mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-21 09:35:38 -05:00
Fix Agent tabs not switching (#6271)
This commit is contained in:
@@ -50,7 +50,7 @@ interface IInternalPanelTab {
|
||||
disposables: IDisposable[];
|
||||
label: HTMLElement;
|
||||
body?: HTMLElement;
|
||||
destoryTabBody?: boolean;
|
||||
destroyTabBody?: boolean;
|
||||
}
|
||||
|
||||
const defaultOptions: IPanelOptions = {
|
||||
@@ -115,10 +115,10 @@ export class TabbedPanel extends Disposable {
|
||||
return this._tabMap.has(tab.identifier);
|
||||
}
|
||||
|
||||
public pushTab(tab: IPanelTab, index?: number, destoryTabBody?: boolean): PanelTabIdentifier {
|
||||
public pushTab(tab: IPanelTab, index?: number, destroyTabBody?: boolean): PanelTabIdentifier {
|
||||
let internalTab = { tab } as IInternalPanelTab;
|
||||
internalTab.disposables = [];
|
||||
internalTab.destoryTabBody = destoryTabBody;
|
||||
internalTab.destroyTabBody = destroyTabBody;
|
||||
this._tabMap.set(tab.identifier, internalTab);
|
||||
this._createTab(internalTab, index);
|
||||
if (!this._shownTabId) {
|
||||
@@ -203,7 +203,7 @@ export class TabbedPanel extends Disposable {
|
||||
this.tabHistory.push(id);
|
||||
const tab = this._tabMap.get(this._shownTabId)!; // @anthonydresser we know this can't be undefined since we check further up if the map contains the id
|
||||
|
||||
if (tab.destoryTabBody && tab.body) {
|
||||
if (tab.destroyTabBody && tab.body) {
|
||||
tab.body.remove();
|
||||
tab.body = undefined;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user