summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPablo Barciela <[email protected]>2019-09-19 09:54:45 +0200
committerraveit65 <[email protected]>2019-09-22 11:18:50 +0200
commitd769cf763ddab62985f04d97dab75c2de2a6efb1 (patch)
treefbfff445b7eb8c7579372713e4eb4aef7efdeca7
parente9a2c11eb4d3b7404fd68461fb8bf231c37f1d47 (diff)
downloadeom-d769cf763ddab62985f04d97dab75c2de2a6efb1.tar.bz2
eom-d769cf763ddab62985f04d97dab75c2de2a6efb1.tar.xz
egg_editable_toolbar: avoid 'g_type_class_add_private'
-rw-r--r--cut-n-paste/toolbar-editor/egg-editable-toolbar.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/cut-n-paste/toolbar-editor/egg-editable-toolbar.c b/cut-n-paste/toolbar-editor/egg-editable-toolbar.c
index 5097c2a..3be8f5d 100644
--- a/cut-n-paste/toolbar-editor/egg-editable-toolbar.c
+++ b/cut-n-paste/toolbar-editor/egg-editable-toolbar.c
@@ -57,8 +57,6 @@ enum
static guint egg_editable_toolbar_signals[LAST_SIGNAL] = { 0 };
-#define EGG_EDITABLE_TOOLBAR_GET_PRIVATE(object)(G_TYPE_INSTANCE_GET_PRIVATE ((object), EGG_TYPE_EDITABLE_TOOLBAR, EggEditableToolbarPrivate))
-
struct _EggEditableToolbarPrivate
{
GtkUIManager *manager;
@@ -81,7 +79,7 @@ struct _EggEditableToolbarPrivate
GtkToolItem *dnd_toolitem;
};
-G_DEFINE_TYPE (EggEditableToolbar, egg_editable_toolbar, GTK_TYPE_BOX)
+G_DEFINE_TYPE_WITH_PRIVATE (EggEditableToolbar, egg_editable_toolbar, GTK_TYPE_BOX)
static int
get_dock_position (EggEditableToolbar *etoolbar,
@@ -1360,7 +1358,7 @@ egg_editable_toolbar_init (EggEditableToolbar *etoolbar)
EggEditableToolbarPrivate *priv;
- priv = etoolbar->priv = EGG_EDITABLE_TOOLBAR_GET_PRIVATE (etoolbar);
+ priv = etoolbar->priv = egg_editable_toolbar_get_instance_private (etoolbar);
priv->save_hidden = TRUE;
@@ -1636,8 +1634,6 @@ egg_editable_toolbar_class_init (EggEditableToolbarClass *klass)
"Edit Mode",
FALSE,
G_PARAM_READWRITE | G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB));
-
- g_type_class_add_private (object_class, sizeof (EggEditableToolbarPrivate));
}
GtkWidget *