-
Notifications
You must be signed in to change notification settings - Fork 92
Adding PB Editors available in the GOcontext for the actions overlay #690
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -314,7 +314,7 @@ | |
| var shouldDisplay = action.group != ToolbarGroup.Tool && action.group != ToolbarGroup.Selection; | ||
|
|
||
| var hidden = action.hidden; | ||
| hidden |= (action.group == ToolbarGroup.Object) ? !isGOContext : isGOContext; | ||
| hidden |= shouldDisplayAsEditor || (action.group == ToolbarGroup.Object) ? !isGOContext : isGOContext; | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This only fixes the panel/grid path. When the overlay is used as a horizontal or vertical toolbar, 🤖 Helpful? 👍/👎 |
||
|
|
||
| if (initActionButtons) | ||
| m_ActionButtons.Add( new ProBuilderActionButton(action) ); | ||
|
|
@@ -355,7 +355,7 @@ | |
| s_CurrentMode == DisplayMode.Icon ? DropdownMenuAction.Status.Checked : DropdownMenuAction.Status.Normal); | ||
| menu.AppendAction(L10n.Tr("Text Mode"), _ => { SetMode(DisplayMode.Text); }, | ||
| s_CurrentMode == DisplayMode.Text ? DropdownMenuAction.Status.Checked : DropdownMenuAction.Status.Normal); | ||
| menu.AppendAction(L10n.Tr("Text & Icon Mode"), _ => { SetMode(DisplayMode.Full); }, | ||
| menu.AppendAction(L10n.Tr("Text+Icon Mode"), _ => { SetMode(DisplayMode.Full); }, | ||
| s_CurrentMode == DisplayMode.Full ? DropdownMenuAction.Status.Checked : DropdownMenuAction.Status.Normal); | ||
| menu.AppendSeparator(); | ||
| } | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldDisplayAsEditoris true forToolbarGroup.Toolactions, and because?:binds after||this line evaluates as(shouldDisplayAsEditor || action.group == ToolbarGroup.Object) ? !isGOContext : isGOContext. With the defaultDisplay Editorssetting enabled, every editor action now getshidden |= !isGOContext, so those buttons disappear as soon as the ProBuilder tool context is active. That is a regression from the previous behavior; the change adds GO-context visibility by removing PB-context visibility. Please treat tool-group actions as a separate case so they stay available in both contexts.🤖 Helpful? 👍/👎