Skip to content

Conversation

@sbatten
Copy link
Member

@sbatten sbatten commented Dec 21, 2018

fixes #54349

@bpasero
Copy link
Member

bpasero commented Dec 21, 2018

@sbatten I do not understand why this code has to live in electron-main, you can use winreg also from the renderer directly, no? As such I think that is not an argument for having the menu bar service created if the custom menu is enabled.

Besides, if you are using a dependency to NPM, make sure to not require it via imports on top of the file, but rather to a dynamic import when you need it to delay loading of modules to the latest point possible. E.g. await import('winreg').then(...)

@sbatten
Copy link
Member Author

sbatten commented Dec 21, 2018

@bpasero thanks for the advice. I also had trouble finding a place for this code to avoid layer breakage. Right now it is in the menubar service just for association reasons. Any recommendations are welcome. @Tyriar threw out having a registry service

@bpasero
Copy link
Member

bpasero commented Dec 28, 2018

@sbatten I see the issue with the layer, so then I guess we need another IMenuService in workbench that lives in node or electron-browser to implement this. Or even more general, a service to access windows registry keys.

@sbatten sbatten closed this Feb 19, 2019
@github-actions github-actions bot locked and limited conversation to collaborators Mar 30, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Access keys not working as expected with custom titleBarStyle

2 participants