xserver: Branch 'xwayland-1.12'

Kristian Høgsberg krh at kemper.freedesktop.org
Thu Jul 19 09:50:56 PDT 2012


 hw/xfree86/xwayland/xwayland-input.c |    5 +++++
 1 file changed, 5 insertions(+)

New commits:
commit facfb9415debd77fe18b4dbc1ee82f3ba25f5ee6
Author: Kristian Høgsberg <krh at bitplanet.net>
Date:   Thu Jul 19 12:51:40 2012 -0400

    xwayland: Hide cursor on leave, show again on enter
    
    This makes sure we change the cursor on enter.  If the pointer enters from
    a wayland client the X server would not have seen any cursor change that
    client made, so this makes sure we always set the cursor on enter.

diff --git a/hw/xfree86/xwayland/xwayland-input.c b/hw/xfree86/xwayland/xwayland-input.c
index b129fae..d9f352f 100644
--- a/hw/xfree86/xwayland/xwayland-input.c
+++ b/hw/xfree86/xwayland/xwayland-input.c
@@ -294,6 +294,8 @@ pointer_handle_enter(void *data, struct wl_pointer *pointer,
     for (i = 0; i < dev->button->numButtons; i++)
 	if (BitIsOn(dev->button->down, i))
 		xf86PostButtonEvent(dev, TRUE, i, 0, 0, 0);
+
+    (*pScreen->DisplayCursor)(dev, pScreen, dev->spriteInfo->sprite->current);
 }
 
 static void
@@ -301,11 +303,14 @@ pointer_handle_leave(void *data, struct wl_pointer *pointer,
 		     uint32_t serial, struct wl_surface *surface)
 {
     struct xwl_seat *xwl_seat = data;
+    DeviceIntPtr dev = xwl_seat->pointer;
+    ScreenPtr pScreen = xwl_seat->xwl_screen->screen;
 
     xwl_seat->xwl_screen->serial = serial;
 
     xwl_seat->focus_window = NULL;
     SetDeviceRedirectWindow(xwl_seat->pointer, PointerRootWin);
+    (*pScreen->DisplayCursor)(dev, pScreen, NullCursor);
 }
 
 static void


More information about the xorg-commit mailing list