summaryrefslogtreecommitdiff
path: root/gtk/gtknumerableicon.c
diff options
context:
space:
mode:
authorEmmanuele Bassi <ebassi@gnome.org>2013-06-27 20:02:52 +0100
committerEmmanuele Bassi <ebassi@gnome.org>2013-07-09 09:30:02 +0100
commit0899ef7cc9cf73824901923143f38bb9b6d224a3 (patch)
tree16207a8837da8a89a6f4a1d1a1c23074fd29aa1d /gtk/gtknumerableicon.c
parent365919d5f6da0a8648815ca5cf5805fb88c9be16 (diff)
downloadgtk+-0899ef7cc9cf73824901923143f38bb9b6d224a3.tar.gz
gtk: Use new macros for defining private data
https://bugzilla.gnome.org/show_bug.cgi?id=702996
Diffstat (limited to 'gtk/gtknumerableicon.c')
-rw-r--r--gtk/gtknumerableicon.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/gtk/gtknumerableicon.c b/gtk/gtknumerableicon.c
index 1d5768f11f..45c9b0e579 100644
--- a/gtk/gtknumerableicon.c
+++ b/gtk/gtknumerableicon.c
@@ -93,7 +93,7 @@ enum {
static GParamSpec *properties[NUM_PROPERTIES] = { NULL, };
-G_DEFINE_TYPE (GtkNumerableIcon, gtk_numerable_icon, G_TYPE_EMBLEMED_ICON);
+G_DEFINE_TYPE_WITH_PRIVATE (GtkNumerableIcon, gtk_numerable_icon, G_TYPE_EMBLEMED_ICON)
static gint
get_surface_size (cairo_surface_t *surface)
@@ -636,8 +636,6 @@ gtk_numerable_icon_class_init (GtkNumerableIconClass *klass)
oclass->dispose = gtk_numerable_icon_dispose;
oclass->finalize = gtk_numerable_icon_finalize;
- g_type_class_add_private (klass, sizeof (GtkNumerableIconPrivate));
-
properties[PROP_COUNT] =
g_param_spec_int ("count",
P_("Icon's count"),
@@ -682,9 +680,7 @@ gtk_numerable_icon_init (GtkNumerableIcon *self)
GdkRGBA bg;
GdkRGBA fg;
- self->priv = G_TYPE_INSTANCE_GET_PRIVATE (self,
- GTK_TYPE_NUMERABLE_ICON,
- GtkNumerableIconPrivate);
+ self->priv = gtk_numerable_icon_get_instance_private (self);
gdk_rgba_parse (&bg, DEFAULT_BACKGROUND);
gdk_rgba_parse (&fg, DEFAULT_FOREGROUND);