diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-06-07 05:04:59 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-06-07 05:16:25 +0300 |
commit | 99eb4e9cc4e0fd3723c4591475bd6e359dd7477d (patch) | |
tree | 513ab5b393d5edf4bdde58f0e7388f2ed375eaa8 /release/scripts | |
parent | 6dd9e08051d20e0c673660b2826470965e1eb8ca (diff) |
Keymap: expose gizmo press/drag as a preference
- Right click select always activates on press
since this was added as a workaround to left click select conflict.
- Left click has the option to set this to drag or press.
Make this change based on feedback on 8778dd0c8b461.
Diffstat (limited to 'release/scripts')
-rw-r--r-- | release/scripts/presets/keyconfig/blender.py | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/release/scripts/presets/keyconfig/blender.py b/release/scripts/presets/keyconfig/blender.py index 75ea8e9f498..fa004c25393 100644 --- a/release/scripts/presets/keyconfig/blender.py +++ b/release/scripts/presets/keyconfig/blender.py @@ -64,6 +64,25 @@ class Prefs(bpy.types.KeyConfigPreferences): update=update_fn, ) + gizmo_action: EnumProperty( + name="Activate Gizmo", + items=( + ('PRESS', "Press", "Press causes immediate activation, preventing click being passed to the tool"), + ('DRAG', "Drag", "Drag allows click events to pass through to the tool, adding a small delay"), + ), + description="Activation event for gizmos that support drag motion", + update=update_fn, + ) + + use_gizmo_drag: BoolProperty( + name="Drag Gizmos", + description=( + "Causes gizmos such" + ), + default=True, + update=update_fn, + ) + # 3D View use_v3d_tab_menu: BoolProperty( name="Tab for Pie Menu", @@ -114,10 +133,20 @@ class Prefs(bpy.types.KeyConfigPreferences): ) def draw(self, layout): + is_select_left = (self.select_mouse == 'LEFT') + split = layout.split() col = split.column(align=True) col.label(text="Select With:") col.row().prop(self, "select_mouse", expand=True) + + if is_select_left: + col.label(text="Activate Gizmo:") + col.row().prop(self, "gizmo_action", expand=True) + else: + col.label() + col.label() + col.prop(self, "use_select_all_toggle") col = split.column(align=True) @@ -156,6 +185,10 @@ def load(): use_select_all_toggle=kc_prefs.use_select_all_toggle, use_v3d_tab_menu=kc_prefs.use_v3d_tab_menu, use_v3d_shade_ex_pie=kc_prefs.use_v3d_shade_ex_pie, + use_gizmo_drag=( + kc_prefs.select_mouse == 'LEFT' and + kc_prefs.gizmo_action == 'DRAG' + ), use_pie_click_drag=kc_prefs.use_pie_click_drag, ), ) |