diff --git a/fullscreen.bs b/fullscreen.bs index bd54a2c..6130a65 100644 --- a/fullscreen.bs +++ b/fullscreen.bs @@ -85,18 +85,6 @@ its node document's top layer.
-

To fully exit fullscreen a document document, run these steps: - -

    -
  1. If document's fullscreen element is null, terminate these steps. - -

  2. Unfullscreen elements whose fullscreen flag is - set, within document's top layer, except for document's - fullscreen element. - -

  3. Exit fullscreen document. -

-

Whenever the removing steps run with a removedNode, run these steps:

    @@ -109,7 +97,7 @@ its node document's top layer.
    1. If node is its node document's fullscreen element, - exit fullscreen that document. + exit fullscreen that document with fullyFlag unset.

    2. Otherwise, unfullscreen node within its node document. @@ -117,7 +105,7 @@ its node document's top layer.

    Whenever the unloading document cleanup steps run with a document, -fully exit fullscreen document. +exit fullscreen document with fullyFlag set.


    @@ -351,7 +339,8 @@ could be an open <{dialog}> element. in which case that document will still remain in fullscreen.
-

To exit fullscreen a document doc, run these steps: +

To exit fullscreen a document doc with +fullyFlag, run these steps:

  1. Let promise be a new promise. @@ -393,8 +382,8 @@ could be an open <{dialog}> element.

  2. If resize is true and topLevelDoc is either not in exitDocs, or not a simple fullscreen document, - fully exit fullscreen topLevelDoc, reject promise with a - TypeError exception, and terminate these steps. + exit fullscreen topLevelDoc with fullyFlag set, reject + promise with a TypeError exception, and terminate these steps.

  3. Let descendantDocs be an ordered set consisting of doc's @@ -406,8 +395,16 @@ could be an open <{dialog}> element. unfullscreen descendantDoc. -

  4. For each exitDoc in exitDocs, - unfullscreen exitDoc's fullscreen element. +

  5. +

    For each exitDoc in exitDocs: + +

      +
    1. If exitDoc is doc and fullyFlag is set, then + unfullscreen doc. + +

    2. Otherwise, unfullscreen exitDoc's + fullscreen element. +

  6. For each descendantDoc in descendantDocs, fire an event named fullscreenchange on descendantDoc. @@ -424,7 +421,8 @@ could be an open <{dialog}> element.

The exitFullscreen() method, when invoked, must -return the result of running exit fullscreen on the context object. +return the result of running exit fullscreen on the context object with +fullyFlag unset.


@@ -453,8 +451,8 @@ return the result of running exit fullscreen on the context object {{Element/requestFullscreen()}} and {{Document/exitFullscreen()}}.

If the end user instructs the user agent to end a fullscreen session initiated via -{{Element/requestFullscreen()}}, fully exit fullscreen the -top-level browsing context's active document. +{{Element/requestFullscreen()}}, exit fullscreen the +top-level browsing context's active document with fullyFlag set.