| 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 "sky/viewer/cc/web_layer_impl.h" | 5 #include "sky/viewer/cc/web_layer_impl.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/debug/trace_event_impl.h" | 8 #include "base/debug/trace_event_impl.h" |
| 9 #include "base/lazy_instance.h" | 9 #include "base/lazy_instance.h" |
| 10 #include "base/strings/string_util.h" | 10 #include "base/strings/string_util.h" |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 143 } | 143 } |
| 144 | 144 |
| 145 void WebLayerImpl::setBlendMode(blink::WebBlendMode blend_mode) { | 145 void WebLayerImpl::setBlendMode(blink::WebBlendMode blend_mode) { |
| 146 layer_->SetBlendMode(BlendModeToSkia(blend_mode)); | 146 layer_->SetBlendMode(BlendModeToSkia(blend_mode)); |
| 147 } | 147 } |
| 148 | 148 |
| 149 blink::WebBlendMode WebLayerImpl::blendMode() const { | 149 blink::WebBlendMode WebLayerImpl::blendMode() const { |
| 150 return BlendModeFromSkia(layer_->blend_mode()); | 150 return BlendModeFromSkia(layer_->blend_mode()); |
| 151 } | 151 } |
| 152 | 152 |
| 153 void WebLayerImpl::setIsRootForIsolatedGroup(bool isolate) { | |
| 154 layer_->SetIsRootForIsolatedGroup(isolate); | |
| 155 } | |
| 156 | |
| 157 bool WebLayerImpl::isRootForIsolatedGroup() { | |
| 158 return layer_->is_root_for_isolated_group(); | |
| 159 } | |
| 160 | |
| 161 void WebLayerImpl::setOpaque(bool opaque) { | 153 void WebLayerImpl::setOpaque(bool opaque) { |
| 162 layer_->SetContentsOpaque(opaque); | 154 layer_->SetContentsOpaque(opaque); |
| 163 } | 155 } |
| 164 | 156 |
| 165 bool WebLayerImpl::opaque() const { | 157 bool WebLayerImpl::opaque() const { |
| 166 return layer_->contents_opaque(); | 158 return layer_->contents_opaque(); |
| 167 } | 159 } |
| 168 | 160 |
| 169 void WebLayerImpl::setPosition(const WebFloatPoint& position) { | 161 void WebLayerImpl::setPosition(const WebFloatPoint& position) { |
| 170 layer_->SetPosition(position); | 162 layer_->SetPosition(position); |
| (...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 349 if (parent) | 341 if (parent) |
| 350 clip_parent = static_cast<WebLayerImpl*>(parent)->layer(); | 342 clip_parent = static_cast<WebLayerImpl*>(parent)->layer(); |
| 351 layer_->SetClipParent(clip_parent); | 343 layer_->SetClipParent(clip_parent); |
| 352 } | 344 } |
| 353 | 345 |
| 354 Layer* WebLayerImpl::layer() const { | 346 Layer* WebLayerImpl::layer() const { |
| 355 return layer_.get(); | 347 return layer_.get(); |
| 356 } | 348 } |
| 357 | 349 |
| 358 } // namespace sky_viewer_cc | 350 } // namespace sky_viewer_cc |
| OLD | NEW |