-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
electron: restore previous workspace #9995
Conversation
a4187b6
to
6f98d5c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can confirm that the issue exists on master
and is addressed by this change nicely.
I hereby confirm that |
One limitation with the approach is if the default window (no workspace) was the last opened window, then we will still attempt to re-open the last workspace. For comparison, vscode restores the default window successfully for such a case. |
Question: This would be the first non-maintenance commit to |
@ccorn still confirming if the patch is proper, or if additional work is required to handle the other use-cases. As for creating a patch release, we generally do not do it for each non-maintenance commits to master but only if a major bug is resolved (we can think about if this warrants a patch release). Else, you can always use a |
In that case, opening the welcome page should clear |
Interesting. With this patch:
|
6f98d5c
to
c4fff9e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code LGTM.
Using this patch I am able to restore the last workspace as well as the case where the workspace is not set (the window re-opens without a workspace).
@ccorn can you also confirm that the behavior is fixed? |
The slightly odd behavior described above remains. |
I basically do a |
Update: A clean rebuild fixed it. I can confirm that Excellent issue handling! I cannot comment on the code, but I ran across a Linter warning for one of the affected files (Update: seems unrelated):
|
The commit fixes logic when determining whether to open a default window or existing workspace on electron startup. The update now correctly restores the workspace which would previously never restore properly. Signed-off-by: vince-fugnitto <[email protected]>
c4fff9e
to
5881a47
Compare
We'll release tomorrow, just need to give a heads up during the dev meeting as there's at least one other commit I'd like to include. |
The commit fixes logic when determining whether to open a default window or existing workspace on electron startup. The update now correctly restores the workspace which would previously never restore properly. Signed-off-by: vince-fugnitto <[email protected]>
The commit fixes logic when determining whether to open a default window or existing workspace on electron startup. The update now correctly restores the workspace which would previously never restore properly. Signed-off-by: vince-fugnitto <[email protected]>
The commit fixes logic when determining whether to open a default window or existing workspace on electron startup. The update now correctly restores the workspace which would previously never restore properly. Signed-off-by: vince-fugnitto <[email protected]>
What it does
Fixes: #9990.
Fixes: #9997.
Closes: #9993
The commit fixes logic when determining whether to open a default window or existing workspace on electron startup. The update now correctly restores the workspace which would previously never restore properly. As a consequence, the fix also resolves the window-state not being properly restored.
How to test
Workspace Restoration:
example-electron
application, and select a workspace folder.new window
- a new window should open with no workspace present.(cd examples/electron/ && yarn start ~/workspaces/theia)
) - the application should start and open with the specified workspace.Test Size + Position:
example-electron
applicationReview checklist
Reminder for reviewers
Signed-off-by: vince-fugnitto [email protected]