summaryrefslogtreecommitdiff
path: root/mate-panel
diff options
context:
space:
mode:
authorinfirit <[email protected]>2014-11-22 14:09:09 +0100
committerinfirit <[email protected]>2014-11-22 15:13:50 +0100
commitca5abdea1b6a1e5e178dfe63a260b73106f69658 (patch)
treef01ceabc2e75f9f51c905ccde2612b4af740313b /mate-panel
parent7dbd1866ad11c2052cf1508531faed7e57d5d2cc (diff)
downloadmate-panel-ca5abdea1b6a1e5e178dfe63a260b73106f69658.tar.bz2
mate-panel-ca5abdea1b6a1e5e178dfe63a260b73106f69658.tar.xz
Gtk3: Replaced gdk_cursor_unref() by g_object_unref()
gdk_cursor_unref () is deprecated in Gtk+3
Diffstat (limited to 'mate-panel')
-rw-r--r--mate-panel/menu.c4
-rw-r--r--mate-panel/panel-force-quit.c4
-rw-r--r--mate-panel/panel-toplevel.c4
-rw-r--r--mate-panel/panel-util.c4
-rw-r--r--mate-panel/panel-widget.c4
5 files changed, 20 insertions, 0 deletions
diff --git a/mate-panel/menu.c b/mate-panel/menu.c
index 368c416c..3e4b16d2 100644
--- a/mate-panel/menu.c
+++ b/mate-panel/menu.c
@@ -709,7 +709,11 @@ drag_end_menu_cb (GtkWidget *widget, GdkDragContext *context)
}
}
+#if GTK_CHECK_VERSION (3, 0, 0)
+ g_object_unref (cursor);
+#else
gdk_cursor_unref (cursor);
+#endif
}
}
diff --git a/mate-panel/panel-force-quit.c b/mate-panel/panel-force-quit.c
index b4498aeb..9d70b590 100644
--- a/mate-panel/panel-force-quit.c
+++ b/mate-panel/panel-force-quit.c
@@ -302,7 +302,11 @@ panel_force_quit (GdkScreen *screen,
cross = gdk_cursor_new (GDK_CROSS);
status = gdk_pointer_grab (root, FALSE, GDK_BUTTON_PRESS_MASK,
NULL, cross, time);
+#if GTK_CHECK_VERSION (3, 0, 0)
+ g_object_unref (cross);
+#else
gdk_cursor_unref (cross);
+#endif
if (status != GDK_GRAB_SUCCESS) {
g_warning ("Pointer grab failed\n");
remove_popup (popup);
diff --git a/mate-panel/panel-toplevel.c b/mate-panel/panel-toplevel.c
index 00659e5d..8c8b5561 100644
--- a/mate-panel/panel-toplevel.c
+++ b/mate-panel/panel-toplevel.c
@@ -497,7 +497,11 @@ static void panel_toplevel_begin_grab_op(PanelToplevel* toplevel, PanelGrabOpTyp
gdk_pointer_grab (window, FALSE,
GDK_POINTER_MOTION_MASK | GDK_BUTTON_RELEASE_MASK,
NULL, cursor, time_);
+#if GTK_CHECK_VERSION (3, 0, 0)
+ g_object_unref (cursor);
+#else
gdk_cursor_unref (cursor);
+#endif
if (grab_keyboard)
gdk_keyboard_grab (window, FALSE, time_);
diff --git a/mate-panel/panel-util.c b/mate-panel/panel-util.c
index 838d9687..f3ab7bc7 100644
--- a/mate-panel/panel-util.c
+++ b/mate-panel/panel-util.c
@@ -116,7 +116,11 @@ panel_push_window_busy (GtkWidget *window)
if (win != NULL) {
GdkCursor *cursor = gdk_cursor_new (GDK_WATCH);
gdk_window_set_cursor (win, cursor);
+#if GTK_CHECK_VERSION (3, 0, 0)
+ g_object_unref (cursor);
+#else
gdk_cursor_unref (cursor);
+#endif
gdk_flush ();
}
}
diff --git a/mate-panel/panel-widget.c b/mate-panel/panel-widget.c
index 2f402da7..5dd4bb43 100644
--- a/mate-panel/panel-widget.c
+++ b/mate-panel/panel-widget.c
@@ -2032,7 +2032,11 @@ panel_widget_applet_drag_start (PanelWidget *panel,
APPLET_EVENT_MASK, NULL,
fleur_cursor, time_);
+#if GTK_CHECK_VERSION (3, 0, 0)
+ g_object_unref (fleur_cursor);
+#else
gdk_cursor_unref (fleur_cursor);
+#endif
gdk_flush ();
if (status != GDK_GRAB_SUCCESS) {