Exit scene live mode when leaving the editor - #53837
Open
MindFreeze wants to merge 2 commits into
Open
Conversation
piitaya
reviewed
Aug 27, 2026
piitaya
left a comment
Member
There was a problem hiding this comment.
Not sure the test are really necessary. Otherwise, I agree on the fix.
Member
|
@MindFreeze since you're working on this flow, could you please take a look at this? #53694 |
Leaving the page previously only unsubscribed, so live-activated device states stayed behind. Restore stored states unless the tab is hidden for panel suspend.
bramkragten
force-pushed
the
exit-scene-live-mode-on-leave
branch
from
August 27, 2026 15:04
020e774 to
7347aac
Compare
maartenla
reviewed
Aug 27, 2026
| }; | ||
|
|
||
| private _goBack(): void { | ||
| if (this._mode === "live") { |
Contributor
There was a problem hiding this comment.
Go back now triggers applyScene twice right?
So goBack should now or remove this if with apply or swap it to exitLiveMode.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Proposed change
Leaving the scene editor while live editing only unsubscribed from
state_changed. Devices stayed in the live-activated state. The back button already restored stored states; other ways of leaving (sidebar, switching scenes after #53826 remounts the editor) did not.This calls
_exitLiveModeon disconnect so stored pre-live states are applied again. It skips that restore whendocument.hiddenis true, so the five-minute hidden-tab panel suspend does not undo live mode.Stacked on #53826.
Type of change
Additional information
Checklist
If user exposed functionality or configuration variables are added/changed:
To help with the load of incoming pull requests: