Skip to content
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

GH-5100: Update the menu if the frontend is ready. #5140

Merged
merged 1 commit into from
Sep 25, 2019
Merged

Conversation

kittaakos
Copy link
Contributor

@kittaakos kittaakos commented May 14, 2019

Closes #5100.

Signed-off-by: Akos Kitta [email protected]

What it does

  • Forcefully sets the application menu once the frontend application is ready.

How to test

  • See details and corresponding screencast here.

Review checklist

Reminder for reviewers

🌞

@kittaakos kittaakos changed the title Gh 5100 GH-5100, GH-446: Various menu related fixes for electron May 14, 2019
@kittaakos kittaakos marked this pull request as ready for review May 14, 2019 11:04
@thegecko
Copy link
Member

The code looks good to me, which desktop platforms does it need testing on?

@kittaakos
Copy link
Contributor Author

which desktop platforms does it need testing on?

I experienced #5100 on macOS only, I do not know if it is an issue on Windows/Linux or not. The dynamic menu item related change (#446) should affect all supported platforms.

@thegecko
Copy link
Member

I see no issue on MacOS

Copy link
Member

@paul-marechal paul-marechal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also it flickers when I click in the editor on Ubuntu 16.04, doesn't do it on master :/

theia-flickering-menu

(can't see it really well on the gif, but still a bit)

Copy link
Member

@akosyakov akosyakov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems to be a good approximation, won't work though if commands should be enabled/disabled based on internal widget state.

@kittaakos
Copy link
Contributor Author

won't work though if commands should be enabled/disabled based on internal widget state

This. I will investigate VS Code's solution a bit more thoroughly.

Also it flickers when I click in the editor on Ubuntu 16.04, doesn't do it on master :/

Thanks for the feedback. I will try how VS Code behaves on my Ubuntu image and will compare it with Theia. Perhaps, I have to add some debouncing logic.

@kittaakos
Copy link
Contributor Author

@akosyakov, I have dropped the dynamic electron menu part.
@marechal-p, could you please review the PR again. I have changed the window argument to electronWindow based on your feedback. Thank you!

@kittaakos kittaakos changed the title GH-5100, GH-446: Various menu related fixes for electron GH-5100: Update the menu if the frontend is ready. Sep 24, 2019
Copy link
Member

@paul-marechal paul-marechal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM no more flickering on my side.

@akosyakov akosyakov added the electron issues related to the electron target label Sep 25, 2019
@kittaakos kittaakos merged commit cc50d40 into master Sep 25, 2019
@kittaakos kittaakos deleted the GH-5100 branch September 25, 2019 06:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
electron issues related to the electron target
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[electron][menu][osx] The application menu is incomplete on app start up
4 participants