mirror of
https://github.com/Eugeny/tabby.git
synced 2025-06-08 13:30:02 +00:00
Merge pull request #8918 from Clem-Fern/fix#8912
This commit is contained in:
commit
adeb6031dd
@ -46,7 +46,9 @@ export abstract class ConnectableTerminalTabComponent<P extends ConnectableTermi
|
|||||||
}
|
}
|
||||||
|
|
||||||
protected onFrontendReady (): void {
|
protected onFrontendReady (): void {
|
||||||
this.initializeSession()
|
this.initializeSession().then(() => {
|
||||||
|
this.clearServiceMessagesOnConnect()
|
||||||
|
})
|
||||||
super.onFrontendReady()
|
super.onFrontendReady()
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -57,9 +59,6 @@ export abstract class ConnectableTerminalTabComponent<P extends ConnectableTermi
|
|||||||
async initializeSession (): Promise<void> {
|
async initializeSession (): Promise<void> {
|
||||||
this.reconnectOffered = false
|
this.reconnectOffered = false
|
||||||
this.isDisconnectedByHand = false
|
this.isDisconnectedByHand = false
|
||||||
if (this.profile.clearServiceMessagesOnConnect) {
|
|
||||||
this.frontend?.clear()
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -119,7 +118,14 @@ export abstract class ConnectableTerminalTabComponent<P extends ConnectableTermi
|
|||||||
async reconnect (): Promise<void> {
|
async reconnect (): Promise<void> {
|
||||||
this.session?.destroy()
|
this.session?.destroy()
|
||||||
await this.initializeSession()
|
await this.initializeSession()
|
||||||
|
this.clearServiceMessagesOnConnect()
|
||||||
this.session?.releaseInitialDataBuffer()
|
this.session?.releaseInitialDataBuffer()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private clearServiceMessagesOnConnect (): void {
|
||||||
|
if (this.profile.clearServiceMessagesOnConnect && this.session?.open) {
|
||||||
|
this.frontend?.clear()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user