Fix #33271: Box tool delay
authorSergey Sharybin <sergey.vfx@gmail.com>
Fri, 23 Nov 2012 10:00:15 +0000 (10:00 +0000)
committerSergey Sharybin <sergey.vfx@gmail.com>
Fri, 23 Nov 2012 10:00:15 +0000 (10:00 +0000)
Issue was introduced in svn rev51808 which was a fix for #33038

One of changes in that patch lead to a situation that if some keymap don't have
modifier key it wouldn't be triggered in cases modifier key was pressed.

source/blender/windowmanager/intern/wm_event_system.c

index 5cbad42134c364ef508a6568adf611f0965d8a44..b3c9cfbc79e5316cb06b663e17915fc49e21a1ec 100644 (file)
@@ -1310,7 +1310,8 @@ static int wm_eventmatch(wmEvent *winevent, wmKeyMapItem *kmi)
        if (kmi->oskey != KM_ANY)
                if (winevent->oskey != kmi->oskey && !(winevent->oskey & kmi->oskey)) return 0;
        
-       if (winevent->keymodifier != kmi->keymodifier) return 0;
+       if (kmi->keymodifier)
+               if (winevent->keymodifier != kmi->keymodifier) return 0;
                
        
        return 1;