Don't glom new tabs into the _quake window - #20670
Open
Niu Shuai (niushuai1991) wants to merge 3 commits into
Open
Don't glom new tabs into the _quake window#20670Niu Shuai (niushuai1991) wants to merge 3 commits into
Niu Shuai (niushuai1991) wants to merge 3 commits into
Conversation
When windowingBehavior is set to useExisting or useAnyExisting, new terminal instances glom to the most recently used window. Since pressing win+` activates the _quake window, it's almost always the most recently used one, so new tabs ended up glomming into the _quake window, where the tab row is not visible and tabs can't be switched. Monarch::_getMostRecentPeasantID used to explicitly skip the _quake window when finding a glomming target (originally added in microsoft#9956, then parameterized in microsoft#10108 to keep summoning working), but that exclusion was lost when the Monarch/Peasant layer was removed in microsoft#18215. This restores the old semantics by giving _mostRecentWindow an ignoreQuakeWindow argument: * glomming (useExisting / useAnyExisting) passes true, skipping _quake * summoning the MRU window still passes false, so globalSummon and the notification area keep working as before * `wt -w _quake` still targets the quake window via GetWindowByName
|
Azure Pipelines: There may be pipelines that require an authorized user to comment /azp run to run. |
This comment has been minimized.
This comment has been minimized.
Author
|
@microsoft-github-policy-service agree |
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.
Summary of the Pull Request
When
windowingBehavioris set touseExistingoruseAnyExisting, new terminal instances glom into the most recently used window. Since pressing Win + ` activates the_quakewindow, it is almost always the most recently used one — so new tabs ended up inside the quake dropdown, where the tab row is not visible and tabs cannot be switched.This PR restores the old semantics: the
_quakewindow is never treated as the MRU glomming target.References and Relevant Issues
_quakewindow from glomming #9956 originally made the Monarch skip the_quakewindow when picking a glomming targetDetailed Description of the Pull Request / Additional comments
WindowEmperor::_mostRecentWindow()gains anignoreQuakeWindowargument:true, so_quakeis skipped as a target:WindowingMode::UseAnyExistingin_dispatchCommandline_dispatchCommandlineCurrentDesktopfalse, soglobalSummonand the notification area still summon the quake window when it is the MRU one_dispatchSpecialKeyalso passesfalse, unchanged behavior when the quake window is focusedwt -w _quakestill targets the quake window explicitly viaGetWindowByNameValidation Steps Performed
All tested manually with a local build:
useAnyExisting: open a regular window, summon quake via Win + ` (making it the MRU window), then launch a new instance → the new tab gloms into the regular window, not the quake window (before this change it went into the quake window)useExisting(per-virtual-desktop path): same steps, same resultwt -w _quakestill creates a new tab in the quake windowPR Checklist