mirror of
https://github.com/Microsoft/vscode
synced 2024-10-06 11:26:07 +00:00
proper fix for #68597
This commit is contained in:
parent
172a2df376
commit
c0de575949
|
@ -64,6 +64,7 @@ export class ExplorerView extends ViewletPanel {
|
|||
private dragHandler: DelayedDragHandler;
|
||||
private decorationProvider: ExplorerDecorationsProvider;
|
||||
private autoReveal = false;
|
||||
private ignoreActiveEditorChange = false;
|
||||
|
||||
constructor(
|
||||
options: IViewletPanelOptions,
|
||||
|
@ -194,7 +195,10 @@ export class ExplorerView extends ViewletPanel {
|
|||
|
||||
// When the explorer viewer is loaded, listen to changes to the editor input
|
||||
this.disposables.push(this.editorService.onDidActiveEditorChange(() => {
|
||||
this.selectActiveFile();
|
||||
if (!this.ignoreActiveEditorChange) {
|
||||
this.selectActiveFile();
|
||||
}
|
||||
this.ignoreActiveEditorChange = false;
|
||||
}));
|
||||
|
||||
// Also handle configuration updates
|
||||
|
@ -336,6 +340,7 @@ export class ExplorerView extends ViewletPanel {
|
|||
"from": { "classification": "SystemMetaData", "purpose": "FeatureInsight" }
|
||||
}*/
|
||||
this.telemetryService.publicLog('workbenchActionExecuted', { id: 'workbench.files.openFile', from: 'explorer' });
|
||||
this.ignoreActiveEditorChange = true;
|
||||
this.editorService.openEditor({ resource: selection[0].resource, options: { preserveFocus: e.editorOptions.preserveFocus, pinned: e.editorOptions.pinned } }, e.sideBySide ? SIDE_GROUP : ACTIVE_GROUP)
|
||||
.then(undefined, onUnexpectedError);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue