summaryrefslogtreecommitdiff
path: root/libmate-desktop/mate-bg-crossfade.c
diff options
context:
space:
mode:
authorraveit65 <[email protected]>2018-08-12 15:24:36 +0200
committerraveit65 <[email protected]>2018-08-15 17:59:32 +0200
commitc49a780a0bc0120f4da9453a142d4ee33f506bfb (patch)
tree441fcf6d78a5e8c099575b9033cdca7148c6c952 /libmate-desktop/mate-bg-crossfade.c
parent5e16dc1799dbe6e9293c0d91e88c53023e8875d3 (diff)
downloadmate-desktop-c49a780a0bc0120f4da9453a142d4ee33f506bfb.tar.bz2
mate-desktop-c49a780a0bc0120f4da9453a142d4ee33f506bfb.tar.xz
mate-bg-crossfade: replace deprecated gdk_error_trap_push/pop
Diffstat (limited to 'libmate-desktop/mate-bg-crossfade.c')
-rw-r--r--libmate-desktop/mate-bg-crossfade.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/libmate-desktop/mate-bg-crossfade.c b/libmate-desktop/mate-bg-crossfade.c
index 848727b..96e48eb 100644
--- a/libmate-desktop/mate-bg-crossfade.c
+++ b/libmate-desktop/mate-bg-crossfade.c
@@ -426,13 +426,15 @@ draw_background (MateBGCrossfade *fade)
cairo_region_destroy (region);
} else {
Display *xdisplay = GDK_WINDOW_XDISPLAY (fade->priv->window);
- gdk_error_trap_push ();
+ GdkDisplay *display;
+ display = gdk_display_get_default ();
+ gdk_x11_display_error_trap_push (display);
XGrabServer (xdisplay);
XClearWindow (xdisplay, GDK_WINDOW_XID (fade->priv->window));
send_root_property_change_notification (fade);
XFlush (xdisplay);
XUngrabServer (xdisplay);
- gdk_error_trap_pop_ignored ();
+ gdk_x11_display_error_trap_pop_ignored (display);
}
}
@@ -588,7 +590,7 @@ get_root_pixmap_id_surface (GdkDisplay *display)
int x_ret, y_ret;
unsigned int w_ret, h_ret, bw_ret, depth_ret;
- gdk_error_trap_push ();
+ gdk_x11_display_error_trap_push (display);
if (XGetGeometry (xdisplay, pixmap, &root_ret,
&x_ret, &y_ret, &w_ret, &h_ret,
&bw_ret, &depth_ret))
@@ -598,7 +600,7 @@ get_root_pixmap_id_surface (GdkDisplay *display)
w_ret, h_ret);
}
- gdk_error_trap_pop_ignored ();
+ gdk_x11_display_error_trap_pop_ignored (display);
XFree (data);
}