Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Martin Thomson <mt@lowentropy.net>
  • Loading branch information
marcoscaceres and martinthomson authored Dec 8, 2023
1 parent 0087119 commit f670402
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions fullscreen.bs
Original file line number Diff line number Diff line change
Expand Up @@ -688,9 +688,9 @@ iframe:fullscreen {



<h2 id="keyboard-locking">keyboard locking</h2>
<h2 id="keyboard-locking">Keyboard Locking</h2>

<p>keyboard Locking enhances the functionality of web applications running in fullscreen by allowing
<p>Keyboard locking enhances the functionality of web applications running in fullscreen by allowing
them to intercept certain key inputs that would typically be handled by either the system or the
user agent. This is useful in scenarios such as gaming or remote desktop applications, where keys
like ESC or function keys are integral to the application's functionality.
Expand All @@ -704,20 +704,26 @@ web application in fullscreen.

<dl>
<dt><dfn>Application-level keyboard lock</dfn></dt>
<dd><p>Captures all keys that the user agent would ordinarily receive, except those reserved for
critical system functions or security shortcuts (e.g., Ctrl+Alt+Del).
<dd><p>Captures all keys that the user agent would ordinarily receive, such as those that open or
close windows. This excludes those reserved for system-level interactions, such
as key presses that open system menus or switch applications.
<dt><dfn>System-level keyboard lock</dfn></dt>
<dd><p>Capture a wider range of keys, including those used for system-level navigation and
shortcuts (e.g., Alt+Tab), subject to user consent and user agent implementation.
</dl>

<p>User agents should reserve an additional input for the purposes of exiting fullscreen.
There are also some system-level key sequences or combinations that cannot be
intercepted for security reasons, such as Ctrl+Alt+Del on Windows.

<div algorithm>
<p>To <dfn>run the release the keyboard lock steps</dfn> for a <a>document</a>
<var>document</var>, run these steps:
<ol>
<li><p>If the [=keyboard lock flag=] for the <var>document</var> is not set, abort these steps.
<li><p>Deactivate the keyboard lock and restore the handling of keyboard inputs to the default
behavior of the user agent and the operating system. <li><p>Set the [=keyboard lock flag=] for
behavior of the user agent and the operating system.
<li><p>Set the [=keyboard lock flag=] for
the <var>document</var> to <code>false</code>.
</ol>
</div>
Expand Down

0 comments on commit f670402

Please sign in to comment.