From de5347d0f2a82150a4788b63d06b5e91d5ebc27a Mon Sep 17 00:00:00 2001 From: Simon Ser Date: Mon, 29 Mar 2021 12:03:35 +0200 Subject: xwayland: require xcb-icccm This dependency is already required by many other widely used X11 programs, such as i3, Qt, and other XWMs. So it should be available on most systems. X11 support can be pretty broken without xcb-icccm, with focus issues for instance. Let's just remove this --please-break-my-desktop footgun option. --- xwayland/meson.build | 2 +- xwayland/xwm.c | 18 +----------------- 2 files changed, 2 insertions(+), 18 deletions(-) (limited to 'xwayland') diff --git a/xwayland/meson.build b/xwayland/meson.build index a4b51bf2..09a7c6c2 100644 --- a/xwayland/meson.build +++ b/xwayland/meson.build @@ -2,12 +2,12 @@ xwayland_libs = [] xwayland_required = [ 'xcb', 'xcb-composite', + 'xcb-icccm', 'xcb-render', 'xcb-xfixes', ] xwayland_optional = { 'xcb-errors': 'Required for printing X11 errors.', - 'xcb-icccm': 'Required for extended X11 window manager hints.', } msg = [] diff --git a/xwayland/xwm.c b/xwayland/xwm.c index 89459533..b8e686d7 100644 --- a/xwayland/xwm.c +++ b/xwayland/xwm.c @@ -14,6 +14,7 @@ #include #include #include +#include #include #include "util/signal.h" #include "xwayland/xwm.h" @@ -563,7 +564,6 @@ static void read_surface_protocols(struct wlr_xwm *xwm, xsurface->protocols_len = atoms_len; } -#if WLR_HAS_XCB_ICCCM static void read_surface_hints(struct wlr_xwm *xwm, struct wlr_xwayland_surface *xsurface, xcb_get_property_reply_t *reply) { @@ -593,15 +593,7 @@ static void read_surface_hints(struct wlr_xwm *xwm, wlr_signal_emit_safe(&xsurface->events.set_hints, xsurface); } -#else -static void read_surface_hints(struct wlr_xwm *xwm, - struct wlr_xwayland_surface *xsurface, - xcb_get_property_reply_t *reply) { - // Do nothing -} -#endif -#if WLR_HAS_XCB_ICCCM static void read_surface_normal_hints(struct wlr_xwm *xwm, struct wlr_xwayland_surface *xsurface, xcb_get_property_reply_t *reply) { @@ -642,14 +634,6 @@ static void read_surface_normal_hints(struct wlr_xwm *xwm, xsurface->size_hints->max_height = -1; } } -#else -static void read_surface_normal_hints(struct wlr_xwm *xwm, - struct wlr_xwayland_surface *xsurface, - xcb_get_property_reply_t *reply) { - // Do nothing -} -#endif - #define MWM_HINTS_FLAGS_FIELD 0 #define MWM_HINTS_DECORATIONS_FIELD 2 -- cgit v1.2.3