Commit: d335db09e0a59499ca74a597d7da43cbb05e7708
Author: Pratik Borhade
Date:   Fri Feb 3 15:45:59 2023 +0530
Branches: master
https://developer.blender.org/rBd335db09e0a59499ca74a597d7da43cbb05e7708

Fix T90893: Restoring a key in the keymap editor doesn't work if the key is 
only disabled

Reset `KMI_INACTIVE` flag when restore-item  button is called

Reviewed By: campbellbarton

Differential Revision: https://developer.blender.org/D16773

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

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

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

diff --git a/source/blender/windowmanager/intern/wm_keymap.c 
b/source/blender/windowmanager/intern/wm_keymap.c
index bb945456d46..c6513a908cf 100644
--- a/source/blender/windowmanager/intern/wm_keymap.c
+++ b/source/blender/windowmanager/intern/wm_keymap.c
@@ -2021,7 +2021,8 @@ void WM_keymap_item_restore_to_default(wmWindowManager 
*wm, wmKeyMap *keymap, wm
     kmi->oskey = orig->oskey;
     kmi->keymodifier = orig->keymodifier;
     kmi->maptype = orig->maptype;
-    kmi->flag = (kmi->flag & ~KMI_REPEAT_IGNORE) | (orig->flag & 
KMI_REPEAT_IGNORE);
+    kmi->flag = (kmi->flag & ~(KMI_REPEAT_IGNORE | KMI_INACTIVE)) |
+                (orig->flag & KMI_REPEAT_IGNORE);
 
     WM_keyconfig_update_tag(keymap, kmi);
   }

_______________________________________________
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
List details, subscription details or unsubscribe:
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to