Fix #20561: keymap editing after using search could edit wrong keymap item.
authorBrecht Van Lommel <brechtvanlommel@pandora.be>
Mon, 4 Jan 2010 16:48:14 +0000 (16:48 +0000)
committerBrecht Van Lommel <brechtvanlommel@pandora.be>
Mon, 4 Jan 2010 16:48:14 +0000 (16:48 +0000)
release/scripts/ui/space_userpref.py

index 4c807fd9bd2f57fb718744b9c28e5b42eb57e6d6..571abb39dab073590b2a701c60e33e7896f91d60 100644 (file)
@@ -1475,11 +1475,11 @@ class USERPREF_PT_input(bpy.types.Panel):
         filter = kc.filter.lower()
 
         for km in kc.keymaps:
+            km = km.active()
+
             filtered_items = [kmi for kmi in km.items if filter in kmi.name.lower()]
 
             if len(filtered_items) != 0:
-                km = km.active()
-
                 layout.set_context_pointer("keymap", km)
                 col = layout.column()