| 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 <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 303 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 314 } | 314 } |
| 315 | 315 |
| 316 void SetMasksToBounds(bool masks_to_bounds); | 316 void SetMasksToBounds(bool masks_to_bounds); |
| 317 bool masks_to_bounds() const { return masks_to_bounds_; } | 317 bool masks_to_bounds() const { return masks_to_bounds_; } |
| 318 | 318 |
| 319 void SetContentsOpaque(bool opaque); | 319 void SetContentsOpaque(bool opaque); |
| 320 bool contents_opaque() const { return contents_opaque_; } | 320 bool contents_opaque() const { return contents_opaque_; } |
| 321 | 321 |
| 322 void SetOpacity(float opacity); | 322 void SetOpacity(float opacity); |
| 323 float opacity() const { return opacity_; } | 323 float opacity() const { return opacity_; } |
| 324 float EffectiveOpacity() const; |
| 324 bool OpacityIsAnimating() const; | 325 bool OpacityIsAnimating() const; |
| 325 bool HasPotentiallyRunningOpacityAnimation() const; | 326 bool HasPotentiallyRunningOpacityAnimation() const; |
| 326 bool OpacityIsAnimatingOnImplOnly() const; | 327 bool OpacityIsAnimatingOnImplOnly() const; |
| 327 | 328 |
| 328 void SetElementId(uint64_t element_id); | 329 void SetElementId(uint64_t element_id); |
| 329 uint64_t element_id() const { return element_id_; } | 330 uint64_t element_id() const { return element_id_; } |
| 330 | 331 |
| 331 void SetMutableProperties(uint32_t properties); | 332 void SetMutableProperties(uint32_t properties); |
| 332 uint32_t mutable_properties() const { return mutable_properties_; } | 333 uint32_t mutable_properties() const { return mutable_properties_; } |
| 333 | 334 |
| (...skipping 344 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 678 | 679 |
| 679 void set_sorted_for_recursion(bool sorted_for_recursion) { | 680 void set_sorted_for_recursion(bool sorted_for_recursion) { |
| 680 sorted_for_recursion_ = sorted_for_recursion; | 681 sorted_for_recursion_ = sorted_for_recursion; |
| 681 } | 682 } |
| 682 bool sorted_for_recursion() { return sorted_for_recursion_; } | 683 bool sorted_for_recursion() { return sorted_for_recursion_; } |
| 683 | 684 |
| 684 int num_copy_requests_in_target_subtree(); | 685 int num_copy_requests_in_target_subtree(); |
| 685 | 686 |
| 686 void UpdatePropertyTreeForScrollingAndAnimationIfNeeded(); | 687 void UpdatePropertyTreeForScrollingAndAnimationIfNeeded(); |
| 687 | 688 |
| 688 void set_is_hidden_from_property_trees(bool is_hidden) { | 689 bool IsHidden() const; |
| 689 if (is_hidden == is_hidden_from_property_trees_) | |
| 690 return; | |
| 691 is_hidden_from_property_trees_ = is_hidden; | |
| 692 SetNeedsPushProperties(); | |
| 693 } | |
| 694 bool LayerIsHidden() const; | |
| 695 | 690 |
| 696 float GetIdealContentsScale() const; | 691 float GetIdealContentsScale() const; |
| 697 | 692 |
| 698 bool was_ever_ready_since_last_transform_animation() const { | 693 bool was_ever_ready_since_last_transform_animation() const { |
| 699 return was_ever_ready_since_last_transform_animation_; | 694 return was_ever_ready_since_last_transform_animation_; |
| 700 } | 695 } |
| 701 | 696 |
| 702 void set_was_ever_ready_since_last_transform_animation(bool was_ready) { | 697 void set_was_ever_ready_since_last_transform_animation(bool was_ready) { |
| 703 was_ever_ready_since_last_transform_animation_ = was_ready; | 698 was_ever_ready_since_last_transform_animation_ = was_ready; |
| 704 } | 699 } |
| (...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 888 | 883 |
| 889 bool force_render_surface_; | 884 bool force_render_surface_; |
| 890 | 885 |
| 891 std::vector<FrameTimingRequest> frame_timing_requests_; | 886 std::vector<FrameTimingRequest> frame_timing_requests_; |
| 892 bool frame_timing_requests_dirty_; | 887 bool frame_timing_requests_dirty_; |
| 893 bool visited_; | 888 bool visited_; |
| 894 bool layer_or_descendant_is_drawn_; | 889 bool layer_or_descendant_is_drawn_; |
| 895 // If true, the layer or one of its descendants has a wheel or touch handler. | 890 // If true, the layer or one of its descendants has a wheel or touch handler. |
| 896 bool layer_or_descendant_has_input_handler_; | 891 bool layer_or_descendant_has_input_handler_; |
| 897 bool sorted_for_recursion_; | 892 bool sorted_for_recursion_; |
| 898 bool is_hidden_from_property_trees_; | |
| 899 | 893 |
| 900 DISALLOW_COPY_AND_ASSIGN(LayerImpl); | 894 DISALLOW_COPY_AND_ASSIGN(LayerImpl); |
| 901 }; | 895 }; |
| 902 | 896 |
| 903 } // namespace cc | 897 } // namespace cc |
| 904 | 898 |
| 905 #endif // CC_LAYERS_LAYER_IMPL_H_ | 899 #endif // CC_LAYERS_LAYER_IMPL_H_ |
| OLD | NEW |