| 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 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 120 // AnimationDelegate implementation. | 120 // AnimationDelegate implementation. |
| 121 void NotifyAnimationStarted(base::TimeTicks monotonic_time, | 121 void NotifyAnimationStarted(base::TimeTicks monotonic_time, |
| 122 TargetProperty::Type target_property, | 122 TargetProperty::Type target_property, |
| 123 int group) override{}; | 123 int group) override{}; |
| 124 void NotifyAnimationFinished(base::TimeTicks monotonic_time, | 124 void NotifyAnimationFinished(base::TimeTicks monotonic_time, |
| 125 TargetProperty::Type target_property, | 125 TargetProperty::Type target_property, |
| 126 int group) override; | 126 int group) override; |
| 127 void NotifyAnimationAborted(base::TimeTicks monotonic_time, | 127 void NotifyAnimationAborted(base::TimeTicks monotonic_time, |
| 128 TargetProperty::Type target_property, | 128 TargetProperty::Type target_property, |
| 129 int group) override{}; | 129 int group) override{}; |
| 130 void NotifyAnimationTakeover(base::TimeTicks monotonic_time, |
| 131 double animation_start_time, |
| 132 scoped_ptr<AnimationCurve> curve) override {} |
| 130 | 133 |
| 131 // Tree structure. | 134 // Tree structure. |
| 132 LayerImpl* parent() { return parent_; } | 135 LayerImpl* parent() { return parent_; } |
| 133 const LayerImpl* parent() const { return parent_; } | 136 const LayerImpl* parent() const { return parent_; } |
| 134 const OwnedLayerImplList& children() const { return children_; } | 137 const OwnedLayerImplList& children() const { return children_; } |
| 135 OwnedLayerImplList& children() { return children_; } | 138 OwnedLayerImplList& children() { return children_; } |
| 136 LayerImpl* child_at(size_t index) const { return children_[index].get(); } | 139 LayerImpl* child_at(size_t index) const { return children_[index].get(); } |
| 137 void AddChild(scoped_ptr<LayerImpl> child); | 140 void AddChild(scoped_ptr<LayerImpl> child); |
| 138 scoped_ptr<LayerImpl> RemoveChild(LayerImpl* child); | 141 scoped_ptr<LayerImpl> RemoveChild(LayerImpl* child); |
| 139 void SetParent(LayerImpl* parent); | 142 void SetParent(LayerImpl* parent); |
| (...skipping 358 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 498 void set_user_scrollable_vertical(bool scrollable) { | 501 void set_user_scrollable_vertical(bool scrollable) { |
| 499 user_scrollable_vertical_ = scrollable; | 502 user_scrollable_vertical_ = scrollable; |
| 500 } | 503 } |
| 501 bool user_scrollable_vertical() const { return user_scrollable_vertical_; } | 504 bool user_scrollable_vertical() const { return user_scrollable_vertical_; } |
| 502 | 505 |
| 503 bool user_scrollable(ScrollbarOrientation orientation) const; | 506 bool user_scrollable(ScrollbarOrientation orientation) const; |
| 504 | 507 |
| 505 void ApplySentScrollDeltasFromAbortedCommit(); | 508 void ApplySentScrollDeltasFromAbortedCommit(); |
| 506 | 509 |
| 507 void set_main_thread_scrolling_reasons( | 510 void set_main_thread_scrolling_reasons( |
| 508 uint32_t main_thread_scrolling_reasons) { | 511 uint32_t main_thread_scrolling_reasons); |
| 509 main_thread_scrolling_reasons_ = main_thread_scrolling_reasons; | |
| 510 } | |
| 511 uint32_t main_thread_scrolling_reasons() const { | 512 uint32_t main_thread_scrolling_reasons() const { |
| 512 return main_thread_scrolling_reasons_; | 513 return main_thread_scrolling_reasons_; |
| 513 } | 514 } |
| 514 bool should_scroll_on_main_thread() const { | 515 bool should_scroll_on_main_thread() const { |
| 515 return !!main_thread_scrolling_reasons_; | 516 return !!main_thread_scrolling_reasons_; |
| 516 } | 517 } |
| 517 | 518 |
| 518 void SetNonFastScrollableRegion(const Region& region) { | 519 void SetNonFastScrollableRegion(const Region& region) { |
| 519 non_fast_scrollable_region_ = region; | 520 non_fast_scrollable_region_ = region; |
| 520 } | 521 } |
| (...skipping 352 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 873 // If true, the layer or one of its descendants has a touch handler. | 874 // If true, the layer or one of its descendants has a touch handler. |
| 874 bool layer_or_descendant_has_touch_handler_; | 875 bool layer_or_descendant_has_touch_handler_; |
| 875 bool sorted_for_recursion_; | 876 bool sorted_for_recursion_; |
| 876 | 877 |
| 877 DISALLOW_COPY_AND_ASSIGN(LayerImpl); | 878 DISALLOW_COPY_AND_ASSIGN(LayerImpl); |
| 878 }; | 879 }; |
| 879 | 880 |
| 880 } // namespace cc | 881 } // namespace cc |
| 881 | 882 |
| 882 #endif // CC_LAYERS_LAYER_IMPL_H_ | 883 #endif // CC_LAYERS_LAYER_IMPL_H_ |
| OLD | NEW |