Microsoft/vscode

Some Mac keyboard shortcuts does not work in the new Terminal Editor after being moved with `workbench.action.moveEditorTo<Side>Group` until the terminal editor has been unfocused and focused again

Open

#183,268 创建于 2023年5月23日

在 GitHub 查看
 (3 评论) (0 反应) (1 负责人)TypeScript (74,848 star) (10,221 fork)batch import
bughelp wantedterminal-editors

描述

Does this issue occur when all extensions are disabled?: Yes

Version: 1.78.2
Commit: b3e4e68a0bc097f0ae7907b217c1119af9e03435
Date: 2023-05-10T15:00:40.428Z
Electron: 22.5.2
Chromium: 108.0.5359.215
Node.js: 16.17.1
V8: 10.8.168.25-electron.0
OS: Darwin arm64 22.4.0
Sandboxed: No

Steps to Reproduce:

  1. [
    	// #region Move between panes
    	{ "key": "cmd+alt+up", "command": "workbench.action.navigateUp" },
    	{ "key": "cmd+alt+right", "command": "workbench.action.navigateRight" },
    	{ "key": "cmd+alt+down", "command": "workbench.action.navigateDown" },
    	{ "key": "cmd+alt+left", "command": "workbench.action.navigateLeft" },
    	// #endregion
    
    	// #region Spawn terminal
    	{
    		// spawn terminal in current editor group, replace text editor if untitled and unedited.
    		"key": "cmd+alt+t",
    		"when": "editorTextFocus && resourceScheme == untitled && !activeEditorIsDirty",
    		"command": "runCommands",
    		"args": {
    			"commands": [
    				"workbench.action.createTerminalEditor",
    				"workbench.action.closeActiveEditor"
    			]
    		}
    	},
    	{
    		// spawn terminal in current editor group, replace text editor if untitled and unedited.
    		"key": "cmd+alt+t",
    		"when": "resourceScheme != untitled",
    		"command": "workbench.action.createTerminalEditor"
    	},
    	// #endregion
    
    	// #region Create new pane with untitled file (CTRL + SHIFT + OPT + CMD + <direction>)
    	{
    		"key": "ctrl+shift+alt+cmd+up",
    		"when": "editorTextFocus || terminalEditorFocus",
    		"command": "runCommands",
    		"args": {
    			"commands": [
    				"workbench.action.newGroupAbove",
    				"workbench.action.previousEditor",
    				"workbench.action.moveEditorToAboveGroup"
    			]
    		}
    	},
    	{
    		"key": "ctrl+shift+alt+cmd+right",
    		"when": "editorTextFocus || terminalEditorFocus",
    		"command": "runCommands",
    		"args": {
    			"commands": [
    				"workbench.action.newGroupRight",
    				"workbench.action.previousEditor",
    				"workbench.action.moveEditorToRightGroup"
    			]
    		}
    	},
    	{
    		"key": "ctrl+shift+alt+cmd+down",
    		"when": "editorTextFocus || terminalEditorFocus",
    		"command": "runCommands",
    		"args": {
    			"commands": [
    				"workbench.action.newGroupBelow",
    				"workbench.action.previousEditor",
    				"workbench.action.moveEditorToBelowGroup"
    			]
    		}
    	},
    	{
    		"key": "ctrl+shift+alt+cmd+left",
    		"when": "editorTextFocus || terminalEditorFocus",
    		"command": "runCommands",
    		"args": {
    			"commands": [
    				"workbench.action.newGroupLeft",
    				"workbench.action.previousEditor",
    				"workbench.action.moveEditorToLeftGroup"
    			]
    		}
    	},
    	// endregion
    
    	// #region Move current editor to pane (CTRL + SHIFT + CMD + <direction>)
    	{
    		"key": "ctrl+shift+cmd+up",
    		"when": "editorTextFocus || terminalEditorFocus",
    		"command": "workbench.action.moveEditorToAboveGroup"
    	},
    	{
    		"key": "ctrl+shift+cmd+right",
    		"when": "editorTextFocus || terminalEditorFocus",
    		"command": "workbench.action.moveEditorToRightGroup"
    	},
    	{
    		"key": "ctrl+shift+cmd+down",
    		"when": "editorTextFocus || terminalEditorFocus",
    		"command": "workbench.action.moveEditorToBelowGroup"
    	},
    	{
    		"key": "ctrl+shift+cmd+left",
    		"when": "editorTextFocus || terminalEditorFocus",
    		"command": "workbench.action.moveEditorToLeftGroup"
    	}
    	// #endregion
    ]
    
  2. Open terminal by using keybind from config, OPTION + COMMAND + T.

  3. Open one more terminal.

  4. Test that keybinds such as COMMAND + BACKSPACE works to remove text from cursor to beginning of line.

  5. Move the terminal to a new editor group by using keybind from config, SHIFT + CONTROL + COMMAND + <SIDE>.

  6. Keybinds such as COMMAND + BACKSPACE no longer works.

  7. Unfocus the moved terminal and go the other terminal.

  8. Go back to the moved terminal.

  9. Keybinds such as COMMAND + BACKSPACE should now work again.

See video (it displays keypresses)

https://github.com/microsoft/vscode/assets/125522276/377851a8-2633-4736-bae4-c4accf656b93

贡献者指南