Index: Source/core/html/shadow/MediaControlElements.cpp |
diff --git a/Source/core/html/shadow/MediaControlElements.cpp b/Source/core/html/shadow/MediaControlElements.cpp |
index be6779c55324872696413abccf8029f093a151b9..28169b82b1ea2d9e4f614c4f3019e0f0e7c2cc90 100644 |
--- a/Source/core/html/shadow/MediaControlElements.cpp |
+++ b/Source/core/html/shadow/MediaControlElements.cpp |
@@ -735,29 +735,7 @@ void MediaControlTextTrackContainerElement::updateDisplay() |
if (!cue->track() || !cue->track()->isRendered() || !cue->isActive()) |
continue; |
- RefPtr<TextTrackCueBox> displayBox = cue->getDisplayTree(m_videoDisplaySize.size()); |
- VTTRegion* region = 0; |
- if (cue->track()->regions()) |
- region = cue->track()->regions()->getRegionById(cue->regionId()); |
- |
- if (!region) { |
- // If cue has an empty text track cue region identifier or there is no |
- // WebVTT region whose region identifier is identical to cue's text |
- // track cue region identifier, run the following substeps: |
- if (displayBox->hasChildNodes() && !contains(displayBox.get())) |
- // Note: the display tree of a cue is removed when the active flag of the cue is unset. |
- appendChild(displayBox); |
- } else { |
- // Let region be the WebVTT region whose region identifier |
- // matches the text track cue region identifier of cue. |
- RefPtr<HTMLDivElement> regionNode = region->getDisplayTree(document()); |
- |
- // Append the region to the viewport, if it was not already. |
- if (!contains(regionNode.get())) |
- appendChild(regionNode); |
- |
- region->appendTextTrackCueBox(displayBox); |
- } |
+ cue->updateDisplay(m_videoDisplaySize.size(), this); |
esprehn
2013/11/22 04:52:30
You probably want *this and to use references.
gasubic
2013/11/22 15:27:34
Done.
|
} |
// 11. Return output. |