diff --git a/src/vs/workbench/browser/parts/views/treeView.ts b/src/vs/workbench/browser/parts/views/treeView.ts index 6bf667dda1074..6aaf7f3f198f2 100644 --- a/src/vs/workbench/browser/parts/views/treeView.ts +++ b/src/vs/workbench/browser/parts/views/treeView.ts @@ -346,6 +346,9 @@ abstract class AbstractTreeView extends Disposable implements ITreeView { set dataProvider(dataProvider: ITreeViewDataProvider | undefined) { if (dataProvider) { + if (this.visible) { + this.activate(); + } const self = this; this._dataProvider = new class implements ITreeViewDataProvider { private _isEmpty: boolean = true;