diff options
author | Campbell Barton <ideasman42@gmail.com> | 2021-07-15 11:58:18 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2021-07-15 12:13:22 +0300 |
commit | 757ec00f830219ab078d52c1fd904af019fc6d47 (patch) | |
tree | ed02676bb3d14e5f9a4b5f2f3865bd5e3a3d3898 /release | |
parent | de913516dd2e15d2c81e2854cc6208ce428243bb (diff) |
Revert "Keymap: use D-Key for view-pie menu"
This reverts commit f92f5d1ac62c66ceb7a6ac1ff69084fbd5e3614a.
See: T89757 for rationale for reverting this change.
Diffstat (limited to 'release')
-rw-r--r-- | release/scripts/presets/keyconfig/Blender.py | 6 | ||||
-rw-r--r-- | release/scripts/presets/keyconfig/keymap_data/blender_default.py | 36 |
2 files changed, 12 insertions, 30 deletions
diff --git a/release/scripts/presets/keyconfig/Blender.py b/release/scripts/presets/keyconfig/Blender.py index 222ee43432f..eb66c961472 100644 --- a/release/scripts/presets/keyconfig/Blender.py +++ b/release/scripts/presets/keyconfig/Blender.py @@ -103,8 +103,8 @@ class Prefs(bpy.types.KeyConfigPreferences): v3d_tilde_action: EnumProperty( name="Tilde Action", items=( - ('OBJECT_SWITCH', "Object Switch", - "Switch the active object under the cursor (when not in object mode)", + ('VIEW', "Navigate", + "View operations (useful for keyboards without a numpad)", 0), ('GIZMO', "Gizmos", "Control transform gizmos", @@ -113,7 +113,7 @@ class Prefs(bpy.types.KeyConfigPreferences): description=( "Action when 'Tilde' is pressed" ), - default='OBJECT_SWITCH', + default='VIEW', update=update_fn, ) diff --git a/release/scripts/presets/keyconfig/keymap_data/blender_default.py b/release/scripts/presets/keyconfig/keymap_data/blender_default.py index 0af7493ed47..36cf1f46de6 100644 --- a/release/scripts/presets/keyconfig/keymap_data/blender_default.py +++ b/release/scripts/presets/keyconfig/keymap_data/blender_default.py @@ -1084,7 +1084,13 @@ def km_view3d(params): {"properties": [("use_all_regions", True), ("center", False)]}), ("view3d.view_all", {"type": 'C', "value": 'PRESS', "shift": True}, {"properties": [("center", True)]}), - op_menu_pie("VIEW3D_MT_view_pie", {"type": 'D', "value": 'CLICK_DRAG'}), + op_menu_pie( + "VIEW3D_MT_view_pie" if params.v3d_tilde_action == 'VIEW' else "VIEW3D_MT_transform_gizmo_pie", + {"type": 'ACCENT_GRAVE', "value": params.pie_value}, + ), + *(() if not params.use_pie_click_drag else + (("view3d.navigate", {"type": 'ACCENT_GRAVE', "value": 'CLICK'}, None),)), + ("view3d.navigate", {"type": 'ACCENT_GRAVE', "value": 'PRESS', "shift": True}, None), ("view3d.navigate", {"type": 'ACCENT_GRAVE', "value": 'PRESS', "shift": True}, None), # Numpad views. ("view3d.view_camera", {"type": 'NUMPAD_0', "value": 'PRESS'}, None), @@ -1328,32 +1334,6 @@ def km_view3d(params): op_tool_cycle("builtin.select_box", {"type": 'W', "value": 'PRESS'}), ]) - # Tilda key. - if params.use_pie_click_drag: - items.extend([ - ("object.transfer_mode", - {"type": 'ACCENT_GRAVE', "value": 'CLICK' if params.use_pie_click_drag else 'PRESS'}, - None), - op_menu_pie( - "VIEW3D_MT_transform_gizmo_pie", - {"type": 'ACCENT_GRAVE', "value": 'CLICK_DRAG'}, - ) - ]) - else: - if params.v3d_tilde_action == 'OBJECT_SWITCH': - items.append( - ("object.transfer_mode", - {"type": 'ACCENT_GRAVE', "value": 'PRESS'}, - {"properties": [("use_eyedropper", False)]}) - ) - else: - items.append( - op_menu_pie( - "VIEW3D_MT_transform_gizmo_pie", - {"type": 'ACCENT_GRAVE', "value": 'PRESS'}, - ) - ) - return keymap @@ -4528,6 +4508,8 @@ def km_sculpt(params): ) items.extend([ + # Transfer Sculpt Mode (release to avoid conflict with grease pencil drawing). + ("object.transfer_mode", {"type": 'D', "value": 'RELEASE'}, None), # Brush strokes ("sculpt.brush_stroke", {"type": 'LEFTMOUSE', "value": 'PRESS'}, {"properties": [("mode", 'NORMAL')]}), |