summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPablo Barciela <[email protected]>2018-12-31 13:44:09 +0100
committerZenWalker <[email protected]>2019-01-03 23:11:29 +0100
commit7a18fdde8c216caeca0d6cf7f13c67b3e3ae3806 (patch)
tree018e828f34f92124d8c611d8c15dfa95a1256963
parent6a113cd87c2a6455e51bb434127acdc5fb405b0f (diff)
downloadmarco-7a18fdde8c216caeca0d6cf7f13c67b3e3ae3806.tar.bz2
marco-7a18fdde8c216caeca0d6cf7f13c67b3e3ae3806.tar.xz
compositor-xrender: avoid deprecated 'gdk_error_trap_push/pop'
-rw-r--r--src/compositor/compositor-xrender.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/compositor/compositor-xrender.c b/src/compositor/compositor-xrender.c
index 74703e67..c18c8dd2 100644
--- a/src/compositor/compositor-xrender.c
+++ b/src/compositor/compositor-xrender.c
@@ -34,6 +34,7 @@
#include <unistd.h>
#include <gdk/gdk.h>
+#include <gdk/gdkx.h>
#include <gtk/gtk.h>
#include <cairo/cairo-xlib.h>
@@ -2722,6 +2723,7 @@ xrender_manage_screen (MetaCompositor *compositor,
MetaCompScreen *info;
MetaDisplay *display = meta_screen_get_display (screen);
Display *xdisplay = meta_display_get_xdisplay (display);
+ GdkDisplay *gdk_display = gdk_x11_lookup_xdisplay (xdisplay);
XRenderPictureAttributes pa;
XRenderPictFormat *visual_format;
int screen_number = meta_screen_get_screen_number (screen);
@@ -2732,11 +2734,11 @@ xrender_manage_screen (MetaCompositor *compositor,
if (meta_screen_get_compositor_data (screen))
return;
- gdk_error_trap_push ();
+ gdk_x11_display_error_trap_push (gdk_display);
XCompositeRedirectSubwindows (xdisplay, xroot, CompositeRedirectManual);
XSync (xdisplay, FALSE);
- if (gdk_error_trap_pop ())
+ if (gdk_x11_display_error_trap_pop (gdk_display))
{
g_warning ("Another compositing manager is running on screen %i",
screen_number);