terminal_panel: Cmd+N opens new terminal where you are already working#48609
Merged
SomeoneToIgnore merged 1 commit intozed-industries:mainfrom Mar 24, 2026
Merged
Conversation
Contributor
SomeoneToIgnore
left a comment
There was a problem hiding this comment.
Nice change, thank you.
Let's do another small update of the logic while we're here and merge this.
| @@ -659,6 +659,29 @@ impl TerminalPanel { | |||
| return; | |||
Contributor
There was a problem hiding this comment.
Should the new approach also open the center terminal in this case?
Contributor
Author
There was a problem hiding this comment.
Moved it above the guard, thanks for catching this.
831b736 to
b32a7f1
Compare
Contributor
|
Looks like the formatting CI check is failing. |
Contributor
Author
|
Oops. Let me take a look. |
b32a7f1 to
defe9c8
Compare
Contributor
Author
|
Rebased on main — adapted tests to the MultiWorkspace refactor, no logic changes. |
📏 PR Size: 451 lines changed (Size L)Please note: this PR exceeds the 400 LOC soft limit.
|
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.
Related to #31504
Problem
If you drag a terminal into the center editor area as a tab, pressing
Cmd+Nstill opens the new terminal in the terminal panel instead of next to the tab you're looking at.Solution
Cmd+Nnow checks whether the center pane is focused and its active tab is a terminal. If both are true, the new terminal opens there. All other behavior is unchanged.demo-new-terminal-command.mp4
Test plan
Release Notes:
terminal: New Terminal(Cmd+N) to open in the center pane when a terminal tab there is focused, instead of always opening in the terminal panel.