diff options
-rw-r--r-- | intern/ghost/intern/GHOST_SystemX11.cpp | 3 | ||||
-rw-r--r-- | source/blender/windowmanager/intern/wm_event_system.c | 7 |
2 files changed, 8 insertions, 2 deletions
diff --git a/intern/ghost/intern/GHOST_SystemX11.cpp b/intern/ghost/intern/GHOST_SystemX11.cpp index 5d14ff5bb93..129261480b9 100644 --- a/intern/ghost/intern/GHOST_SystemX11.cpp +++ b/intern/ghost/intern/GHOST_SystemX11.cpp @@ -1841,6 +1841,9 @@ convertXKey(KeySym key) GXMAP(type, XF86XK_AudioForward, GHOST_kKeyMediaLast); #endif #endif + /* Non US keyboard layouts: avoid 'UnknownKey' - TODO(campbell): lookup scan-codes. */ + GXMAP(type, XK_dead_circumflex, GHOST_kKeyAccentGrave); /* 'de' */ + GXMAP(type, XK_twosuperior, GHOST_kKeyAccentGrave); /* 'fr' */ default: type = GHOST_kKeyUnknown; break; diff --git a/source/blender/windowmanager/intern/wm_event_system.c b/source/blender/windowmanager/intern/wm_event_system.c index fdca1d96b4b..37d594df688 100644 --- a/source/blender/windowmanager/intern/wm_event_system.c +++ b/source/blender/windowmanager/intern/wm_event_system.c @@ -2559,8 +2559,11 @@ static int wm_handlers_do(bContext *C, wmEvent *event, ListBase *handlers) if (win != NULL) { if (event->val == KM_PRESS) { - win->eventstate->check_click = true; - win->eventstate->check_drag = true; + /* Ensure the types match to prevent mouse wheel from triggering drag/clicks. */ + if (event->type == win->eventstate->prevtype) { + win->eventstate->check_click = true; + win->eventstate->check_drag = true; + } } else if (event->val == KM_RELEASE) { win->eventstate->check_drag = false; |