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 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
180 | 180 |
181 float Opacity() const; | 181 float Opacity() const; |
182 const gfx::Transform& Transform() const; | 182 const gfx::Transform& Transform() const; |
183 | 183 |
184 void SetElementId(ElementId element_id); | 184 void SetElementId(ElementId element_id); |
185 ElementId element_id() const { return element_id_; } | 185 ElementId element_id() const { return element_id_; } |
186 | 186 |
187 void SetMutableProperties(uint32_t properties); | 187 void SetMutableProperties(uint32_t properties); |
188 uint32_t mutable_properties() const { return mutable_properties_; } | 188 uint32_t mutable_properties() const { return mutable_properties_; } |
189 | 189 |
190 void set_draw_blend_mode(SkBlendMode blend_mode) { | |
191 draw_blend_mode_ = blend_mode; | |
192 } | |
193 SkBlendMode draw_blend_mode() const { return draw_blend_mode_; } | |
194 | |
195 void SetPosition(const gfx::PointF& position); | 190 void SetPosition(const gfx::PointF& position); |
196 gfx::PointF position() const { return position_; } | 191 gfx::PointF position() const { return position_; } |
197 | 192 |
198 bool IsAffectedByPageScale() const; | 193 bool IsAffectedByPageScale() const; |
199 | 194 |
200 gfx::Vector2dF FixedContainerSizeDelta() const; | 195 gfx::Vector2dF FixedContainerSizeDelta() const; |
201 | 196 |
202 bool Is3dSorted() const { return GetSortingContextId() != 0; } | 197 bool Is3dSorted() const { return GetSortingContextId() != 0; } |
203 | 198 |
204 void SetUseParentBackfaceVisibility(bool use) { | 199 void SetUseParentBackfaceVisibility(bool use) { |
(...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
505 | 500 |
506 // This is true if and only if the layer was ever ready since it last animated | 501 // This is true if and only if the layer was ever ready since it last animated |
507 // (all content was complete). | 502 // (all content was complete). |
508 bool was_ever_ready_since_last_transform_animation_ : 1; | 503 bool was_ever_ready_since_last_transform_animation_ : 1; |
509 | 504 |
510 Region non_fast_scrollable_region_; | 505 Region non_fast_scrollable_region_; |
511 Region touch_event_handler_region_; | 506 Region touch_event_handler_region_; |
512 SkColor background_color_; | 507 SkColor background_color_; |
513 SkColor safe_opaque_background_color_; | 508 SkColor safe_opaque_background_color_; |
514 | 509 |
515 SkBlendMode draw_blend_mode_; | |
516 gfx::PointF position_; | 510 gfx::PointF position_; |
517 | 511 |
518 gfx::Rect clip_rect_in_target_space_; | 512 gfx::Rect clip_rect_in_target_space_; |
519 int transform_tree_index_; | 513 int transform_tree_index_; |
520 int effect_tree_index_; | 514 int effect_tree_index_; |
521 int clip_tree_index_; | 515 int clip_tree_index_; |
522 int scroll_tree_index_; | 516 int scroll_tree_index_; |
523 | 517 |
524 protected: | 518 protected: |
525 friend class TreeSynchronizer; | 519 friend class TreeSynchronizer; |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
561 // the overlay scrollbars. It's set on the scroll layer (not the scrollbar | 555 // the overlay scrollbars. It's set on the scroll layer (not the scrollbar |
562 // layers) and consumed by LayerTreeImpl::PushPropertiesTo during activation. | 556 // layers) and consumed by LayerTreeImpl::PushPropertiesTo during activation. |
563 bool needs_show_scrollbars_ : 1; | 557 bool needs_show_scrollbars_ : 1; |
564 | 558 |
565 DISALLOW_COPY_AND_ASSIGN(LayerImpl); | 559 DISALLOW_COPY_AND_ASSIGN(LayerImpl); |
566 }; | 560 }; |
567 | 561 |
568 } // namespace cc | 562 } // namespace cc |
569 | 563 |
570 #endif // CC_LAYERS_LAYER_IMPL_H_ | 564 #endif // CC_LAYERS_LAYER_IMPL_H_ |
OLD | NEW |