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
Panel size is not remembered correctly when panel is moved to the right #85451
Comments
(Experimental duplicate detection) |
|
Ignore my previous statement, the correct root cause is that when a new empty window is created on macOS and VS Code is already running(even without a window), the new window is always a new workspace id. However, from a cold start (VS Code is not running), the new empty window uses the same workspace id as before. Panel position and visibility are stored in workspace storage and therefore in the repro case, do not exist. The size is written to global storage so it is restored. @bpasero Does this workspace id generation sound correct? It seems strange that a new window from cold and hot starts give differing results if no windows are open from the beginning. For the panel state, I could check if this is an empty workspace and just ignore workspace storage and revert to defaults. But, I want to check that this is how storage is expected to work. |
This is correct, macOS has the concept of running apps even without windows. If you then go and click the app, it will open a new empty window with new workspace id. Starting VSCode when it is not running will restore any previous workspaces, including empty ones. |
Still seems strange to treat clicking the app icon differently when no windows are open based on the app running in the background. But perhaps that's what Mac users expect |
@sbatten my understanding is that clicking on the app icon when no window is open acts like "New Window" and not "Restore Window from Previous Session". |
I've updated the restoration logic to ignore the global storage panel size when we aren't restoring positions but rather just using defaults. |
new fix is similar but will restore size if the position matches the last saved panel size |
@sbatten What's the expected behavior now? Following the original repro steps, I still see the panel being restored to the bottom instead of the right |
@RMacfarlane Following the original steps should show the panel at the bottom, but the size should be appropriate. |
Steps to Reproduce:
Video of the reproduction steps: https://streamable.com/fkcox.
Does this issue occur when all extensions are disabled?: Yes
The text was updated successfully, but these errors were encountered: