[mutter/wayland] backend: Fix the nested mode
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/wayland] backend: Fix the nested mode
- Date: Tue, 1 Apr 2014 18:00:42 +0000 (UTC)
commit 29396014fd7965d757c7989194e3e4b0f6569fae
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Tue Apr 1 13:56:40 2014 -0400
backend: Fix the nested mode
src/backends/meta-backend.c | 19 +++++++++++++++++--
1 files changed, 17 insertions(+), 2 deletions(-)
---
diff --git a/src/backends/meta-backend.c b/src/backends/meta-backend.c
index 464b442..b5ea43d 100644
--- a/src/backends/meta-backend.c
+++ b/src/backends/meta-backend.c
@@ -88,8 +88,23 @@ meta_clutter_init (void)
{
GSource *source;
- clutter_x11_set_display (GDK_DISPLAY_XDISPLAY (gdk_display_get_default ()));
- clutter_x11_disable_event_retrieval ();
+ /* When running as an X11 compositor, we install our own event filter and
+ * pass events to Clutter explicitly, so we need to prevent Clutter from
+ * handling our events.
+ *
+ * However, when running as a Wayland compostior under X11 nested, Clutter
+ * Clutter needs to see events related to its own window. We need to
+ * eventually replace this with a proper frontend / backend split: Clutter
+ * under nested is connecting to the "host X server" to get its events it
+ * needs to put up a window, and GTK+ is connecting to the "inner X server".
+ * The two would the same in the X11 compositor case, but not when running
+ * XWayland as a Wayland compositor.
+ */
+ if (!meta_is_wayland_compositor ())
+ {
+ clutter_x11_set_display (GDK_DISPLAY_XDISPLAY (gdk_display_get_default ()));
+ clutter_x11_disable_event_retrieval ();
+ }
/* If we're running on bare metal, we're a display server,
* so start talking to weston-launch. */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]