summaryrefslogtreecommitdiff
path: root/Libraries/LibGUI/GItemView.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/GItemView.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/GItemView.h')
-rw-r--r--Libraries/LibGUI/GItemView.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/Libraries/LibGUI/GItemView.h b/Libraries/LibGUI/GItemView.h
index ca50019ce4..0d0bacf492 100644
--- a/Libraries/LibGUI/GItemView.h
+++ b/Libraries/LibGUI/GItemView.h
@@ -9,6 +9,7 @@ class GScrollBar;
class Painter;
class GItemView : public GAbstractView {
+ C_OBJECT(GItemView)
public:
explicit GItemView(GWidget* parent);
virtual ~GItemView() override;
@@ -22,8 +23,6 @@ public:
int model_column() const { return m_model_column; }
void set_model_column(int column) { m_model_column = column; }
- virtual const char* class_name() const override { return "GItemView"; }
-
private:
virtual void did_update_model() override;
virtual void paint_event(GPaintEvent&) override;