summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mate-panel/menu.c3
-rw-r--r--mate-panel/panel-force-quit.c4
-rw-r--r--mate-panel/panel-toplevel.c8
-rw-r--r--mate-panel/panel-util.c4
-rw-r--r--mate-panel/panel-widget.c8
5 files changed, 17 insertions, 10 deletions
diff --git a/mate-panel/menu.c b/mate-panel/menu.c
index 3d71bca2..3fe1d329 100644
--- a/mate-panel/menu.c
+++ b/mate-panel/menu.c
@@ -691,7 +691,8 @@ drag_end_menu_cb (GtkWidget *widget, GdkDragContext *context)
GdkDeviceManager *device_manager;
#endif
GdkWindow *window = gtk_widget_get_window (xgrab_shell);
- GdkCursor *cursor = gdk_cursor_new (GDK_ARROW);
+ GdkCursor *cursor = gdk_cursor_new_for_display (gdk_display_get_default (),
+ GDK_ARROW);
#if GTK_CHECK_VERSION (3, 0, 0)
display = gdk_window_get_display (window);
diff --git a/mate-panel/panel-force-quit.c b/mate-panel/panel-force-quit.c
index e8832214..842922b2 100644
--- a/mate-panel/panel-force-quit.c
+++ b/mate-panel/panel-force-quit.c
@@ -350,8 +350,8 @@ panel_force_quit (GdkScreen *screen,
root = gdk_screen_get_root_window (screen);
gdk_window_add_filter (root, (GdkFilterFunc) popup_filter, popup);
-
- cross = gdk_cursor_new (GDK_CROSS);
+ cross = gdk_cursor_new_for_display (gdk_display_get_default (),
+ GDK_CROSS);
#if GTK_CHECK_VERSION (3, 0, 0)
display = gdk_window_get_display (root);
device_manager = gdk_display_get_device_manager (display);
diff --git a/mate-panel/panel-toplevel.c b/mate-panel/panel-toplevel.c
index f740d0c8..fa1b757c 100644
--- a/mate-panel/panel-toplevel.c
+++ b/mate-panel/panel-toplevel.c
@@ -438,8 +438,8 @@ static void panel_toplevel_begin_grab_op(PanelToplevel* toplevel, PanelGrabOpTyp
GdkWindow *window;
GdkCursorType cursor_type;
GdkCursor *cursor;
- GdkDisplay *display;
#if GTK_CHECK_VERSION (3, 0, 0)
+ GdkDisplay *display;
GdkDevice *pointer;
GdkDevice *keyboard;
GdkDeviceManager *device_manager;
@@ -496,9 +496,11 @@ static void panel_toplevel_begin_grab_op(PanelToplevel* toplevel, PanelGrabOpTyp
cursor_type = panel_toplevel_grab_op_cursor (
toplevel, toplevel->priv->grab_op);
- display = gdk_window_get_display (window);
- cursor = gdk_cursor_new_for_display (display, cursor_type);
+
+ cursor = gdk_cursor_new_for_display (gdk_display_get_default (),
+ cursor_type);
#if GTK_CHECK_VERSION (3, 0, 0)
+ display = gdk_window_get_display (window);
device_manager = gdk_display_get_device_manager (display);
pointer = gdk_device_manager_get_client_pointer (device_manager);
keyboard = gdk_device_get_associated_device (pointer);
diff --git a/mate-panel/panel-util.c b/mate-panel/panel-util.c
index 49048289..1567a73c 100644
--- a/mate-panel/panel-util.c
+++ b/mate-panel/panel-util.c
@@ -112,7 +112,9 @@ panel_push_window_busy (GtkWidget *window)
win = gtk_widget_get_window (window);
if (win != NULL) {
- GdkCursor *cursor = gdk_cursor_new (GDK_WATCH);
+ GdkCursor *cursor = gdk_cursor_new_for_display (gdk_display_get_default (),
+ GDK_WATCH);
+
gdk_window_set_cursor (win, cursor);
#if GTK_CHECK_VERSION (3, 0, 0)
g_object_unref (cursor);
diff --git a/mate-panel/panel-widget.c b/mate-panel/panel-widget.c
index 9d162690..ab1872cb 100644
--- a/mate-panel/panel-widget.c
+++ b/mate-panel/panel-widget.c
@@ -2011,9 +2011,13 @@ panel_widget_applet_drag_start (PanelWidget *panel,
GdkDisplay *display;
GdkDevice *pointer;
GdkDeviceManager *device_manager;
+#endif
+
+ fleur_cursor = gdk_cursor_new_for_display (gdk_display_get_default (),
+ GDK_FLEUR);
+#if GTK_CHECK_VERSION (3, 0, 0)
display = gdk_window_get_display (window);
- fleur_cursor = gdk_cursor_new_for_display (display, GDK_FLEUR);
device_manager = gdk_display_get_device_manager (display);
pointer = gdk_device_manager_get_client_pointer (device_manager);
status = gdk_device_grab (pointer, window,
@@ -2023,8 +2027,6 @@ panel_widget_applet_drag_start (PanelWidget *panel,
g_object_unref (fleur_cursor);
#else
- fleur_cursor = gdk_cursor_new (GDK_FLEUR);
-
status = gdk_pointer_grab (window, FALSE,
APPLET_EVENT_MASK, NULL,
fleur_cursor, time_);