File tree Expand file tree Collapse file tree
extensions/ql-vscode/src/data-extensions-editor Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -99,7 +99,8 @@ export class DataExtensionsEditorView extends AbstractWebview<
9999 panel . reveal ( undefined , true ) ;
100100
101101 panel . onDidChangeViewState ( async ( ) => {
102- if ( await this . isTheMostRecentlyActivePanel ( ) ) {
102+ if ( panel . active ) {
103+ await this . onPanelBecameActive ( ) ;
103104 await this . updateModelDetailsPanelState (
104105 this . externalApiUsages ,
105106 this . databaseItem ,
@@ -110,15 +111,14 @@ export class DataExtensionsEditorView extends AbstractWebview<
110111 await this . waitForPanelLoaded ( ) ;
111112 }
112113
113- private async isTheMostRecentlyActivePanel ( ) : Promise < boolean > {
114+ private async onPanelBecameActive ( ) : Promise < void > {
114115 const panel = await this . getPanel ( ) ;
116+ DataExtensionsEditorView . mostRecentlyActivePanel = panel ;
117+ }
115118
116- if ( panel . active ) {
117- DataExtensionsEditorView . mostRecentlyActivePanel = panel ;
118- return true ;
119- } else {
120- return panel === DataExtensionsEditorView . mostRecentlyActivePanel ;
121- }
119+ private async isTheMostRecentlyActivePanel ( ) : Promise < boolean > {
120+ const panel = await this . getPanel ( ) ;
121+ return panel === DataExtensionsEditorView . mostRecentlyActivePanel ;
122122 }
123123
124124 protected async getPanelConfig ( ) : Promise < WebviewPanelConfig > {
You can’t perform that action at this time.
0 commit comments