diff options
author | Julian Eisel <julian@blender.org> | 2020-12-18 20:12:11 +0300 |
---|---|---|
committer | Julian Eisel <julian@blender.org> | 2020-12-18 20:28:04 +0300 |
commit | 2250b5cefee7f7cce31e388cb83515543ffe60f0 (patch) | |
tree | cbac53205d453f4b1c7ec221b6377a672d9eaa09 /release | |
parent | 7bee1489c1d81ecf2634df96ba039549c64313c3 (diff) |
UI: Redesigned data-block selectors
The previous design is rather old and has a couple of problems:
* Scalability: The current solution of adding little icon buttons next to the
data-block name field doesn't scale well. It only works if there's a small
number of operations. We need to be able to place more items there for better
data-block management. Especially with the introduction of library overrides.
* Discoverability: It's not obvious what some of the icons do. They appear and
disappear, but it's not obvious why some are available at times and others
not.
* Unclear Status: Currently their library status (linked, indirectly linked,
broken link, library override) isn't really clear.
* Unusual behavior: Some of the icon buttons allow Shift or Ctrl clicking to
invoke alternative behaviors. This is not a usual pattern in Blender.
This patch does the following changes:
* Adds a menu to the right of the name button to access all kinds of operations
(create, delete, unlink, user management, library overrides, etc).
* Make good use of the "disabled hint" for tooltips, to explain why buttons are
disabled. The UI team wants to establish this as a good practise.
* Use superimposed icons for duplicate and unlink, rather than extra buttons
(uses less space, looks less distracting and is a nice + consistent design
language).
* Remove fake user and user count button, they are available from the menu now.
* Support tooltips for superimposed icons (committed mouse hover feedback to
master already).
* Slightly increase size of the name button - it was already a bit small
before, and the move from real buttons to superimposed icons reduces usable
space for the name itself.
* More clearly differentiate between duplicate and creating a new data-block.
The latter is only available in the menu.
* Display library status icon on the left (linked, missing library, overridden,
asset)
* Disables "Make Single User" button - in review we weren't sure if there are
good use-cases for it, so better to see if we can remove it.
Note that I do expect some aspects of this design to change still. I think some
changes are problematic, but others disagreed. I will open a feedback thread on
devtalk to see what others think.
Differential Revision: https://developer.blender.org/D8554
Reviewed by: Bastien Montagne
Design discussed and agreed on with the UI team, also see T79959.
Diffstat (limited to 'release')
-rw-r--r-- | release/scripts/startup/bl_ui/properties_material.py | 2 | ||||
-rw-r--r-- | release/scripts/startup/bl_ui/properties_world.py | 2 | ||||
-rw-r--r-- | release/scripts/startup/bl_ui/space_dopesheet.py | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/release/scripts/startup/bl_ui/properties_material.py b/release/scripts/startup/bl_ui/properties_material.py index 47ab98386f4..e1f2862f826 100644 --- a/release/scripts/startup/bl_ui/properties_material.py +++ b/release/scripts/startup/bl_ui/properties_material.py @@ -133,7 +133,7 @@ class EEVEE_MATERIAL_PT_context_material(MaterialButtonsPanel, Panel): row = layout.row() if ob: - row.template_ID(ob, "active_material", new="material.new") + row.template_ID(ob, "active_material", new="material.new", duplicate="material.duplicate") if slot: icon_link = 'MESH_DATA' if slot.link == 'DATA' else 'OBJECT_DATA' diff --git a/release/scripts/startup/bl_ui/properties_world.py b/release/scripts/startup/bl_ui/properties_world.py index 9b61311c2d3..74293e02b60 100644 --- a/release/scripts/startup/bl_ui/properties_world.py +++ b/release/scripts/startup/bl_ui/properties_world.py @@ -51,7 +51,7 @@ class WORLD_PT_context_world(WorldButtonsPanel, Panel): space = context.space_data if scene: - layout.template_ID(scene, "world", new="world.new") + layout.template_ID(scene, "world", new="world.new", duplicate="world.duplicate") elif world: layout.template_ID(space, "pin_id") diff --git a/release/scripts/startup/bl_ui/space_dopesheet.py b/release/scripts/startup/bl_ui/space_dopesheet.py index 0c222e8c023..3f43240eaed 100644 --- a/release/scripts/startup/bl_ui/space_dopesheet.py +++ b/release/scripts/startup/bl_ui/space_dopesheet.py @@ -248,7 +248,7 @@ class DOPESHEET_HT_editor_buttons: layout.separator_spacer() - layout.template_ID(st, "action", new="action.new", unlink="action.unlink") + layout.template_ID(st, "action", new="action.new", duplicate="action.duplicate_assign", unlink="action.unlink") # Layer management if st.mode == 'GPENCIL': |