Rémi Bernon : winex11.drv: Handle FocusIn/NotifyGrab and FocusOut/NotifyUngrab events.
Alexandre Julliard
julliard at winehq.org
Mon Sep 23 15:22:34 CDT 2019
Module: wine
Branch: master
Commit: ae8f605ede0054c8e380e809c196f2621d9cf423
URL: https://source.winehq.org/git/wine.git/?a=commit;h=ae8f605ede0054c8e380e809c196f2621d9cf423
Author: Rémi Bernon <rbernon at codeweavers.com>
Date: Mon Sep 23 09:58:17 2019 +0200
winex11.drv: Handle FocusIn/NotifyGrab and FocusOut/NotifyUngrab events.
These events are received on mutter, when moving undecorated managed
windows, although Wine never grabs the keyboard itself.
Signed-off-by: Rémi Bernon <rbernon at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/winex11.drv/event.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/dlls/winex11.drv/event.c b/dlls/winex11.drv/event.c
index f79f40c232..25730192d3 100644
--- a/dlls/winex11.drv/event.c
+++ b/dlls/winex11.drv/event.c
@@ -778,8 +778,9 @@ static BOOL X11DRV_FocusIn( HWND hwnd, XEvent *xev )
switch (event->mode)
{
case NotifyGrab:
- WARN( "unexpected FocusIn event with NotifyGrab mode\n" );
- break;
+ /* these are received when moving undecorated managed windows on mutter */
+ keyboard_grabbed = TRUE;
+ return FALSE;
case NotifyWhileGrabbed:
keyboard_grabbed = TRUE;
break;
@@ -879,8 +880,9 @@ static BOOL X11DRV_FocusOut( HWND hwnd, XEvent *xev )
switch (event->mode)
{
case NotifyUngrab:
- WARN( "unexpected FocusOut event with NotifyUngrab mode\n" );
- break;
+ /* these are received when moving undecorated managed windows on mutter */
+ keyboard_grabbed = FALSE;
+ return FALSE;
case NotifyNormal:
keyboard_grabbed = FALSE;
break;
More information about the wine-cvs
mailing list