expose sessionChanged$

This commit is contained in:
Eugene Pankov 2021-03-10 20:51:44 +01:00
parent 975b5a117d
commit 0c963dcbcc
No known key found for this signature in database
GPG key ID: 5896FCBBDD1CF4F4

View file

@ -90,6 +90,7 @@ export class BaseTerminalTabComponent extends BaseTabComponent implements OnInit
protected logger: Logger
protected output = new Subject<string>()
protected sessionChanged = new Subject<BaseSession|null>()
private sessionCloseSubscription: Subscription
private hotkeysSubscription: Subscription
private bellPlayer: HTMLAudioElement
@ -122,6 +123,8 @@ export class BaseTerminalTabComponent extends BaseTabComponent implements OnInit
get frontendReady$ (): Observable<void> { return this.frontendReady }
get sessionChanged$ (): Observable<BaseSession|null> { return this.sessionChanged }
constructor (protected injector: Injector) {
super()
@ -581,6 +584,7 @@ export class BaseTerminalTabComponent extends BaseTabComponent implements OnInit
this.detachSessionHandlers()
this.session = null
}
this.sessionChanged.next(session)
}
protected attachSessionHandler (subscription: Subscription): void {