diff options
author | Wu Xiaotian <[email protected]> | 2019-01-26 21:54:36 +0800 |
---|---|---|
committer | lukefromdc <[email protected]> | 2019-01-29 20:18:39 +0000 |
commit | b7dffb4086d7230c1b210bfc06a068a24ef21e5c (patch) | |
tree | 106e6184f387c3f02e521366cb89cadfc5d51af7 /libmate-desktop/mate-rr-labeler.c | |
parent | 627a1d931e3417630a5df78bb87b0d7873e43342 (diff) | |
download | mate-desktop-b7dffb4086d7230c1b210bfc06a068a24ef21e5c.tar.bz2 mate-desktop-b7dffb4086d7230c1b210bfc06a068a24ef21e5c.tar.xz |
[mate-rr] Avoid deprecated g_type_class_add_private
Diffstat (limited to 'libmate-desktop/mate-rr-labeler.c')
-rw-r--r-- | libmate-desktop/mate-rr-labeler.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/libmate-desktop/mate-rr-labeler.c b/libmate-desktop/mate-rr-labeler.c index a1786a5..346eb71 100644 --- a/libmate-desktop/mate-rr-labeler.c +++ b/libmate-desktop/mate-rr-labeler.c @@ -57,7 +57,7 @@ enum { PROP_LAST }; -G_DEFINE_TYPE (MateRRLabeler, mate_rr_labeler, G_TYPE_OBJECT); +G_DEFINE_TYPE_WITH_PRIVATE (MateRRLabeler, mate_rr_labeler, G_TYPE_OBJECT); static void mate_rr_labeler_finalize (GObject *object); static void create_label_windows (MateRRLabeler *labeler); @@ -186,7 +186,7 @@ mate_rr_labeler_init (MateRRLabeler *labeler) { GdkWindow *gdkwindow; - labeler->priv = G_TYPE_INSTANCE_GET_PRIVATE (labeler, MATE_TYPE_RR_LABELER, MateRRLabelerPrivate); + labeler->priv = mate_rr_labeler_get_instance_private (labeler); labeler->priv->workarea_atom = XInternAtom (GDK_DISPLAY_XDISPLAY (gdk_display_get_default ()), "_NET_WORKAREA", @@ -228,8 +228,6 @@ mate_rr_labeler_class_init (MateRRLabelerClass *klass) { GObjectClass *object_class; - g_type_class_add_private (klass, sizeof (MateRRLabelerPrivate)); - object_class = (GObjectClass *) klass; object_class->set_property = mate_rr_labeler_set_property; |