summaryrefslogtreecommitdiff
path: root/src/x11/meta-x11-display.c
diff options
context:
space:
mode:
authorJonas Ã…dahl <jadahl@gmail.com>2022-03-14 22:45:34 +0100
committerMarge Bot <marge-bot@gnome.org>2022-07-26 20:27:24 +0000
commit0debb24e12d7b2f60d489b31981019f5f7b9b508 (patch)
tree500c395e19fc96e427af322588d96cc48f6ba6de /src/x11/meta-x11-display.c
parent877dc33545e76cf71358d304caf39755b74081a7 (diff)
downloadmutter-0debb24e12d7b2f60d489b31981019f5f7b9b508.tar.gz
barriers: Make barriers fully part of the backend
Prior to this commit, barriers were created with a MetaDisplay pointer, despite being entities related and owned by the backend. In the X11 case, it was also not hooked up to the backend X11 connection, but the clutter one, meaning for example that the logic was active (but dormant) also for the Xwayland connection. Fix this by moving X11 barrier management and event processing fully to the backend. Also replace passing a display pointer with passing a backend pointer. Keep the display pointer around for a release, but mark it as deprecated. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2442>
Diffstat (limited to 'src/x11/meta-x11-display.c')
-rw-r--r--src/x11/meta-x11-display.c16
1 files changed, 2 insertions, 14 deletions
diff --git a/src/x11/meta-x11-display.c b/src/x11/meta-x11-display.c
index bb5f4bf50..3139246cc 100644
--- a/src/x11/meta-x11-display.c
+++ b/src/x11/meta-x11-display.c
@@ -429,15 +429,8 @@ query_xi_extension (MetaX11Display *x11_display)
&x11_display->xinput_error_base,
&x11_display->xinput_event_base))
{
- if (XIQueryVersion (x11_display->xdisplay, &major, &minor) == Success)
- {
- int version = (major * 10) + minor;
- if (version >= 22)
- has_xi = TRUE;
-
- if (version >= 23)
- x11_display->have_xinput_23 = TRUE;
- }
+ if (XIQueryVersion (x11_display->xdisplay, &major, &minor) == Success)
+ has_xi = TRUE;
}
if (!has_xi)
@@ -792,11 +785,6 @@ init_event_masks (MetaX11Display *x11_display)
XISetMask (mask.mask, XI_Leave);
XISetMask (mask.mask, XI_FocusIn);
XISetMask (mask.mask, XI_FocusOut);
- if (META_X11_DISPLAY_HAS_XINPUT_23 (x11_display))
- {
- XISetMask (mask.mask, XI_BarrierHit);
- XISetMask (mask.mask, XI_BarrierLeave);
- }
XISelectEvents (x11_display->xdisplay, x11_display->xroot, &mask, 1);
event_mask = (SubstructureRedirectMask | SubstructureNotifyMask |