Skip to content
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

ToolBarSceneSelection should check playmode change #30

Open
Flavelius opened this issue Oct 19, 2021 · 0 comments
Open

ToolBarSceneSelection should check playmode change #30

Flavelius opened this issue Oct 19, 2021 · 0 comments

Comments

@Flavelius
Copy link

Flavelius commented Oct 19, 2021

ToolBarSceneSelection's Draw handling of the dropdown conflicts with opening scenes for playing.
As this changes the lists content (rebuild), the scene is opened implicitly (again) by this action (GUI.changed).
This becomes noticable if the ToolbarStartFromFirstScene button is used. The internal reopening of the scene prolongs the playmode start and the regular unity toolbar buttons don't show the entering-playmode-state change (play-button being visually pressed down).
This little change works around this (in DrawSceneDropdown() - ToolbarSceneSelection.cs):
if ((scenePath) == scenesPopupDisplay[selectedSceneIndex].path && !EditorApplication.isPlayingOrWillChangePlaymode) // check for entering playmode here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant