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

Unified Diff: cc/layers/video_layer_impl.cc

Issue 609663003: cc: Remove use of PassAs() and constructor-casting with scoped_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: cc-passas: PassAs-presubmit-warning Created 6 years, 3 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 | « cc/layers/video_layer.cc ('k') | cc/output/bsp_tree.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layers/video_layer_impl.cc
diff --git a/cc/layers/video_layer_impl.cc b/cc/layers/video_layer_impl.cc
index 4bfd1cd58030af5e1f72715966d31b7aa0ee097b..2edea947da42c07b0b00bb3db1ae402f44ab918e 100644
--- a/cc/layers/video_layer_impl.cc
+++ b/cc/layers/video_layer_impl.cc
@@ -59,8 +59,7 @@ VideoLayerImpl::~VideoLayerImpl() {
scoped_ptr<LayerImpl> VideoLayerImpl::CreateLayerImpl(
LayerTreeImpl* tree_impl) {
- VideoLayerImpl* impl = new VideoLayerImpl(tree_impl, id(), video_rotation_);
- return scoped_ptr<LayerImpl>(impl);
+ return make_scoped_ptr(new VideoLayerImpl(tree_impl, id(), video_rotation_));
}
void VideoLayerImpl::PushPropertiesTo(LayerImpl* layer) {
@@ -90,7 +89,7 @@ bool VideoLayerImpl::WillDraw(DrawMode draw_mode,
if (!frame_.get()) {
// Drop any resources used by the updater if there is no frame to display.
- updater_.reset();
+ updater_ = nullptr;
provider_client_impl_->ReleaseLock();
return false;
@@ -358,7 +357,7 @@ void VideoLayerImpl::DidDraw(ResourceProvider* resource_provider) {
}
void VideoLayerImpl::ReleaseResources() {
- updater_.reset();
+ updater_ = nullptr;
}
void VideoLayerImpl::SetNeedsRedraw() {
« no previous file with comments | « cc/layers/video_layer.cc ('k') | cc/output/bsp_tree.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698