[mutter] compositor: Don't select for stage events on the UI X11 connection
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] compositor: Don't select for stage events on the UI X11 connection
- Date: Thu, 24 Apr 2014 16:13:21 +0000 (UTC)
commit 925075ddaf54e33e45ee999399ff20c7cb19cb3d
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Thu Apr 24 11:54:48 2014 -0400
compositor: Don't select for stage events on the UI X11 connection
src/compositor/compositor.c | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
---
diff --git a/src/compositor/compositor.c b/src/compositor/compositor.c
index f74173d..35193d9 100644
--- a/src/compositor/compositor.c
+++ b/src/compositor/compositor.c
@@ -513,12 +513,14 @@ meta_compositor_manage (MetaCompositor *compositor)
XResizeWindow (xdisplay, xwin, width, height);
{
+ MetaBackendX11 *backend = META_BACKEND_X11 (meta_get_backend ());
+ Display *backend_xdisplay = meta_backend_x11_get_xdisplay (backend);
long event_mask;
unsigned char mask_bits[XIMaskLen (XI_LASTEVENT)] = { 0 };
XIEventMask mask = { XIAllMasterDevices, sizeof (mask_bits), mask_bits };
XWindowAttributes attr;
- meta_core_add_old_event_mask (xdisplay, xwin, &mask);
+ meta_core_add_old_event_mask (backend_xdisplay, xwin, &mask);
XISetMask (mask.mask, XI_KeyPress);
XISetMask (mask.mask, XI_KeyRelease);
@@ -532,13 +534,13 @@ meta_compositor_manage (MetaCompositor *compositor)
XIClearMask (mask.mask, XI_TouchBegin);
XIClearMask (mask.mask, XI_TouchEnd);
XIClearMask (mask.mask, XI_TouchUpdate);
- XISelectEvents (xdisplay, xwin, &mask, 1);
+ XISelectEvents (backend_xdisplay, xwin, &mask, 1);
event_mask = ExposureMask | PropertyChangeMask | StructureNotifyMask;
- if (XGetWindowAttributes (xdisplay, xwin, &attr))
+ if (XGetWindowAttributes (backend_xdisplay, xwin, &attr))
event_mask |= attr.your_event_mask;
- XSelectInput (xdisplay, xwin, event_mask);
+ XSelectInput (backend_xdisplay, xwin, event_mask);
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]