chore: remove stale TODOs about lifecycle hack

This commit is contained in:
Murat Aslan
2026-01-02 17:42:15 +03:00
parent dcd097ce90
commit e120edc2f7
@@ -592,10 +592,8 @@ export class TerminalTabbedView extends Disposable {
// be focused. So wait for connection to finish, then focus.
const previousActiveElement = this._tabListElement.ownerDocument.activeElement;
if (previousActiveElement) {
// TODO: Improve lifecycle management this event should be disposed after first fire
const listener = this._register(Event.once(this._terminalService.onDidChangeConnectionState)(() => {
// Only focus the terminal if the activeElement has not changed since focus() was called
// TODO: Hack
if (dom.isActiveElement(previousActiveElement)) {
this._focus();
}