It's possible to capture most key events and prevent that the browser handles them without going into fullscreen mode. I had the same problem in my emulators with some function keys (for instance F1 would always open the help in Chrome).
This is done by returning "true" from the emscripten key callback functions (I think it doesn't work for things like Ctrl-L though). On Friday, 1 February 2019 16:39:51 UTC+1, Nolan Darilek wrote: > > On one hand, going full-screen blocks use of the escape key. On the other, > *not* going full-screen would seem to block the use of far more keys--tab, > ctrl-l, etc. Am I mistaken about that? > > > Is there a way to have the best of both worlds? Take up as much of the > screen as possible, permit using most/all keys, but give the user an escape > hatch back to the browser? Full-screen and the Escape key seem like the > best option for this, but I haven't experimented extensively. > > On 1/31/19 3:46 PM, Gabriel CV wrote: > > Yes, all those "pointer-locking / fullscreen / popups" issues and behavior > differences between browsers are a pain to handle properly. > > I guess you are right on the Fullscreen issue, resizing the canvas to 100% > is probably a more accurate solution. > > Nice work on your emulators btw > -- > You received this message because you are subscribed to the Google Groups > "emscripten-discuss" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected] <javascript:>. > For more options, visit https://groups.google.com/d/optout. > > -- You received this message because you are subscribed to the Google Groups "emscripten-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
