Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
libappfw|GuiRootWidget: Added method for finding GuiWidgets
  • Loading branch information
skyjake committed Mar 10, 2014
1 parent 303a0bb commit 3ef5e7d
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
2 changes: 2 additions & 0 deletions doomsday/libappfw/include/de/framework/guirootwidget.h
Expand Up @@ -86,6 +86,8 @@ class LIBAPPFW_PUBLIC GuiRootWidget : public RootWidget
*/
GuiWidget const *globalHitTest(Vector2i const &pos) const;

GuiWidget const *guiFind(String const &name) const;

// Events.
void update();
void draw();
Expand Down
5 changes: 5 additions & 0 deletions doomsday/libappfw/src/guirootwidget.cpp
Expand Up @@ -322,6 +322,11 @@ GuiWidget const *GuiRootWidget::globalHitTest(Vector2i const &pos) const
return 0;
}

GuiWidget const *GuiRootWidget::guiFind(String const &name) const
{
return find(name)->maybeAs<GuiWidget>();
}

void GuiRootWidget::update()
{
if(window().canvas().isGLReady())
Expand Down

0 comments on commit 3ef5e7d

Please sign in to comment.