summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWilliam Wold <[email protected]>2019-06-20 04:39:39 +0000
committerraveit65 <[email protected]>2019-06-23 10:12:24 +0200
commit8fca8d929a6382d59566639acb0edf1bdb5c9600 (patch)
treee1594f2f232af827ea3b2ef9d59a81385fc50255
parent598b3fec58b15eb2eb5e2d7bcaf0a26b2acc6afc (diff)
downloadmate-panel-8fca8d929a6382d59566639acb0edf1bdb5c9600.tar.bz2
mate-panel-8fca8d929a6382d59566639acb0edf1bdb5c9600.tar.xz
Wayland support for panel-layout.c
-rw-r--r--mate-panel/panel-layout.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/mate-panel/panel-layout.c b/mate-panel/panel-layout.c
index ab051e96..d550af97 100644
--- a/mate-panel/panel-layout.c
+++ b/mate-panel/panel-layout.c
@@ -28,7 +28,10 @@
#include <glib.h>
#include <gio/gio.h>
+
+#ifdef HAVE_X11
#include <gdk/gdkx.h>
+#endif
#include <libmate-desktop/mate-dconf.h>
#include <libmate-desktop/mate-gsettings.h>
@@ -321,7 +324,12 @@ panel_layout_apply_default_from_gkeyfile (GdkScreen *screen)
GError *error = NULL;
int i;
- screen_n = gdk_x11_screen_get_screen_number (screen);
+ screen_n = 0;
+#ifdef HAVE_X11
+ if (GDK_IS_X11_SCREEN (screen))
+ screen_n = gdk_x11_screen_get_screen_number (screen);
+#endif // HAVE_11
+
layout_file = panel_layout_filename();
if (layout_file)