Fix T44251: Changing views using numpad broken
For KM_ANY I've filtered out every event that has a click type, although that was only needed for the additional event sent on KM_HOLD. A bit weird that this only happened on a few machines though.
This commit is contained in:
parent
59df941ea5
commit
1604a26fe6
Notes:
blender-bot
2023-09-13 08:48:34 +02:00
Referenced by issue #44251, '0'-key shortcut in 3DView (switch to/from camera view) broken - sticky keys?
|
@ -1460,8 +1460,8 @@ static int wm_eventmatch(wmEvent *winevent, wmKeyMapItem *kmi)
|
|||
if (kmitype != KM_ANY)
|
||||
if (winevent->type != kmitype) return 0;
|
||||
|
||||
/* KM_ANY excludes click_type events - filter them out */
|
||||
if (kmi->val == KM_ANY && winevent->click_type) return 0;
|
||||
/* KM_ANY excludes KM_HOLD since it's time based and not a real input - filter it out */
|
||||
if (kmi->val == KM_ANY && winevent->click_type == KM_HOLD) return 0;
|
||||
|
||||
if (kmi->val != KM_ANY)
|
||||
if (!ELEM(kmi->val, winevent->val, winevent->click_type)) return 0;
|
||||
|
|
Loading…
Reference in New Issue