GHOST/X11: Xinput/XIM support caused double key-up
authorCampbell Barton <ideasman42@gmail.com>
Thu, 7 Jun 2018 18:32:51 +0000 (20:32 +0200)
committerCampbell Barton <ideasman42@gmail.com>
Thu, 7 Jun 2018 18:35:06 +0000 (20:35 +0200)
All keyboard events were sending double key events (including modifiers)
when xinput was enabled with gnome (causing much confusion!).

I cant test if XIM works,
but this isn't useful to send double events, so disabling for now.

intern/ghost/intern/GHOST_SystemX11.cpp

index 93a9f3589f4fe441f824a7877322ac7c290af424..62befc2f2278fb1a47fedfdb6bb27f62717d01e1 100644 (file)
@@ -571,10 +571,8 @@ processEvents(
                        }
 
                        /* dispatch event to XIM server */
-                       if ((XFilterEvent(&xevent, (Window)NULL) == True) && (xevent.type != KeyRelease)) {
-                               /* do nothing now, the event is consumed by XIM.
-                                * however, KeyRelease event should be processed
-                                * here, otherwise modifiers remain activated.   */
+                       if ((XFilterEvent(&xevent, (Window)NULL) == True)) {
+                               /* do nothing now, the event is consumed by XIM. */
                                continue;
                        }
 #endif