Revert "resolves Eugeny/tabby#7751, Eugeny/tabby#8062, Eugeny/tabby#6617 add configurable behavior when session ends"

This reverts commit 268af8806c.
This commit is contained in:
Clem
2023-04-22 14:36:43 +02:00
parent 8cb75e14a2
commit f423be1510
7 changed files with 32 additions and 79 deletions

View File

@@ -28,6 +28,7 @@ export class TerminalTabComponent extends BaseTerminalTabComponent<LocalProfile>
this.sessionOptions = this.profile.options
this.logger = this.log.create('terminalTab')
this.session = new Session(this.injector)
const isConPTY = isWindowsBuild(WIN_BUILD_CONPTY_SUPPORTED) && this.config.store.terminal.useConPTY
@@ -55,9 +56,6 @@ export class TerminalTabComponent extends BaseTerminalTabComponent<LocalProfile>
}
initializeSession (columns: number, rows: number): void {
const session = new Session(this.injector)
if (this.profile.options.runAsAdministrator && this.uac?.isAvailable) {
this.profile = {
...this.profile,
@@ -65,13 +63,13 @@ export class TerminalTabComponent extends BaseTerminalTabComponent<LocalProfile>
}
}
session.start({
this.session!.start({
...this.profile.options,
width: columns,
height: rows,
})
this.setSession(session, this.config.store.terminal.behaviorOnSessionEnds.endsWith('close'))
this.attachSessionHandlers(true)
this.recoveryStateChangedHint.next()
}