Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "cc/blink/web_layer_impl.h" | 5 #include "cc/blink/web_layer_impl.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 60 WebLayerImpl::WebLayerImpl(scoped_refptr<Layer> layer) | 60 WebLayerImpl::WebLayerImpl(scoped_refptr<Layer> layer) |
| 61 : layer_(layer), contents_opaque_is_fixed_(false) { | 61 : layer_(layer), contents_opaque_is_fixed_(false) { |
| 62 web_layer_client_ = nullptr; | 62 web_layer_client_ = nullptr; |
| 63 layer_->SetLayerClient(this); | 63 layer_->SetLayerClient(this); |
| 64 } | 64 } |
| 65 | 65 |
| 66 WebLayerImpl::~WebLayerImpl() { | 66 WebLayerImpl::~WebLayerImpl() { |
| 67 if (animation_delegate_adapter_.get()) | 67 if (animation_delegate_adapter_.get()) |
| 68 layer_->set_layer_animation_delegate(nullptr); | 68 layer_->set_layer_animation_delegate(nullptr); |
| 69 web_layer_client_ = nullptr; | 69 web_layer_client_ = nullptr; |
| 70 layer_->SetLayerClient(nullptr); | |
|
enne (OOO)
2015/10/21 00:04:12
Oh! Kind of surprised this managed to not be here
| |
| 70 } | 71 } |
| 71 | 72 |
| 72 // static | 73 // static |
| 73 void WebLayerImpl::SetLayerSettings(const cc::LayerSettings& settings) { | 74 void WebLayerImpl::SetLayerSettings(const cc::LayerSettings& settings) { |
| 74 g_layer_settings.Get() = settings; | 75 g_layer_settings.Get() = settings; |
| 75 } | 76 } |
| 76 | 77 |
| 77 // static | 78 // static |
| 78 const cc::LayerSettings& WebLayerImpl::LayerSettings() { | 79 const cc::LayerSettings& WebLayerImpl::LayerSettings() { |
| 79 return g_layer_settings.Get(); | 80 return g_layer_settings.Get(); |
| (...skipping 458 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 538 | 539 |
| 539 Layer* WebLayerImpl::layer() const { | 540 Layer* WebLayerImpl::layer() const { |
| 540 return layer_.get(); | 541 return layer_.get(); |
| 541 } | 542 } |
| 542 | 543 |
| 543 void WebLayerImpl::SetContentsOpaqueIsFixed(bool fixed) { | 544 void WebLayerImpl::SetContentsOpaqueIsFixed(bool fixed) { |
| 544 contents_opaque_is_fixed_ = fixed; | 545 contents_opaque_is_fixed_ = fixed; |
| 545 } | 546 } |
| 546 | 547 |
| 547 } // namespace cc_blink | 548 } // namespace cc_blink |
| OLD | NEW |