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

Handle leaving fullscreen with Escape and toggling with F11 #4

Open
ZimbiX opened this issue Mar 18, 2021 · 2 comments
Open

Handle leaving fullscreen with Escape and toggling with F11 #4

ZimbiX opened this issue Mar 18, 2021 · 2 comments
Labels
enhancement New feature or request

Comments

@ZimbiX
Copy link
Owner

ZimbiX commented Mar 18, 2021

Similar to #3, I realised that pressing Escape to leave fullscreen is still slow. I'd forgotten to handle that.

I had a bit of a go, and it seems like neither detecting Escape keydown nor the fullscreenchange event happen soon enough (or at all?). If this is even possible to fix, it's going to be difficult. I'd rather not dive deep into how YouTube's fullscreen toggling works to delay the actual transition.

Handling F11 is related. I haven't tried to do that yet, but I suspect it'll require the same mechanism.

@ZimbiX ZimbiX added the enhancement New feature or request label Mar 18, 2021
@ZimbiX
Copy link
Owner Author

ZimbiX commented Mar 18, 2021

Until this is resolved, I should update the readme to note that only the F key and fullscreen button are currently supported.

Edit: Done

@Metal-spoon
Copy link

Metal-spoon commented Apr 25, 2021

Escape and f11 are probably never going to be able to be used for this.
You can't override them because they are the panic buttons of fullscreen so to speak.
Only way to do this is to prevent the input and let it press f instead, this can't be done in javascript, one has to use something like AHK to achieve that functionality. Something that runs outside the browser and can capture inputs.
Or modify the code of the browser itself but that is also a stretch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants