summaryrefslogtreecommitdiff
path: root/LibCore/CObject.h
diff options
context:
space:
mode:
authorAndreas Kling <awesomekling@gmail.com>2019-04-16 03:47:55 +0200
committerAndreas Kling <awesomekling@gmail.com>2019-04-16 03:47:55 +0200
commit04500c1ae29c8ae5b59b8850b88afe1844548dce (patch)
tree06f980bc5180e5c73a1965f2e52e74e27d233356 /LibCore/CObject.h
parentd31b47b371b77f906c4c6d5759ed1a64aa8c5db1 (diff)
downloadserenity-04500c1ae29c8ae5b59b8850b88afe1844548dce.zip
GWidget: Add some new child z-ordering facilities.
- child_at(Point) - move_to_front() - move_to_back() - is_frontmost() - is_backmost() This patch also makes it possible to receive the mouse event that triggers a context menu before the context menu is shown. I'm not sure this is the best design for context menus but it works for now.
Diffstat (limited to 'LibCore/CObject.h')
-rw-r--r--LibCore/CObject.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/LibCore/CObject.h b/LibCore/CObject.h
index c94ed2f167..f8ae55a7b2 100644
--- a/LibCore/CObject.h
+++ b/LibCore/CObject.h
@@ -18,6 +18,7 @@ public:
virtual void event(CEvent&);
Vector<CObject*>& children() { return m_children; }
+ const Vector<CObject*>& children() const { return m_children; }
CObject* parent() { return m_parent; }
const CObject* parent() const { return m_parent; }