michael@0: /* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ michael@0: /* This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this file, michael@0: * You can obtain one at http://mozilla.org/MPL/2.0/. michael@0: * michael@0: * The origin of this IDL file is michael@0: * http://www.whatwg.org/specs/web-apps/current-work/#texttrackcue michael@0: */ michael@0: michael@0: enum AutoKeyword { "auto" }; michael@0: michael@0: enum AlignSetting { michael@0: "start", michael@0: "middle", michael@0: "end", michael@0: "left", michael@0: "right" michael@0: }; michael@0: michael@0: enum DirectionSetting { michael@0: "", michael@0: "rl", michael@0: "lr" michael@0: }; michael@0: michael@0: [Constructor(double startTime, double endTime, DOMString text), michael@0: Pref="media.webvtt.enabled"] michael@0: interface VTTCue : EventTarget { michael@0: readonly attribute TextTrack? track; michael@0: michael@0: attribute DOMString id; michael@0: attribute double startTime; michael@0: attribute double endTime; michael@0: attribute boolean pauseOnExit; michael@0: [Pref="media.webvtt.regions.enabled"] michael@0: attribute VTTRegion? region; michael@0: attribute DirectionSetting vertical; michael@0: attribute boolean snapToLines; michael@0: attribute (long or AutoKeyword) line; michael@0: [SetterThrows] michael@0: attribute AlignSetting lineAlign; michael@0: [SetterThrows] michael@0: attribute long position; michael@0: [SetterThrows] michael@0: attribute AlignSetting positionAlign; michael@0: [SetterThrows] michael@0: attribute long size; michael@0: attribute AlignSetting align; michael@0: attribute DOMString text; michael@0: DocumentFragment getCueAsHTML(); michael@0: michael@0: attribute EventHandler onenter; michael@0: michael@0: attribute EventHandler onexit; michael@0: }; michael@0: michael@0: // Mozilla extensions. michael@0: partial interface VTTCue { michael@0: [ChromeOnly] michael@0: attribute HTMLDivElement? displayState; michael@0: [ChromeOnly] michael@0: readonly attribute boolean hasBeenReset; michael@0: };