ref(connectable tab) on frontend ready

This commit is contained in:
Clem Fern 2023-05-12 20:01:06 +02:00
parent 38302622b8
commit bd4b11813c
4 changed files with 5 additions and 15 deletions

View File

@ -53,11 +53,6 @@ export class SerialTabComponent extends ConnectableTerminalTabComponent<SerialPr
})
}
protected onFrontendReady (): void {
this.initializeSession()
super.onFrontendReady()
}
async initializeSession () {
super.initializeSession()

View File

@ -71,11 +71,6 @@ export class SSHTabComponent extends ConnectableTerminalTabComponent<SSHProfile>
super.ngOnInit()
}
protected onFrontendReady (): void {
this.initializeSession()
super.onFrontendReady()
}
async setupOneSession (injector: Injector, profile: SSHProfile, multiplex = true): Promise<SSHSession> {
let session = await this.sshMultiplexer.getSession(profile)
if (!multiplex || !session || !profile.options.reuseSession) {

View File

@ -37,11 +37,6 @@ export class TelnetTabComponent extends ConnectableTerminalTabComponent<TelnetPr
super.ngOnInit()
}
protected onFrontendReady (): void {
this.initializeSession()
super.onFrontendReady()
}
protected onSessionDestroyed (): void {
if (this.frontend) {
// Session was closed abruptly

View File

@ -25,6 +25,11 @@ export abstract class ConnectableTerminalTabComponent<P extends BaseTerminalProf
})
}
protected onFrontendReady (): void {
this.initializeSession()
super.onFrontendReady()
}
/**
* Initialize Connectable Session.
* Set reconnectOffered to false