mirror of
https://github.com/Eugeny/tabby.git
synced 2024-11-10 12:16:34 +03:00
expose sessionChanged$
This commit is contained in:
parent
975b5a117d
commit
0c963dcbcc
@ -90,6 +90,7 @@ export class BaseTerminalTabComponent extends BaseTabComponent implements OnInit
|
|||||||
|
|
||||||
protected logger: Logger
|
protected logger: Logger
|
||||||
protected output = new Subject<string>()
|
protected output = new Subject<string>()
|
||||||
|
protected sessionChanged = new Subject<BaseSession|null>()
|
||||||
private sessionCloseSubscription: Subscription
|
private sessionCloseSubscription: Subscription
|
||||||
private hotkeysSubscription: Subscription
|
private hotkeysSubscription: Subscription
|
||||||
private bellPlayer: HTMLAudioElement
|
private bellPlayer: HTMLAudioElement
|
||||||
@ -122,6 +123,8 @@ export class BaseTerminalTabComponent extends BaseTabComponent implements OnInit
|
|||||||
|
|
||||||
get frontendReady$ (): Observable<void> { return this.frontendReady }
|
get frontendReady$ (): Observable<void> { return this.frontendReady }
|
||||||
|
|
||||||
|
get sessionChanged$ (): Observable<BaseSession|null> { return this.sessionChanged }
|
||||||
|
|
||||||
constructor (protected injector: Injector) {
|
constructor (protected injector: Injector) {
|
||||||
super()
|
super()
|
||||||
|
|
||||||
@ -581,6 +584,7 @@ export class BaseTerminalTabComponent extends BaseTabComponent implements OnInit
|
|||||||
this.detachSessionHandlers()
|
this.detachSessionHandlers()
|
||||||
this.session = null
|
this.session = null
|
||||||
}
|
}
|
||||||
|
this.sessionChanged.next(session)
|
||||||
}
|
}
|
||||||
|
|
||||||
protected attachSessionHandler (subscription: Subscription): void {
|
protected attachSessionHandler (subscription: Subscription): void {
|
||||||
|
Loading…
Reference in New Issue
Block a user