Changes

Jump to: navigation, search

Gecko:FullScreenAPI

1,340 bytes added, 00:16, 23 August 2011
capture webkit's additional pseudo-classes and discussion on mailing list, group features by document, element, CSS; add headings
Each document has an optional "current full-screen element".
=== Document additions ===
==== cancelFullScreen method ====
New method of Document:
The current full-screen element for the document is cleared.
==== fullScreen attribute ====
New DOM attribute of Document:
 
* readonly attribute boolean fullScreen
 
Returns true while the document is in the full-screen state.
 
==== fullScreenKeyboardInputAllowed attribute ====
New DOM attribute of Document:
 
* readonly attribute boolean fullScreenKeyboardInputAllowed
 
Returns true while the window's toplevel browsing context is full-screen and not in a "keys disabled" state.
 
=== Element additions ===
New methods of Element:
==== requestFullScreenWithKeys method ====
* void requestFullScreenWithKeys()
Typically the user agent would react by transitioning the Document to the full-screen state, or by presenting asynchronous confirmation UI and transitioning to the full-screen state if/when the user responds affirmatively. However, the user agent is not required to do anything at all in response to requestFullScreen. The user agent's behavior is allowed to vary depending on whether requestFullScreen is called during a user event (e.g. a mouse click handler).
==== requestFullScreen method ====
* void requestFullScreen()
As requestFullScreenWithKeys, but hints to the UA that while in full-screen state, the toplevel browsing context for this Document should have keys disabled. While keys are disabled, there may be a reduced risk of spoofing attacks inducing the user to input inappropriate data, and the UA may choose to relax restrictions on entering full-screen state with keys disabled.
==== fullscreenchange event ====New DOM attribute of Documentevents:
* readonly attribute boolean fullScreenfullscreenchange
Returns true while When a Document enters or leaves the document full-screen state, the user agent must queue a task to dispatch this event. When the event is in dispatched, if the document's current full-screen stateelement is an element in the document, then the event target is that element, otherwise the event target is the document. The event bubbles and is not cancellable.
* readonly ==== onfullscreenchange attribute boolean fullScreenKeyboardInputAllowed==== Returns true while the windowThe 'onfullscreenchange's toplevel browsing context event handling attribute is full-screen and not in a "keys disabled" statesupported on HTML elements.
==== iframe allowfullscreen attribute ====
New content attribute of the <iframe> element:
This is a boolean attribute. When this attribute is not set, UAs must ignore full-screen requests in the iframe or its descendant frames.
New events: * fullscreenchange=== CSS additions === When a Document enters or leaves the ==== full-screen state, the user agent must queue a task to dispatch this event. When the event is dispatched, if the document's current fullpseudo-screen element is an element in the document, then the event target is that element, otherwise the event target is the document. The event bubbles and is not cancellable. The 'onfullscreenchange' event handling attribute is supported on HTML elements.class ====New CSS psuedoclasspseudo-class:
* :full-screen
While a Document is in the full-screen state, and the document's current full-screen element is an element in the document, the 'full-screen' pseudoclass applies to that element. Also, an <iframe>, <object> or <embed> element whose child browsing context's Document is in the full-screen state has the 'full-screen' pseudoclass applied.
==== full-screen media query ====
New CSS media query selector:
While a Document is in the full-screen state, the full-screen media type is active for the document.
==== UA stylesheet rules ====
Suggested UA stylesheet rules:
Note that it is possible for a document to position content over an element with the :full-screen pseudo-class, for example if the :full-screen element is in a container with z-index not 'auto'.
 
==== Webkit additions ====
New CSS pseudo-classes:
* :full-screen-document - While a Document is in the fullscreen state, the 'full-screen-document' pseudo-class applies to the root element of that Document.
** note: webkit has implemented previous name for this :full-screen-doc
* :full-screen-root-with-target - While a Document is in the fullscreen state and the document's current fullscreen element is an element in the document, the 'full-screen-root-with-target' pseudoclass applies to the root element of that Document.
 
We should consider incorporating these into the spec.
 
See [http://lists.whatwg.org/pipermail/whatwg-whatwg.org/2010-August/027670.html feedback on new pseudo-classes] and [http://lists.whatwg.org/pipermail/whatwg-whatwg.org/2010-August/027672.html follow-up from RoC] (and subsequent thread)
== Suggested UA Policy ==
Canmove, confirm
2,672
edits

Navigation menu