UI: Hide asset shelf toggles if not available #113063

Open
Julian Eisel wants to merge 1 commits from JulianEisel/blender:temp-asset-shelf-toggle-hide into blender-v4.0-release

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.
Member

The "Asset Shelf" checkbox can be confusing for people, they enable it
but it still can't get the shelf to show up. This is because the shelf is only
available in certain context (pose mode only for the start). For now
hide the option entirely unless the asset shelf becomes available.

This change adds a new bpy.types.Region.poll_failed property to query
the availability of a region.

The "Asset Shelf" checkbox can be confusing for people, they enable it but it still can't get the shelf to show up. This is because the shelf is only available in certain context (pose mode only for the start). For now hide the option entirely unless the asset shelf becomes available. This change adds a new `bpy.types.Region.poll_failed` property to query the availability of a region.
Julian Eisel added 1 commit 2023-09-29 15:59:00 +02:00
df1d882acd UI: Hide asset shelf toggles if not available
The "Asset Shelf" checkbox can be confusing for people, they enable it
but it still can't get the shelf to show up. This is because it is only
available in certain context (pose mode only for the start). For now
hide the option entirely unless the asset shelf becomes available.

This change adds a new `bpy.types.Region.poll_failed` property to query
the availability of a region.
Julian Eisel requested review from Campbell Barton 2023-09-29 15:59:30 +02:00
Dalai Felinto approved these changes 2023-10-05 14:27:42 +02:00
Dismissed
Dalai Felinto left a comment
Owner

Go for it then Sorry, I typed on the wrong patch.

~~Go for it then~~ Sorry, I typed on the wrong patch.
Member

I'd rather say grey it out.
The same is the case for the extended shading pie menu and Xray. While using Eevee or Cycles in the viewport the Xray toggle is still in the pie menu but greyed out and toggling it won't have a visible effect.

I'd rather say grey it out. The same is the case for the extended shading pie menu and Xray. While using Eevee or Cycles in the viewport the Xray toggle is still in the pie menu but greyed out and toggling it won't have a visible effect.
Author
Member

I'd rather say grey it out.
The same is the case for the extended shading pie menu and Xray. While using Eevee or Cycles in the viewport the Xray toggle is still in the pie menu but greyed out and toggling it won't have a visible effect.

Generally I'd also prefer graying it out. However, the asset shelf is only used by default in pose mode right now and it's tricky to find that out. People would just see this grayed out option almost always, and be confused about it. At least when I tried it it felt that way. Add-ons may register own asset shelves, so if there is a disabled hint in the tooltip, it would be vague like "Not available in the current context". So it doesn't really solve the confusion.

Once the asset shelf is used more commonly, I'd say gray it out indeed. But for now, that would cause more harm than it's useful. For a (a bit weak) consistency argument: Other editors that change the available regions based on their mode also don't show these region toggles, e.g. the Sequencer Preview view type doesn't list the Channels and Adjust Last Operation toggles.

> I'd rather say grey it out. > The same is the case for the extended shading pie menu and Xray. While using Eevee or Cycles in the viewport the Xray toggle is still in the pie menu but greyed out and toggling it won't have a visible effect. Generally I'd also prefer graying it out. However, the asset shelf is only used by default in pose mode right now and it's tricky to find that out. People would just see this grayed out option almost always, and be confused about it. At least when I tried it it felt that way. Add-ons may register own asset shelves, so if there is a disabled hint in the tooltip, it would be vague like "Not available in the current context". So it doesn't really solve the confusion. Once the asset shelf is used more commonly, I'd say gray it out indeed. But for now, that would cause more harm than it's useful. For a (a bit weak) consistency argument: Other editors that change the available regions based on their mode also don't show these region toggles, e.g. the Sequencer _Preview_ view type doesn't list the _Channels_ and _Adjust Last Operation_ toggles.
Dalai Felinto requested review from Dalai Felinto 2023-10-05 16:34:09 +02:00
Dalai Felinto refused to review 2023-10-05 16:34:18 +02:00
Dalai Felinto dismissed dfelinto’s review 2023-10-05 16:35:22 +02:00
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u temp-asset-shelf-toggle-hide:JulianEisel-temp-asset-shelf-toggle-hide
git checkout JulianEisel-temp-asset-shelf-toggle-hide
Sign in to join this conversation.
No reviewers
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#113063
No description provided.