2013-05-21 16:14:00 +00:00
|
|
|
/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
|
|
|
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
|
|
*
|
|
|
|
* The origin of this IDL file is
|
|
|
|
* http://www.whatwg.org/specs/web-apps/current-work/#texttrack
|
|
|
|
*/
|
|
|
|
|
|
|
|
enum TextTrackKind {
|
|
|
|
"subtitles",
|
|
|
|
"captions",
|
|
|
|
"descriptions",
|
|
|
|
"chapters",
|
|
|
|
"metadata"
|
|
|
|
};
|
|
|
|
|
|
|
|
enum TextTrackMode {
|
|
|
|
"disabled",
|
|
|
|
"hidden",
|
|
|
|
"showing"
|
|
|
|
};
|
|
|
|
|
|
|
|
[Pref="media.webvtt.enabled"]
|
|
|
|
interface TextTrack : EventTarget {
|
|
|
|
readonly attribute TextTrackKind kind;
|
|
|
|
readonly attribute DOMString label;
|
|
|
|
readonly attribute DOMString language;
|
2013-07-09 15:44:35 +00:00
|
|
|
|
|
|
|
readonly attribute DOMString id;
|
2013-05-21 16:14:00 +00:00
|
|
|
readonly attribute DOMString inBandMetadataTrackDispatchType;
|
|
|
|
|
|
|
|
attribute TextTrackMode mode;
|
|
|
|
|
|
|
|
readonly attribute TextTrackCueList? cues;
|
|
|
|
readonly attribute TextTrackCueList? activeCues;
|
|
|
|
|
2013-08-27 20:07:00 +00:00
|
|
|
void addCue(VTTCue cue);
|
2013-06-28 17:31:43 +00:00
|
|
|
[Throws]
|
2013-08-27 20:07:00 +00:00
|
|
|
void removeCue(VTTCue cue);
|
2013-05-21 16:14:00 +00:00
|
|
|
|
2014-06-30 23:12:11 +00:00
|
|
|
//(Not implemented)attribute EventHandler oncuechange;
|
2013-05-21 16:14:00 +00:00
|
|
|
};
|
2014-01-27 18:10:06 +00:00
|
|
|
|
|
|
|
// Mozilla Extensions
|
|
|
|
partial interface TextTrack {
|
|
|
|
[ChromeOnly]
|
|
|
|
readonly attribute TextTrackList? textTrackList;
|
|
|
|
};
|