[Bf-blender-cvs] [8c8c1029806] master: Fix T40059: Switching windows ignores held modifier keys

Campbell Barton noreply at git.blender.org
Wed Sep 7 08:24:31 CEST 2022


Commit: 8c8c1029806a790e92973612c3675a81939b518c
Author: Campbell Barton
Date:   Wed Sep 7 16:05:49 2022 +1000
Branches: master
https://developer.blender.org/rB8c8c1029806a790e92973612c3675a81939b518c

Fix T40059: Switching windows ignores held modifier keys

Re-enable workaround (USE_WIN_ACTIVATE) which should no longer cause
problems as of [0].

[0]: 37d835f0bca28a7cbf577385d9828636e7811cc5

===================================================================

M	source/blender/windowmanager/intern/wm_window.c

===================================================================

diff --git a/source/blender/windowmanager/intern/wm_window.c b/source/blender/windowmanager/intern/wm_window.c
index 661db1b62e7..359ea209021 100644
--- a/source/blender/windowmanager/intern/wm_window.c
+++ b/source/blender/windowmanager/intern/wm_window.c
@@ -83,6 +83,12 @@
 #  include "BLI_threads.h"
 #endif
 
+/**
+ * When windows are activated, simulate modifier press/release to match the current state of
+ * held modifier keys, see T40317.
+ */
+#define USE_WIN_ACTIVATE
+
 /* the global to talk to ghost */
 static GHOST_SystemHandle g_system = NULL;
 
@@ -1115,11 +1121,6 @@ static bool ghost_event_proc(GHOST_EventHandle evt, GHOST_TUserDataPtr C_void_pt
     }
     wmWindow *win = GHOST_GetWindowUserData(ghostwin);
 
-    /* Win23/GHOST modifier bug, see T40317 */
-#ifndef WIN32
-//#  define USE_WIN_ACTIVATE
-#endif
-
     switch (type) {
       case GHOST_kEventWindowDeactivate:
         wm_event_add_ghostevent(wm, win, type, data);



More information about the Bf-blender-cvs mailing list