summaryrefslogtreecommitdiff
path: root/shell/ev-sidebar-annotations.c
diff options
context:
space:
mode:
authorPablo Barciela <[email protected]>2019-08-09 12:18:24 +0200
committerlukefromdc <[email protected]>2019-08-16 20:40:31 +0000
commit5ec170487062ce3f40f08798a53df76562439f77 (patch)
treedcde56cc044807290d115c9cef52991b6e346f05 /shell/ev-sidebar-annotations.c
parent39c90f02308c6c54d6e655525420d1061c2e73dc (diff)
downloadatril-5ec170487062ce3f40f08798a53df76562439f77.tar.bz2
atril-5ec170487062ce3f40f08798a53df76562439f77.tar.xz
ev-sidebar-annotations: avoid 'g_type_class_add_private'
Diffstat (limited to 'shell/ev-sidebar-annotations.c')
-rw-r--r--shell/ev-sidebar-annotations.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/shell/ev-sidebar-annotations.c b/shell/ev-sidebar-annotations.c
index ee605005..f445cd35 100644
--- a/shell/ev-sidebar-annotations.c
+++ b/shell/ev-sidebar-annotations.c
@@ -68,12 +68,10 @@ G_DEFINE_TYPE_EXTENDED (EvSidebarAnnotations,
ev_sidebar_annotations,
GTK_TYPE_BOX,
0,
+ G_ADD_PRIVATE (EvSidebarAnnotations)
G_IMPLEMENT_INTERFACE (EV_TYPE_SIDEBAR_PAGE,
ev_sidebar_annotations_page_iface_init))
-#define EV_SIDEBAR_ANNOTATIONS_GET_PRIVATE(object) \
- (G_TYPE_INSTANCE_GET_PRIVATE ((object), EV_TYPE_SIDEBAR_ANNOTATIONS, EvSidebarAnnotationsPrivate))
-
static void
ev_sidebar_annotations_dispose (GObject *object)
{
@@ -144,7 +142,7 @@ ev_sidebar_annotations_init (EvSidebarAnnotations *ev_annots)
GtkWidget *image;
GtkWidget *label;
- ev_annots->priv = EV_SIDEBAR_ANNOTATIONS_GET_PRIVATE (ev_annots);
+ ev_annots->priv = ev_sidebar_annotations_get_instance_private (ev_annots);
gtk_orientable_set_orientation (GTK_ORIENTABLE (ev_annots), GTK_ORIENTATION_VERTICAL);
@@ -244,8 +242,6 @@ ev_sidebar_annotations_class_init (EvSidebarAnnotationsClass *klass)
g_object_class->get_property = ev_sidebar_annotations_get_property;
g_object_class->dispose = ev_sidebar_annotations_dispose;
- g_type_class_add_private (g_object_class, sizeof (EvSidebarAnnotationsPrivate));
-
g_object_class_override_property (g_object_class, PROP_WIDGET, "main-widget");
signals[ANNOT_ACTIVATED] =