diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-11-16 00:28:58 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2018-11-16 00:31:00 +0300 |
commit | 088be7eb2f650f7849e3af33cbea76f7b3af0822 (patch) | |
tree | d0248368b79c2787dc87b4ba57cd3d836e36e0f4 /release/scripts/startup/bl_ui/space_userpref.py | |
parent | 8ecc51e87fd0e3e9bb13622456d03d09926eab47 (diff) |
Keymaps: replace select / action mouse system
For Blender builtin configurations the option to choose the select mouse remains
and is now also in the splash screen. It works by changing the keymap dynamically
in the script, rather than using special events.
The system of automatic switching of events was not flexible enough to deal with
side effects that require further keymap changes, so it is now under more manual
control in the script.
This breaks compatibility for some scripts and exported key configurations.
These can be fixed by replacing SELECTMOUSE, ACTIONMOUSE, EVT_TWEAK_S and
EVT_TWEAK_A with appropriate LEFTMOUSE, RIGHTMOUSE, EVT_TWEAK_L and
EVT_TWEAK_R events.
Other than that, there should be no functional changes.
Diffstat (limited to 'release/scripts/startup/bl_ui/space_userpref.py')
-rw-r--r-- | release/scripts/startup/bl_ui/space_userpref.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/release/scripts/startup/bl_ui/space_userpref.py b/release/scripts/startup/bl_ui/space_userpref.py index 149206fc151..e661ccec37c 100644 --- a/release/scripts/startup/bl_ui/space_userpref.py +++ b/release/scripts/startup/bl_ui/space_userpref.py @@ -1087,15 +1087,15 @@ class USERPREF_PT_input(Panel): sub.separator() sub.label(text="Mouse:") - sub1 = sub.column() - sub1.active = (inputs.select_mouse == 'RIGHT') - sub1.prop(inputs, "use_mouse_emulate_3_button") + sub.prop(inputs, "use_mouse_emulate_3_button") sub.prop(inputs, "use_mouse_continuous") sub.prop(inputs, "drag_threshold") sub.prop(inputs, "tweak_threshold") - sub.label(text="Select With:") - sub.row().prop(inputs, "select_mouse", expand=True) + wm = bpy.context.window_manager + if wm.keyconfigs.active.has_select_mouse: + sub.label(text="Select With:") + sub.row().prop(inputs, "select_mouse", expand=True) sub = col.column() sub.label(text="Double Click:") |