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

Unified Diff: media/blink/webmediaplayer_impl.cc

Issue 2495753002: Reenable idle suspension of media elements on Windows. (Closed)
Patch Set: add comment Created 4 years, 1 month 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 | « no previous file | media/gpu/dxva_picture_buffer_win.h » ('j') | 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 c746292dd77438a14580527234d2265b82549804..88934a48a32fddb4c6d990f409ae191112b35b90 100644
--- a/media/blink/webmediaplayer_impl.cc
+++ b/media/blink/webmediaplayer_impl.cc
@@ -1761,12 +1761,11 @@ void WebMediaPlayerImpl::SetSuspendState(bool is_suspended) {
if (IsNetworkStateError(network_state_))
return;
-#if !defined(OS_ANDROID) && !defined(OS_CHROMEOS) && !defined(OS_MACOSX)
+#if defined(OS_LINUX)
// TODO(sandersd): idle suspend is disabled if decoder owns video frame.
- // Used on Windows+Chromecast. Since GetCurrentFrameFromCompositor is a
- // synchronous cross-thread post, avoid the cost on platforms that always
- // allow suspend. Need to find a better mechanism for this. See
- // http://crbug.com/602708
+ // Used on Chromecast. Since GetCurrentFrameFromCompositor is a synchronous
+ // cross-thread post, avoid the cost on platforms that always allow suspend.
+ // Need to find a better mechanism for this. See http://crbug.com/602708
if (can_suspend_state_ == CanSuspendState::UNKNOWN) {
scoped_refptr<VideoFrame> frame = GetCurrentFrameFromCompositor();
if (frame) {
« no previous file with comments | « no previous file | media/gpu/dxva_picture_buffer_win.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698