diff options
Diffstat (limited to 'Source/WebCore/html/track/TextTrack.idl')
-rw-r--r-- | Source/WebCore/html/track/TextTrack.idl | 42 |
1 files changed, 18 insertions, 24 deletions
diff --git a/Source/WebCore/html/track/TextTrack.idl b/Source/WebCore/html/track/TextTrack.idl index 90f6d1b93..c09f0d105 100644 --- a/Source/WebCore/html/track/TextTrack.idl +++ b/Source/WebCore/html/track/TextTrack.idl @@ -10,10 +10,10 @@ * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * - * THIS SOFTWARE IS PROVIDED BY APPLE COMPUTER, INC. ``AS IS'' AND ANY + * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR - * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE COMPUTER, INC. OR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR @@ -23,39 +23,33 @@ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +enum TextTrackMode { "disabled", "hidden", "showing" }; +enum TextTrackKind { "subtitles", "captions", "descriptions", "chapters", "metadata", "forced" }; + [ Conditional=VIDEO_TRACK, - EventTarget, GenerateIsReachable=ImplElementRoot, JSCustomMarkFunction, SkipVTableValidation, -] interface TextTrack { +] interface TextTrack : EventTarget { readonly attribute DOMString id; - [CustomSetter] attribute DOMString kind; + [ImplementedAs=kindForBindings] attribute TextTrackKind kind; readonly attribute DOMString label; [CustomSetter] attribute DOMString language; + readonly attribute DOMString inBandMetadataTrackDispatchType; - attribute DOMString mode; + attribute TextTrackMode mode; - readonly attribute TextTrackCueList cues; - readonly attribute TextTrackCueList activeCues; - attribute EventListener oncuechange; + readonly attribute TextTrackCueList? cues; + readonly attribute TextTrackCueList? activeCues; - void addCue(TextTrackCue cue); - [RaisesException] void removeCue(TextTrackCue cue); + [MayThrowException] void addCue(TextTrackCue cue); + [MayThrowException] void removeCue(TextTrackCue cue); -#if defined(ENABLE_WEBVTT_REGIONS) && ENABLE_WEBVTT_REGIONS - readonly attribute TextTrackRegionList regions; - void addRegion(TextTrackRegion region); - [RaisesException] void removeRegion(TextTrackRegion region); -#endif + attribute EventHandler oncuechange; - // EventTarget interface - void addEventListener(DOMString type, - EventListener listener, - optional boolean useCapture); - void removeEventListener(DOMString type, - EventListener listener, - optional boolean useCapture); - [RaisesException] boolean dispatchEvent(Event evt); + readonly attribute VTTRegionList regions; + // FIXME: region parameter should not be nullable in addRegion and removeRegion. + void addRegion(VTTRegion? region); + [MayThrowException] void removeRegion(VTTRegion? region); }; |