35

In VSCode, if I have an editor window tab open and I click anywhere in that editor window, the selected file in the File Explorer changes to the file being edited. I would like to prevent that behavior. This is possible in Visual Studio, but I can't seem to find a similar setting in the preferences file of VSCode.

Can anyone provide some suggestions?

silverfox1948
  • 857
  • 10
  • 15

2 Answers2

64

This has been added, see https://github.com/Microsoft/vscode/issues/14745.

Configuration is "explorer.autoReveal": false

alalonde
  • 1,823
  • 1
  • 16
  • 27
3

You can't, at least not today. The only thing you can do, is keeping the scroll position when switching tabs. See this answer for the setting: VSCode prevent file Explorer from jumping

And here is the feature request on Github: https://github.com/Microsoft/vscode/issues/14745

(Feel free to add a "Thumbs Up" via Github Reaction at the top so the request gets more attention in the future, this increases the chances that it gets implemented sooner)

Community
  • 1
  • 1
kwood
  • 9,854
  • 2
  • 28
  • 32