| OLD | NEW |
| 1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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 #ifndef CC_LAYERS_LAYER_IMPL_H_ | 5 #ifndef CC_LAYERS_LAYER_IMPL_H_ |
| 6 #define CC_LAYERS_LAYER_IMPL_H_ | 6 #define CC_LAYERS_LAYER_IMPL_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 204 bool masks_to_bounds() const { return masks_to_bounds_; } | 204 bool masks_to_bounds() const { return masks_to_bounds_; } |
| 205 | 205 |
| 206 void SetContentsOpaque(bool opaque); | 206 void SetContentsOpaque(bool opaque); |
| 207 bool contents_opaque() const { return contents_opaque_; } | 207 bool contents_opaque() const { return contents_opaque_; } |
| 208 | 208 |
| 209 void SetOpacity(float opacity); | 209 void SetOpacity(float opacity); |
| 210 float opacity() const { return opacity_; } | 210 float opacity() const { return opacity_; } |
| 211 bool OpacityIsAnimating() const; | 211 bool OpacityIsAnimating() const; |
| 212 bool OpacityIsAnimatingOnImplOnly() const; | 212 bool OpacityIsAnimatingOnImplOnly() const; |
| 213 | 213 |
| 214 void SetBlendMode(SkXfermode::Mode); |
| 215 SkXfermode::Mode blend_mode() const { return blend_mode_; } |
| 216 bool uses_default_blend_mode() const { |
| 217 return blend_mode_ == SkXfermode::kSrcOver_Mode; |
| 218 } |
| 219 |
| 220 void SetIsRootForIsolatedGroup(bool root); |
| 221 bool is_root_for_isolated_group() const { |
| 222 return is_root_for_isolated_group_; |
| 223 } |
| 224 |
| 214 void SetPosition(gfx::PointF position); | 225 void SetPosition(gfx::PointF position); |
| 215 gfx::PointF position() const { return position_; } | 226 gfx::PointF position() const { return position_; } |
| 216 | 227 |
| 217 void SetIsContainerForFixedPositionLayers(bool container) { | 228 void SetIsContainerForFixedPositionLayers(bool container) { |
| 218 is_container_for_fixed_position_layers_ = container; | 229 is_container_for_fixed_position_layers_ = container; |
| 219 } | 230 } |
| 220 // This is a non-trivial function in Layer. | 231 // This is a non-trivial function in Layer. |
| 221 bool IsContainerForFixedPositionLayers() const { | 232 bool IsContainerForFixedPositionLayers() const { |
| 222 return is_container_for_fixed_position_layers_; | 233 return is_container_for_fixed_position_layers_; |
| 223 } | 234 } |
| (...skipping 336 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 560 | 571 |
| 561 // Whether the "back" of this layer should draw. | 572 // Whether the "back" of this layer should draw. |
| 562 bool double_sided_; | 573 bool double_sided_; |
| 563 | 574 |
| 564 // Tracks if drawing-related properties have changed since last redraw. | 575 // Tracks if drawing-related properties have changed since last redraw. |
| 565 bool layer_property_changed_; | 576 bool layer_property_changed_; |
| 566 | 577 |
| 567 bool masks_to_bounds_; | 578 bool masks_to_bounds_; |
| 568 bool contents_opaque_; | 579 bool contents_opaque_; |
| 569 float opacity_; | 580 float opacity_; |
| 581 SkXfermode::Mode blend_mode_; |
| 582 bool is_root_for_isolated_group_; |
| 570 gfx::PointF position_; | 583 gfx::PointF position_; |
| 571 bool preserves_3d_; | 584 bool preserves_3d_; |
| 572 bool use_parent_backface_visibility_; | 585 bool use_parent_backface_visibility_; |
| 573 bool draw_checkerboard_for_missing_tiles_; | 586 bool draw_checkerboard_for_missing_tiles_; |
| 574 gfx::Transform sublayer_transform_; | 587 gfx::Transform sublayer_transform_; |
| 575 gfx::Transform transform_; | 588 gfx::Transform transform_; |
| 576 | 589 |
| 577 bool draws_content_; | 590 bool draws_content_; |
| 578 bool hide_layer_and_subtree_; | 591 bool hide_layer_and_subtree_; |
| 579 bool force_render_surface_; | 592 bool force_render_surface_; |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 627 // Group of properties that need to be computed based on the layer tree | 640 // Group of properties that need to be computed based on the layer tree |
| 628 // hierarchy before layers can be drawn. | 641 // hierarchy before layers can be drawn. |
| 629 DrawProperties<LayerImpl> draw_properties_; | 642 DrawProperties<LayerImpl> draw_properties_; |
| 630 | 643 |
| 631 DISALLOW_COPY_AND_ASSIGN(LayerImpl); | 644 DISALLOW_COPY_AND_ASSIGN(LayerImpl); |
| 632 }; | 645 }; |
| 633 | 646 |
| 634 } // namespace cc | 647 } // namespace cc |
| 635 | 648 |
| 636 #endif // CC_LAYERS_LAYER_IMPL_H_ | 649 #endif // CC_LAYERS_LAYER_IMPL_H_ |
| OLD | NEW |