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
fix: esc not working on Windows during fullscreen #34317
Conversation
WOA failure is unrelated |
Release Notes Persisted
|
I was unable to backport this PR to "18-x-y" cleanly; |
I was unable to backport this PR to "19-x-y" cleanly; |
@codebytere has manually backported this PR to "19-x-y", please check out #34359 |
@codebytere has manually backported this PR to "18-x-y", please check out #34361 |
* fix: esc not working on Windows during fullscreen * chore: fix lint
Description of Change
Closes #34301.
Cleans up fullscreen control logic cross-platform.
fullscreen_controller()->EnterFullscreenModeForTab
inWebContents::EnterFullscreenModeForTab
, becuase there's a chance that the user will deny permission viasession.setPermissionRequestHandler
. Only call this inOnlyEnterFullscreenModeForTab
after the user has allowed fullscreening.NotifyExclusiveTabAccessLost
is called on all platforms inFullscreenController::ExitFullscreenModeInternal()
and not just macOS, since Electron's native window impls report state change fairly instantly as well, and so pressing escape won't work on Linux or Windows to un-fullscreen in some circumstances without this change.Checklist
npm test
passesRelease Notes
Notes: Fixed an issue where pressing escape would not un-fullscreen on Windows or Linux in some circumstances.