From 52cb19d99d3d667f4475f404a333e347654808dc Mon Sep 17 00:00:00 2001 From: Patrick Steinhardt Date: Sun, 28 Jan 2018 12:04:46 +0000 Subject: rootston: fix compilation without XWayland support In case wlroots is not being compiled with XWayland support, we will not have an xwayland surface in our roots view. While we make sure to pay attention to that in some places, we are not being consistent and try to access the xwayland surface in other places. Obviously, this leads to a compiler error due to the field not being present. Fix the issue by sprinkling in a few additional ifdefs where required. --- rootston/seat.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'rootston/seat.c') diff --git a/rootston/seat.c b/rootston/seat.c index e6e505b5..d7353d1e 100644 --- a/rootston/seat.c +++ b/rootston/seat.c @@ -651,10 +651,12 @@ void roots_seat_set_focus(struct roots_seat *seat, struct roots_view *view) { return; } +#ifdef WLR_HAS_XWAYLAND if (view && view->type == ROOTS_XWAYLAND_VIEW && view->xwayland_surface->override_redirect) { return; } +#endif struct roots_seat_view *seat_view = NULL; if (view != NULL) { seat_view = roots_seat_view_from_view(seat, view); -- cgit v1.2.3