Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(560)

Unified Diff: Source/core/html/HTMLMediaElement.cpp

Issue 988763002: Start separating the text track container from the media controls (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase. Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/html/HTMLMediaElement.h ('k') | Source/core/html/shadow/MediaControlElementTypes.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/HTMLMediaElement.cpp
diff --git a/Source/core/html/HTMLMediaElement.cpp b/Source/core/html/HTMLMediaElement.cpp
index 7fd328004969439596d6fa4f05e447e326577f0f..218ddafc271c5396ec90e83cb455a870a8cd3f91 100644
--- a/Source/core/html/HTMLMediaElement.cpp
+++ b/Source/core/html/HTMLMediaElement.cpp
@@ -55,6 +55,7 @@
#include "core/html/track/AutomaticTrackSelection.h"
#include "core/html/track/CueTimeline.h"
#include "core/html/track/InbandTextTrack.h"
+#include "core/html/track/TextTrackContainer.h"
#include "core/html/track/TextTrackList.h"
#include "core/html/track/VideoTrack.h"
#include "core/html/track/VideoTrackList.h"
@@ -3183,12 +3184,17 @@ bool HTMLMediaElement::closedCaptionsVisible() const
return m_closedCaptionsVisible;
}
+TextTrackContainer& HTMLMediaElement::ensureTextTrackContainer()
+{
+ ensureMediaControls();
+ return *mediaControls()->textTrackContainer();
+}
+
void HTMLMediaElement::updateTextTrackDisplay()
{
WTF_LOG(Media, "HTMLMediaElement::updateTextTrackDisplay(%p)", this);
- ensureMediaControls();
- mediaControls()->updateTextTrackDisplay();
+ ensureTextTrackContainer().updateDisplay(*this);
}
void HTMLMediaElement::setClosedCaptionsVisible(bool closedCaptionVisible)
« no previous file with comments | « Source/core/html/HTMLMediaElement.h ('k') | Source/core/html/shadow/MediaControlElementTypes.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698