-
Notifications
You must be signed in to change notification settings - Fork 28.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
With window.restoreWindows=preserve
files do not pick a good window to open
#111605
Comments
window.restoreWindows=preserve
window.restoreWindows=preserve
files do not pick a good window to open
Collection of Issues When you pass a When instructing VSCode to open files (e.g. from command line), and it is not running, we simply have no logic that ensures the files open in the "right" windows (e.g. those that have the parent folders opened). We do this only when VSCode is already running and you pass files in (via When none of the windows would match, we still simply open the files in the first window, where we should probably pick the window that was last active (#111620). Conclusion The best way forward is probably to rewrite the code that opens or restores windows on startup with these goals in mind. The fact that the order of windows to open is totally mixed up when we actually open windows does not help. |
I doubt you'll get this specific issue out in the wild. So let's just close it silently. 🤫 |
Oh I actually think I would like to fix this and I do think it is quite annoying, especially for users that have asked for the feature to restore windows, so I will see what I can do. |
Ah, the "I am too afraid to change the existing code. " was misleading, I just didn't want to push a fix now in endgame week. Needs some good testing in insiders. |
i have actually never gotten an issue for this, so I will close it. not so straight forward as I had hoped... |
Testing #111420
This didn't work for me.
On Windows, with WSL. I had two windows open:
vscode (WSL)
andfakeproject
(not WSL). Without Code running, I invokedcode-insiders C:\Users\joao\Desktop
. Now I have three windows:vscode (WSL)
,fakeproject
andDesktop
. I exit Code. I then invokedcode-insiders C:\Users\joao\Desktop\file.txt
. The same three windows come up butfile.txt
is open in thefakeproject
window instead of theDesktop
window. 🐛The text was updated successfully, but these errors were encountered: