提交 b5c672d2 编写于 作者: D Daniel Imms

Show default cursor when alt is held in terminal

Fixes #44586
上级 72010357
......@@ -100,6 +100,11 @@
text-decoration: underline;
}
/* Use the default cursor when alt is active to help with clicking to move cursor */
.monaco-workbench .panel.integrated-terminal .terminal-outer-container.alt-active .xterm {
cursor: default;
}
.monaco-workbench .panel.integrated-terminal .xterm {
position: absolute;
bottom: 0;
......
......@@ -262,6 +262,12 @@ export class TerminalPanel extends Panel {
}
this._cancelContextMenu = false;
}));
this._register(dom.addDisposableListener(document, 'keydown', (event: KeyboardEvent) => {
this._terminalContainer.classList.toggle('alt-active', !!event.altKey);
}));
this._register(dom.addDisposableListener(document, 'keyup', (event: KeyboardEvent) => {
this._terminalContainer.classList.toggle('alt-active', !!event.altKey);
}));
this._register(dom.addDisposableListener(this._parentDomElement, 'keyup', (event: KeyboardEvent) => {
if (event.keyCode === 27) {
// Keep terminal open on escape
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册