Document Additions Reference
| Inherits from | Node |
| Companion guide | |
| Availability | Available in Safari 3.0 and later. Available in iOS 1.0 and later. |
Overview
These additions to the Document class are used to create touch event objects on iOS and control full-screen mode on the desktop.
Properties
onwebkitfullscreenchange
An event listener that is called when entering or exiting full-screen mode.
attribute EventListener onwebkitfullscreenchange
Availability
- Available in Safari 5.1 and later.
webkitCurrentFullScreenElement
The element that is fullscreen.
readonly attribute Element webkitCurrentFullScreenElement
Availability
- Available in Safari 5.1 and later.
webkitFullScreenKeyboardInputAllowed
A Boolean that indicates whether keyboard input is allowed in fullscreen mode.
readonly attribute boolean webkitFullScreenKeyboardInputAllowed
Discussion
true if keyboard input is allowed; otherwise, false.
Availability
- Available in Safari 5.1 and later.
webkitIsFullScreen
A Boolean that indicates whether the document is in full-screen mode.
readonly attribute boolean webkitIsFullScreen
Discussion
true if the document is in full-screen mode; otherwise, false.
Availability
- Available in Safari 5.1 and later.
Methods
createTouch
Creates a new Touch object.
Parameters
- view
The view (DOM window) in which the event occurred.
- target
The target of this gesture.
- identifier
The unique identifier for this touch object.
- pageX
The x-coordinate of the touch’s location, in page coordinates.
- pageY
The y-coordinate of the touch’s location, in page coordinates.
- screenX
The x-coordinate of the event’s location, in screen coordinates.
- screenY
The y-coordinate of the event’s location, in screen coordinates.
Availability
- Available in iOS 2.0 and later.
createTouchList
Creates a new TouchList object.
Parameters
- firstTouch, …
The touch object.
Discussion
This method accepts a varying number of Touch parameters.
Availability
- Available in iOS 2.0 and later.
webkitCancelFullScreen
Cancels full-screen mode.
Availability
- Available in Safari 5.1 and later.
© 2012 Apple Inc. All Rights Reserved. (Last updated: 2012-02-21)