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

Unified Diff: media/blink/webmediaplayer_impl.cc

Issue 1808463002: Don't mark a WebMediaPlayer as idle until it has size and first frame. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2661
Patch Set: Created 4 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 | « media/blink/webmediaplayer_delegate.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/blink/webmediaplayer_impl.cc
diff --git a/media/blink/webmediaplayer_impl.cc b/media/blink/webmediaplayer_impl.cc
index 8b777e350c3f852ef628d4628b0e93109b5598a8..be5fa48921bf8b2eda5641bc90d184e63625f21f 100644
--- a/media/blink/webmediaplayer_impl.cc
+++ b/media/blink/webmediaplayer_impl.cc
@@ -1024,6 +1024,11 @@ void WebMediaPlayerImpl::OnPipelineMetadata(
if (delegate_ && delegate_->IsHidden())
OnHidden(false);
}
+
+ // Tell the delegate we can now be safely suspended due to inactivity if a
+ // subsequent play event does not occur.
+ if (paused_)
+ NotifyPlaybackPaused();
}
void WebMediaPlayerImpl::OnPipelineBufferingStateChanged(
« no previous file with comments | « media/blink/webmediaplayer_delegate.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698