mirror of
https://github.com/Eugeny/tabby
synced 2024-12-13 14:52:45 +00:00
debounce terminal resize events
This commit is contained in:
parent
13eebd8957
commit
54d71adb26
1 changed files with 2 additions and 2 deletions
|
@ -1,4 +1,4 @@
|
|||
import { Observable, Subject, Subscription, first } from 'rxjs'
|
||||
import { Observable, Subject, Subscription, first, auditTime } from 'rxjs'
|
||||
import { Spinner } from 'cli-spinner'
|
||||
import colors from 'ansi-colors'
|
||||
import { NgZone, OnInit, OnDestroy, Injector, ViewChild, HostBinding, Input, ElementRef, InjectFlags } from '@angular/core'
|
||||
|
@ -664,7 +664,7 @@ export class BaseTerminalTabComponent extends BaseTabComponent implements OnInit
|
|||
this.sendInput(data)
|
||||
})
|
||||
|
||||
this.termContainerSubscriptions.subscribe(this.frontend.resize$, ({ columns, rows }) => {
|
||||
this.termContainerSubscriptions.subscribe(this.frontend.resize$.pipe(auditTime(100)), ({ columns, rows }) => {
|
||||
this.logger.debug(`Resizing to ${columns}x${rows}`)
|
||||
this.size = { columns, rows }
|
||||
this.zone.run(() => {
|
||||
|
|
Loading…
Reference in a new issue