Index: cc/layers/painted_scrollbar_layer.cc |
diff --git a/cc/layers/painted_scrollbar_layer.cc b/cc/layers/painted_scrollbar_layer.cc |
index 83c12e8650950cb7448415eac3724b5a4cf90e66..65fb78d373bba77174dd9c5087b73396e34629be 100644 |
--- a/cc/layers/painted_scrollbar_layer.cc |
+++ b/cc/layers/painted_scrollbar_layer.cc |
@@ -23,7 +23,7 @@ |
scoped_ptr<LayerImpl> PaintedScrollbarLayer::CreateLayerImpl( |
LayerTreeImpl* tree_impl) { |
return PaintedScrollbarLayerImpl::Create( |
- tree_impl, id(), scrollbar_->Orientation()); |
+ tree_impl, id(), scrollbar_->Orientation()).PassAs<LayerImpl>(); |
} |
scoped_refptr<PaintedScrollbarLayer> PaintedScrollbarLayer::Create( |
@@ -156,8 +156,8 @@ |
// When the LTH is set to null or has changed, then this layer should remove |
// all of its associated resources. |
if (!host || host != layer_tree_host()) { |
- track_resource_ = nullptr; |
- thumb_resource_ = nullptr; |
+ track_resource_.reset(); |
+ thumb_resource_.reset(); |
} |
ContentsScalingLayer::SetLayerTreeHost(host); |
@@ -214,8 +214,9 @@ |
if (track_rect_.IsEmpty() || scaled_track_rect.IsEmpty()) { |
if (track_resource_) { |
- track_resource_ = nullptr; |
- thumb_resource_ = nullptr; |
+ track_resource_.reset(); |
+ if (thumb_resource_) |
+ thumb_resource_.reset(); |
SetNeedsPushProperties(); |
updated = true; |
} |
@@ -223,7 +224,7 @@ |
} |
if (!has_thumb_ && thumb_resource_) { |
- thumb_resource_ = nullptr; |
+ thumb_resource_.reset(); |
SetNeedsPushProperties(); |
} |