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

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

Issue 1233313008: Stop calling configureTextTrackDisplay() in clearMediaPlayer() (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: proper test Created 5 years, 5 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') | no next file » | 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 0136464ef89e731646dcb0d6fced717c57badea3..9907360a470f5036452b6a14cc9d1dba1d5ef039 100644
--- a/Source/core/html/HTMLMediaElement.cpp
+++ b/Source/core/html/HTMLMediaElement.cpp
@@ -1145,7 +1145,7 @@ void HTMLMediaElement::textTrackModeChanged(TextTrack* track)
if (track->trackType() == TextTrack::TrackElement)
track->setHasBeenConfigured(true);
- configureTextTrackDisplay(AssumeVisibleChange);
+ configureTextTrackDisplay();
ASSERT(textTracks()->contains(track));
textTracks()->scheduleChangeEvent();
@@ -3072,9 +3072,6 @@ void HTMLMediaElement::clearMediaPlayer(int flags)
if (mediaControls())
mediaControls()->refreshCastButtonVisibility();
- if (m_textTracks)
- configureTextTrackDisplay(AssumeNoVisibleChange);
-
if (layoutObject())
layoutObject()->setShouldDoFullPaintInvalidation();
}
@@ -3420,7 +3417,7 @@ CueTimeline& HTMLMediaElement::cueTimeline()
return *m_cueTimeline;
}
-void HTMLMediaElement::configureTextTrackDisplay(VisibilityChangeAssumption assumption)
+void HTMLMediaElement::configureTextTrackDisplay()
{
ASSERT(m_textTracks);
WTF_LOG(Media, "HTMLMediaElement::configureTextTrackDisplay(%p)", this);
@@ -3428,14 +3425,7 @@ void HTMLMediaElement::configureTextTrackDisplay(VisibilityChangeAssumption assu
if (m_processingPreferenceChange)
return;
- bool haveVisibleTextTrack = m_textTracks->hasShowingTracks();
-
- if (assumption == AssumeNoVisibleChange
- && m_haveVisibleTextTrack == haveVisibleTextTrack) {
- cueTimeline().updateActiveCues(currentTime());
- return;
- }
- m_haveVisibleTextTrack = haveVisibleTextTrack;
+ m_haveVisibleTextTrack = m_textTracks->hasShowingTracks();
m_closedCaptionsVisible = m_haveVisibleTextTrack;
if (!m_haveVisibleTextTrack && !mediaControls())
« no previous file with comments | « Source/core/html/HTMLMediaElement.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698