mirror of
https://github.com/Eugeny/tabby.git
synced 2025-06-21 11:59:53 +00:00
Fix middle click for closing tabs
This commit is contained in:
parent
4bf67b0904
commit
3aa4c6105b
@ -78,10 +78,19 @@ export class TabHeaderComponent {
|
||||
this.showRenameTabModal()
|
||||
}
|
||||
|
||||
@HostListener('auxclick', ['$event']) async onAuxClick ($event: MouseEvent) {
|
||||
@HostListener('mousedown', ['$event']) async onMouseDown ($event: MouseEvent) {
|
||||
if ($event.which === 2) {
|
||||
$event.preventDefault();
|
||||
}
|
||||
}
|
||||
|
||||
@HostListener('mouseup', ['$event']) async onMouseUp ($event: MouseEvent) {
|
||||
if ($event.which === 2) {
|
||||
this.app.closeTab(this.tab, true)
|
||||
}
|
||||
}
|
||||
|
||||
@HostListener('auxclick', ['$event']) async onAuxClick ($event: MouseEvent) {
|
||||
if ($event.which === 3) {
|
||||
$event.preventDefault()
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user