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 408 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
419 virtual Region GetInvalidationRegionForDebugging(); | 419 virtual Region GetInvalidationRegionForDebugging(); |
420 | 420 |
421 virtual gfx::Rect GetEnclosingRectInTargetSpace() const; | 421 virtual gfx::Rect GetEnclosingRectInTargetSpace() const; |
422 | 422 |
423 bool has_copy_requests_in_target_subtree(); | 423 bool has_copy_requests_in_target_subtree(); |
424 | 424 |
425 void UpdatePropertyTreeForScrollingAndAnimationIfNeeded(); | 425 void UpdatePropertyTreeForScrollingAndAnimationIfNeeded(); |
426 | 426 |
427 float GetIdealContentsScale() const; | 427 float GetIdealContentsScale() const; |
428 | 428 |
429 bool was_ever_ready_since_last_transform_animation() const { | |
430 return was_ever_ready_since_last_transform_animation_; | |
431 } | |
432 | |
433 void set_was_ever_ready_since_last_transform_animation(bool was_ready) { | |
434 was_ever_ready_since_last_transform_animation_ = was_ready; | |
435 } | |
436 | |
437 void NoteLayerPropertyChanged(); | 429 void NoteLayerPropertyChanged(); |
438 | 430 |
439 void SetHasWillChangeTransformHint(bool has_will_change); | 431 void SetHasWillChangeTransformHint(bool has_will_change); |
440 bool has_will_change_transform_hint() const { | 432 bool has_will_change_transform_hint() const { |
441 return has_will_change_transform_hint_; | 433 return has_will_change_transform_hint_; |
442 } | 434 } |
443 | 435 |
444 MutatorHost* GetMutatorHost() const; | 436 MutatorHost* GetMutatorHost() const; |
445 | 437 |
446 ElementListType GetElementTypeForAnimation() const; | 438 ElementListType GetElementTypeForAnimation() const; |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
507 bool may_contain_video_ : 1; | 499 bool may_contain_video_ : 1; |
508 | 500 |
509 bool masks_to_bounds_ : 1; | 501 bool masks_to_bounds_ : 1; |
510 bool contents_opaque_ : 1; | 502 bool contents_opaque_ : 1; |
511 bool use_parent_backface_visibility_ : 1; | 503 bool use_parent_backface_visibility_ : 1; |
512 bool use_local_transform_for_backface_visibility_ : 1; | 504 bool use_local_transform_for_backface_visibility_ : 1; |
513 bool should_check_backface_visibility_ : 1; | 505 bool should_check_backface_visibility_ : 1; |
514 bool draws_content_ : 1; | 506 bool draws_content_ : 1; |
515 bool contributes_to_drawn_render_surface_ : 1; | 507 bool contributes_to_drawn_render_surface_ : 1; |
516 | 508 |
517 // This is true if and only if the layer was ever ready since it last animated | |
518 // (all content was complete). | |
519 bool was_ever_ready_since_last_transform_animation_ : 1; | |
520 | |
521 static_assert(LAST_VIEWPORT_LAYER_TYPE < (1u << 3), | 509 static_assert(LAST_VIEWPORT_LAYER_TYPE < (1u << 3), |
522 "enough bits for ViewportLayerType (viewport_layer_type_)"); | 510 "enough bits for ViewportLayerType (viewport_layer_type_)"); |
523 uint8_t viewport_layer_type_ : 3; // ViewportLayerType | 511 uint8_t viewport_layer_type_ : 3; // ViewportLayerType |
524 | 512 |
525 Region non_fast_scrollable_region_; | 513 Region non_fast_scrollable_region_; |
526 Region touch_event_handler_region_; | 514 Region touch_event_handler_region_; |
527 SkColor background_color_; | 515 SkColor background_color_; |
528 SkColor safe_opaque_background_color_; | 516 SkColor safe_opaque_background_color_; |
529 | 517 |
530 gfx::PointF position_; | 518 gfx::PointF position_; |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
577 bool needs_show_scrollbars_ : 1; | 565 bool needs_show_scrollbars_ : 1; |
578 | 566 |
579 bool raster_even_if_not_in_rsll_ : 1; | 567 bool raster_even_if_not_in_rsll_ : 1; |
580 | 568 |
581 DISALLOW_COPY_AND_ASSIGN(LayerImpl); | 569 DISALLOW_COPY_AND_ASSIGN(LayerImpl); |
582 }; | 570 }; |
583 | 571 |
584 } // namespace cc | 572 } // namespace cc |
585 | 573 |
586 #endif // CC_LAYERS_LAYER_IMPL_H_ | 574 #endif // CC_LAYERS_LAYER_IMPL_H_ |
OLD | NEW |