Use #if instead of #ifdef for wlroots config data

This prevents some annoying issues when e.g. not including wlr/config.h or
making a typo in the guard name.
This commit is contained in:
emersion 2018-11-12 10:12:46 +01:00
parent 3181c4bec0
commit 51bfdd620e
No known key found for this signature in database
GPG key ID: 0FDE7BE0E88F5E48
25 changed files with 69 additions and 61 deletions

View file

@ -1131,7 +1131,7 @@ void roots_seat_set_focus(struct roots_seat *seat, struct roots_view *view) {
bool unfullscreen = true;
#ifdef WLR_HAS_XWAYLAND
#if WLR_HAS_XWAYLAND
if (view && view->type == ROOTS_XWAYLAND_VIEW &&
view->xwayland_surface->override_redirect) {
unfullscreen = false;
@ -1160,7 +1160,7 @@ void roots_seat_set_focus(struct roots_seat *seat, struct roots_view *view) {
return;
}
#ifdef WLR_HAS_XWAYLAND
#if WLR_HAS_XWAYLAND
if (view && view->type == ROOTS_XWAYLAND_VIEW &&
!wlr_xwayland_or_surface_wants_focus(
view->xwayland_surface)) {