mirror of
https://github.com/Eugeny/tabby.git
synced 2025-10-05 14:34:54 +00:00
Option to disable middle click paste (#1928)
Option to disable middle click paste
This commit is contained in:
@@ -353,7 +353,9 @@ export class BaseTerminalTabComponent extends BaseTabComponent implements OnInit
|
|||||||
this.frontend.mouseEvent$.subscribe(async event => {
|
this.frontend.mouseEvent$.subscribe(async event => {
|
||||||
if (event.type === 'mousedown') {
|
if (event.type === 'mousedown') {
|
||||||
if (event.which === 2) {
|
if (event.which === 2) {
|
||||||
this.paste()
|
if (this.config.store.terminal.pasteOnMiddleClick) {
|
||||||
|
this.paste()
|
||||||
|
}
|
||||||
event.preventDefault()
|
event.preventDefault()
|
||||||
event.stopPropagation()
|
event.stopPropagation()
|
||||||
return
|
return
|
||||||
|
@@ -64,6 +64,15 @@ h3.mb-3 Terminal
|
|||||||
)
|
)
|
||||||
| Paste
|
| Paste
|
||||||
|
|
||||||
|
.form-line
|
||||||
|
.header
|
||||||
|
.title Paste on middle-click
|
||||||
|
|
||||||
|
toggle(
|
||||||
|
[(ngModel)]='config.store.terminal.pasteOnMiddleClick',
|
||||||
|
(ngModelChange)='config.save()',
|
||||||
|
)
|
||||||
|
|
||||||
.form-line
|
.form-line
|
||||||
.header
|
.header
|
||||||
.title Auto-open a terminal on app start
|
.title Auto-open a terminal on app start
|
||||||
|
@@ -25,6 +25,7 @@ export class TerminalConfigProvider extends ConfigProvider {
|
|||||||
cursorBlink: true,
|
cursorBlink: true,
|
||||||
customShell: '',
|
customShell: '',
|
||||||
rightClick: 'menu',
|
rightClick: 'menu',
|
||||||
|
pasteOnMiddleClick: true,
|
||||||
copyOnSelect: false,
|
copyOnSelect: false,
|
||||||
scrollOnInput: true,
|
scrollOnInput: true,
|
||||||
workingDirectory: '',
|
workingDirectory: '',
|
||||||
@@ -113,6 +114,7 @@ export class TerminalConfigProvider extends ConfigProvider {
|
|||||||
shell: 'clink',
|
shell: 'clink',
|
||||||
profile: 'cmd-clink',
|
profile: 'cmd-clink',
|
||||||
rightClick: 'paste',
|
rightClick: 'paste',
|
||||||
|
pasteOnMiddleClick: false,
|
||||||
copyOnSelect: true,
|
copyOnSelect: true,
|
||||||
},
|
},
|
||||||
hotkeys: {
|
hotkeys: {
|
||||||
|
Reference in New Issue
Block a user