Repository navigation
fix: add support for --ozone-platform-hint flag on Linux - #34937
Conversation
a0e92ce to
ab3cc3a
Compare
deepak1556
left a comment
There was a problem hiding this comment.
Can you copy the logic to support this flag into ElectronBrowserMainParts
Electron has its own shutdown logic and bringing in ChromeBrowserMainExtraParts overrides this, also it is not necessary to support this flag.
ab3cc3a to
7807684
Compare
|
@deepak1556 I've copied the logic from However, it is a bit verbose so it may be worth moving it someplace else in order to keep |
7807684 to
1a16523
Compare
|
Release Notes Persisted
|
|
I have automatically backported this PR to "18-x-y", please check out #35013 |
|
I have automatically backported this PR to "20-x-y", please check out #35014 |
|
I have automatically backported this PR to "19-x-y", please check out #35015 |
Description of Change
Add support for the
--ozone-platform-hintflag in order to make it easier for users to switch between the X11 and Wayland platforms (e.g.: by using--ozone-platform-hint=auto).Implementation details
This was implemented by reusing the same logic from upstream, but it required implementingchrome::SessionEnding()which is a bit hacky. This was necessary due to this call fromChromeBrowserMainExtraPartsOzone::PostCreateMainMessageLoop().Another option would have been to either patch that method or copy the logic fromChromeBrowserMainExtraPartsOzoneandChromeBrowserMainExtraPartsLinuxinside Electron. If Electron maintainers think that's a more reasonable approach I'll update this pull-request accordingly.EDIT: This description is no longer relevant because the implementation has been reworked with feedback from Electron maintainers.
Fixes #33810
Checklist
npm testpassesRelease Notes
Notes: Added support for
--ozone-platform-hintflag on Linux