[Bf-blender-cvs] [3f33b4573da] blender2.8: Keymap: Change default spacebar action to play

Campbell Barton noreply at git.blender.org
Tue Nov 27 22:02:19 CET 2018


Commit: 3f33b4573dab17e39bfde0e2e85bf16d728df0aa
Author: Campbell Barton
Date:   Wed Nov 28 06:57:25 2018 +1100
Branches: blender2.8
https://developer.blender.org/rB3f33b4573dab17e39bfde0e2e85bf16d728df0aa

Keymap: Change default spacebar action to play

This has been a contentious topic: Artists at the Blender-Studio prefer
this behavior, while the user community overwhelmingly prefers 2.7x
operator search. Previously this defaulted to accessing tools
(eg: Space-T activates transform.. Space-R rotate etc) which I still
believe is a better long term default - otherwise we don't have
efficient tool switching for a system we intend to make more use of,
nevertheless as far as I can tell users haven't been keen on adopting
this so far. Show the preference on the setup screen since many users
don't animate and will may want to quickly search or switch tools.

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

M	release/scripts/presets/keyconfig/blender.py
M	release/scripts/startup/bl_operators/wm.py

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

diff --git a/release/scripts/presets/keyconfig/blender.py b/release/scripts/presets/keyconfig/blender.py
index d0d1fa6fe59..6e9faa22762 100644
--- a/release/scripts/presets/keyconfig/blender.py
+++ b/release/scripts/presets/keyconfig/blender.py
@@ -34,23 +34,25 @@ class Prefs(bpy.types.KeyConfigPreferences):
     spacebar_action: EnumProperty(
         name="Spacebar",
         items=(
-            ('TOOL', "Tool-Bar",
+            ('PLAY', "Play",
+             "Toggle animation playback "
+             "('Shift-Space' for Tools)",
+             1),
+            ('TOOL', "Tools",
              "Open the popup tool-bar\n"
              "When 'Space' is held and used as a modifier:\n"
              "\u2022 Pressing the tools binding key switches to it immediately.\n"
              "\u2022 Dragging the cursor over a tool and releasing activates it (like a pie menu).\n"
-            ),
-            ('PLAY', "Playback",
-             "Toggle animation playback"
-            ),
-            ('SEARCH', "Operator Search",
-             "Open the operator search popup"
-            ),
+             "For Play use 'Shift-Space'",
+             0),
+            ('SEARCH', "Search",
+             "Open the operator search popup",
+             2),
         ),
         description=(
-            "Action when 'Space' is pressed ('Shift-Space' is used for the other action)"
+            "Action when 'Space' is pressed"
         ),
-        default='TOOL',
+        default='PLAY',
         update=update_fn,
     )
     use_select_all_toggle: BoolProperty(
diff --git a/release/scripts/startup/bl_operators/wm.py b/release/scripts/startup/bl_operators/wm.py
index 54797f20925..88c28946788 100644
--- a/release/scripts/startup/bl_operators/wm.py
+++ b/release/scripts/startup/bl_operators/wm.py
@@ -2554,9 +2554,17 @@ class WM_MT_splash(Menu):
             row = sub.row()
             row.alignment = 'RIGHT'
             row.label(text="Select With")
-            sub.row().prop(kc_prefs, 'select_mouse', expand=True)
+            sub.row().prop(kc_prefs, "select_mouse", expand=True)
             has_select_mouse = True
 
+        has_spacebar_action = hasattr(kc_prefs, "spacebar_action")
+        if has_spacebar_action:
+            sub = col.split(factor=0.35)
+            row = sub.row()
+            row.alignment = 'RIGHT'
+            row.label(text="Spacebar")
+            sub.row().prop(kc_prefs, "spacebar_action", expand=True)
+            has_select_mouse = True
 
         col.separator()
 
@@ -2580,6 +2588,8 @@ class WM_MT_splash(Menu):
         # Keep height constant
         if not has_select_mouse:
             col.label()
+        if not has_spacebar_action:
+            col.label()
 
         layout.label()



More information about the Bf-blender-cvs mailing list