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

Side by Side Diff: content/renderer/media/webmediaplayer_impl.cc

Issue 204463008: Remove all calls to WebMediaPlayerClient::needsWebLayerForVideo() as compositing is always enabled. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/renderer/media/webmediaplayer_impl.h" 5 #include "content/renderer/media/webmediaplayer_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <limits> 8 #include <limits>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 960 matching lines...) Expand 10 before | Expand all | Expand 10 after
971 971
972 switch (buffering_state) { 972 switch (buffering_state) {
973 case media::Pipeline::kHaveMetadata: 973 case media::Pipeline::kHaveMetadata:
974 // TODO(scherkus): Would be better to have a metadata changed callback 974 // TODO(scherkus): Would be better to have a metadata changed callback
975 // that contained the size information as well whether audio/video is 975 // that contained the size information as well whether audio/video is
976 // present. Doing so would let us remove more methods off Pipeline. 976 // present. Doing so would let us remove more methods off Pipeline.
977 natural_size_ = pipeline_.GetInitialNaturalSize(); 977 natural_size_ = pipeline_.GetInitialNaturalSize();
978 978
979 SetReadyState(WebMediaPlayer::ReadyStateHaveMetadata); 979 SetReadyState(WebMediaPlayer::ReadyStateHaveMetadata);
980 980
981 if (hasVideo() && client_->needsWebLayerForVideo()) { 981 if (hasVideo()) {
982 DCHECK(!video_weblayer_); 982 DCHECK(!video_weblayer_);
983 video_weblayer_.reset( 983 video_weblayer_.reset(
984 new webkit::WebLayerImpl(cc::VideoLayer::Create(this))); 984 new webkit::WebLayerImpl(cc::VideoLayer::Create(this)));
985 client_->setWebLayer(video_weblayer_.get()); 985 client_->setWebLayer(video_weblayer_.get());
986 } 986 }
987 break; 987 break;
988 case media::Pipeline::kPrerollCompleted: 988 case media::Pipeline::kPrerollCompleted:
989 // Only transition to ReadyStateHaveEnoughData if we don't have 989 // Only transition to ReadyStateHaveEnoughData if we don't have
990 // any pending seeks because the transition can cause Blink to 990 // any pending seeks because the transition can cause Blink to
991 // report that the most recent seek has completed. 991 // report that the most recent seek has completed.
(...skipping 328 matching lines...) Expand 10 before | Expand all | Expand 10 after
1320 1320
1321 if (web_cdm_) { 1321 if (web_cdm_) {
1322 decryptor_ready_cb.Run(web_cdm_->GetDecryptor()); 1322 decryptor_ready_cb.Run(web_cdm_->GetDecryptor());
1323 return; 1323 return;
1324 } 1324 }
1325 1325
1326 decryptor_ready_cb_ = decryptor_ready_cb; 1326 decryptor_ready_cb_ = decryptor_ready_cb;
1327 } 1327 }
1328 1328
1329 } // namespace content 1329 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/media/android/webmediaplayer_android.cc ('k') | content/renderer/media/webmediaplayer_ms.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698