| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2008, 2009, 2010, 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2008, 2009, 2010, 2011 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2012 Google Inc. All rights reserved. | 3 * Copyright (C) 2012 Google Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 8 * | 8 * |
| 9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 22 matching lines...) Expand all Loading... |
| 33 #include "bindings/core/v8/ExceptionStatePlaceholder.h" | 33 #include "bindings/core/v8/ExceptionStatePlaceholder.h" |
| 34 #include "core/InputTypeNames.h" | 34 #include "core/InputTypeNames.h" |
| 35 #include "core/dom/DOMTokenList.h" | 35 #include "core/dom/DOMTokenList.h" |
| 36 #include "core/dom/shadow/ShadowRoot.h" | 36 #include "core/dom/shadow/ShadowRoot.h" |
| 37 #include "core/events/MouseEvent.h" | 37 #include "core/events/MouseEvent.h" |
| 38 #include "core/frame/LocalFrame.h" | 38 #include "core/frame/LocalFrame.h" |
| 39 #include "core/html/HTMLVideoElement.h" | 39 #include "core/html/HTMLVideoElement.h" |
| 40 #include "core/html/MediaController.h" | 40 #include "core/html/MediaController.h" |
| 41 #include "core/html/TimeRanges.h" | 41 #include "core/html/TimeRanges.h" |
| 42 #include "core/html/shadow/MediaControls.h" | 42 #include "core/html/shadow/MediaControls.h" |
| 43 #include "core/html/track/CueTimeline.h" |
| 43 #include "core/html/track/TextTrack.h" | 44 #include "core/html/track/TextTrack.h" |
| 45 #include "core/html/track/TextTrackCue.h" |
| 44 #include "core/html/track/vtt/VTTRegionList.h" | 46 #include "core/html/track/vtt/VTTRegionList.h" |
| 45 #include "core/layout/LayoutSlider.h" | 47 #include "core/layout/LayoutSlider.h" |
| 46 #include "core/layout/LayoutTheme.h" | 48 #include "core/layout/LayoutTheme.h" |
| 47 #include "core/page/EventHandler.h" | 49 #include "core/page/EventHandler.h" |
| 48 #include "core/rendering/RenderMediaControlElements.h" | 50 #include "core/rendering/RenderMediaControlElements.h" |
| 49 #include "core/rendering/RenderVideo.h" | 51 #include "core/rendering/RenderVideo.h" |
| 50 #include "platform/RuntimeEnabledFeatures.h" | 52 #include "platform/RuntimeEnabledFeatures.h" |
| 51 | 53 |
| 52 namespace blink { | 54 namespace blink { |
| 53 | 55 |
| (...skipping 598 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 652 // everything is handled through CSS. The caption box is on top of the | 654 // everything is handled through CSS. The caption box is on top of the |
| 653 // controls box, in a container set with the -webkit-box display property. | 655 // controls box, in a container set with the -webkit-box display property. |
| 654 | 656 |
| 655 // 6. Let tracks be the subset of video's list of text tracks that have as | 657 // 6. Let tracks be the subset of video's list of text tracks that have as |
| 656 // their rules for updating the text track rendering these rules for | 658 // their rules for updating the text track rendering these rules for |
| 657 // updating the display of WebVTT text tracks, and whose text track mode is | 659 // updating the display of WebVTT text tracks, and whose text track mode is |
| 658 // showing or showing by default. | 660 // showing or showing by default. |
| 659 // 7. Let cues be an empty list of text track cues. | 661 // 7. Let cues be an empty list of text track cues. |
| 660 // 8. For each track track in tracks, append to cues all the cues from | 662 // 8. For each track track in tracks, append to cues all the cues from |
| 661 // track's list of cues that have their text track cue active flag set. | 663 // track's list of cues that have their text track cue active flag set. |
| 662 CueList activeCues = video.currentlyActiveCues(); | 664 CueList activeCues = video.cueTimeline().currentlyActiveCues(); |
| 663 | 665 |
| 664 // 9. If reset is false, then, for each text track cue cue in cues: if cue's | 666 // 9. If reset is false, then, for each text track cue cue in cues: if cue's |
| 665 // text track cue display state has a set of CSS boxes, then add those boxes | 667 // text track cue display state has a set of CSS boxes, then add those boxes |
| 666 // to output, and remove cue from cues. | 668 // to output, and remove cue from cues. |
| 667 | 669 |
| 668 // There is nothing explicitly to be done here, as all the caching occurs | 670 // There is nothing explicitly to be done here, as all the caching occurs |
| 669 // within the TextTrackCue instance itself. If parameters of the cue change, | 671 // within the TextTrackCue instance itself. If parameters of the cue change, |
| 670 // the display tree is cleared. | 672 // the display tree is cleared. |
| 671 | 673 |
| 672 // 10. For each text track cue cue in cues that has not yet had | 674 // 10. For each text track cue cue in cues that has not yet had |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 709 float fontSize = smallestDimension * 0.05f; | 711 float fontSize = smallestDimension * 0.05f; |
| 710 if (fontSize != m_fontSize) { | 712 if (fontSize != m_fontSize) { |
| 711 m_fontSize = fontSize; | 713 m_fontSize = fontSize; |
| 712 setInlineStyleProperty(CSSPropertyFontSize, fontSize, CSSPrimitiveValue:
:CSS_PX); | 714 setInlineStyleProperty(CSSPropertyFontSize, fontSize, CSSPrimitiveValue:
:CSS_PX); |
| 713 } | 715 } |
| 714 } | 716 } |
| 715 | 717 |
| 716 // ---------------------------- | 718 // ---------------------------- |
| 717 | 719 |
| 718 } // namespace blink | 720 } // namespace blink |
| OLD | NEW |