summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlukefromdc <[email protected]>2023-06-16 18:37:26 -0400
committerraveit65 <[email protected]>2023-07-02 21:10:03 +0200
commita8085cc547281f7df27a7063ffcdb6c9cb027ee0 (patch)
tree1c13fd31f5d4ba48cad3471d26bc419f08557ae4
parent9f81a561186ea52c2bef57b9aaba9e596af4bce2 (diff)
downloadmate-desktop-a8085cc547281f7df27a7063ffcdb6c9cb027ee0.tar.bz2
mate-desktop-a8085cc547281f7df27a7063ffcdb6c9cb027ee0.tar.xz
Initial support for showing a caja desktop in wayland
*put XKillClient and gdk_x11_screen_get_xscreen behind x11-only runtime checks
-rw-r--r--libmate-desktop/mate-bg.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/libmate-desktop/mate-bg.c b/libmate-desktop/mate-bg.c
index e535231..2c44b9e 100644
--- a/libmate-desktop/mate-bg.c
+++ b/libmate-desktop/mate-bg.c
@@ -1163,6 +1163,7 @@ mate_bg_create_surface_scale (MateBG *bg,
cairo_surface_t *surface;
cairo_t *cr;
+ GdkDisplay *display;
g_return_val_if_fail (bg != NULL, NULL);
g_return_val_if_fail (window != NULL, NULL);
@@ -1177,7 +1178,9 @@ mate_bg_create_surface_scale (MateBG *bg,
mate_bg_get_pixmap_size (bg, width, height, &pm_width, &pm_height);
- if (root)
+ display = gdk_display_get_default ();
+
+ if ((root) && GDK_IS_X11_DISPLAY (display))
{
surface = make_root_pixmap (window, pm_width * scale, pm_height * scale);
}