summaryrefslogtreecommitdiff
path: root/applets
diff options
context:
space:
mode:
authorAlberts Muktupavels <[email protected]>2018-09-11 14:33:33 +0300
committerraveit65 <[email protected]>2019-06-05 16:25:42 +0200
commita9e608411f519b5cb1bc268f7384dc8449221d4f (patch)
tree8faed0be575b5cf2ad8d0d5a5873255a44dfe9e3 /applets
parente41549de306f4c597aec1d01755b3ab9c624da1d (diff)
downloadmate-panel-a9e608411f519b5cb1bc268f7384dc8449221d4f.tar.bz2
mate-panel-a9e608411f519b5cb1bc268f7384dc8449221d4f.tar.xz
na-tray: avoid deprecated g_type_class_add_private
origin commit: https://gitlab.gnome.org/GNOME/gnome-panel/commit/cb2cc3a
Diffstat (limited to 'applets')
-rw-r--r--applets/notification_area/system-tray/fixedtip.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/applets/notification_area/system-tray/fixedtip.c b/applets/notification_area/system-tray/fixedtip.c
index 2278e9ca..f5817cdd 100644
--- a/applets/notification_area/system-tray/fixedtip.c
+++ b/applets/notification_area/system-tray/fixedtip.c
@@ -39,7 +39,7 @@ struct _NaFixedTipPrivate
GtkOrientation orientation;
};
-G_DEFINE_TYPE (NaFixedTip, na_fixed_tip, GTK_TYPE_WINDOW)
+G_DEFINE_TYPE_WITH_PRIVATE (NaFixedTip, na_fixed_tip, GTK_TYPE_WINDOW)
static gboolean
button_press_handler (GtkWidget *fixedtip,
@@ -94,8 +94,6 @@ na_fixed_tip_class_init (NaFixedTipClass *class)
NULL, NULL,
g_cclosure_marshal_VOID__VOID,
G_TYPE_NONE, 0);
-
- g_type_class_add_private (class, sizeof (NaFixedTipPrivate));
}
/* Did you already see this code? Yes, it's gtk_tooltips_ force_window() ;-) */
@@ -104,8 +102,7 @@ na_fixed_tip_init (NaFixedTip *fixedtip)
{
GtkWidget *label;
- fixedtip->priv = G_TYPE_INSTANCE_GET_PRIVATE (fixedtip, NA_TYPE_FIXED_TIP,
- NaFixedTipPrivate);
+ fixedtip->priv = na_fixed_tip_get_instance_private (fixedtip);
gtk_window_set_type_hint (GTK_WINDOW (fixedtip),
GDK_WINDOW_TYPE_HINT_TOOLTIP);