summaryrefslogtreecommitdiff
path: root/Libraries/LibGUI/GListView.h
diff options
context:
space:
mode:
authorAndreas Kling <awesomekling@gmail.com>2019-07-25 19:49:28 +0200
committerAndreas Kling <awesomekling@gmail.com>2019-07-25 19:49:28 +0200
commita599317624fb8428eb64cf719affcdd075f5c9d5 (patch)
tree7669ffd4a1acab1b0caf003443ed470de6fe34ea /Libraries/LibGUI/GListView.h
parentd21a4f7518ced2b49e20b3b2521c80b0afec216d (diff)
downloadserenity-a599317624fb8428eb64cf719affcdd075f5c9d5.zip
LibCore: Introduce a C_OBJECT macro.
This macro goes at the top of every CObject-derived class like so: class SomeClass : public CObject { C_OBJECT(SomeClass) public: ... At the moment, all it does is create an override for the class_name() getter but in the future this will be used to automatically insert member functions into these classes.
Diffstat (limited to 'Libraries/LibGUI/GListView.h')
-rw-r--r--Libraries/LibGUI/GListView.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/Libraries/LibGUI/GListView.h b/Libraries/LibGUI/GListView.h
index d32f7b51f9..1298ad4ec5 100644
--- a/Libraries/LibGUI/GListView.h
+++ b/Libraries/LibGUI/GListView.h
@@ -9,6 +9,7 @@ class GScrollBar;
class Painter;
class GListView : public GAbstractView {
+ C_OBJECT(GListView)
public:
explicit GListView(GWidget* parent);
virtual ~GListView() override;
@@ -26,8 +27,6 @@ public:
virtual Rect content_rect(const GModelIndex&) const override;
- virtual const char* class_name() const override { return "GListView"; }
-
private:
virtual void did_update_model() override;
virtual void paint_event(GPaintEvent&) override;