973c76f
From 00e15ddb814dd39bbe7915fff7920aa90ca52cea Mon Sep 17 00:00:00 2001
973c76f
From: Trevor McCort <tjmccort@gmail.com>
973c76f
Date: Tue, 15 Oct 2013 19:41:12 -0500
973c76f
Subject: [PATCH 36/39] xwayland: Fix hidden cursor
973c76f
973c76f
If a cursor is set when bits->emptyMask is true, the xserver
973c76f
sets a NULL cursor instead.
973c76f
973c76f
Signed-off-by: Trevor McCort <tjmccort@gmail.com>
973c76f
---
973c76f
 hw/xfree86/xwayland/xwayland-cursor.c | 9 ++++++++-
973c76f
 1 file changed, 8 insertions(+), 1 deletion(-)
973c76f
973c76f
diff --git a/hw/xfree86/xwayland/xwayland-cursor.c b/hw/xfree86/xwayland/xwayland-cursor.c
973c76f
index 2cdd248..2b3cb5e 100644
973c76f
--- a/hw/xfree86/xwayland/xwayland-cursor.c
973c76f
+++ b/hw/xfree86/xwayland/xwayland-cursor.c
973c76f
@@ -153,9 +153,16 @@ xwl_seat_set_cursor(struct xwl_seat *xwl_seat)
973c76f
 {
973c76f
     struct wl_buffer *buffer;
973c76f
973c76f
-    if (!xwl_seat->x_cursor || !xwl_seat->wl_pointer)
973c76f
+    if (!xwl_seat->wl_pointer)
973c76f
         return;
973c76f
973c76f
+    if (!xwl_seat->x_cursor) {
973c76f
+        wl_pointer_set_cursor(xwl_seat->wl_pointer,
973c76f
+                              xwl_seat->pointer_enter_serial,
973c76f
+                              NULL, 0, 0);
973c76f
+        return;
973c76f
+    }
973c76f
+
973c76f
     buffer = dixGetPrivate(&xwl_seat->x_cursor->devPrivates,
973c76f
                            &xwl_seat->xwl_screen->cursor_private_key);
973c76f
973c76f
--
973c76f
1.8.3.1