Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(44)

Side by Side Diff: cc/layers/layer.h

Issue 2873593002: Force use of and cache render surface. (Closed)
Patch Set: Fix for patch 1. Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2010 The Chromium Authors. All rights reserved. 1 // Copyright 2010 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_H_ 5 #ifndef CC_LAYERS_LAYER_H_
6 #define CC_LAYERS_LAYER_H_ 6 #define CC_LAYERS_LAYER_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after
244 void SetTouchEventHandlerRegion(const Region& touch_event_handler_region); 244 void SetTouchEventHandlerRegion(const Region& touch_event_handler_region);
245 const Region& touch_event_handler_region() const { 245 const Region& touch_event_handler_region() const {
246 return inputs_.touch_event_handler_region; 246 return inputs_.touch_event_handler_region;
247 } 247 }
248 248
249 void set_did_scroll_callback( 249 void set_did_scroll_callback(
250 const base::Callback<void(const gfx::ScrollOffset&)>& callback) { 250 const base::Callback<void(const gfx::ScrollOffset&)>& callback) {
251 inputs_.did_scroll_callback = callback; 251 inputs_.did_scroll_callback = callback;
252 } 252 }
253 253
254 void SetForceRenderSurfaceForTesting(bool force_render_surface); 254 void SetForceRenderSurface(bool force_render_surface);
255 bool force_render_surface_for_testing() const { 255 bool force_render_surface() const { return force_render_surface_; }
256 return force_render_surface_for_testing_;
257 }
258 256
259 gfx::ScrollOffset CurrentScrollOffset() const { 257 gfx::ScrollOffset CurrentScrollOffset() const {
260 return inputs_.scroll_offset; 258 return inputs_.scroll_offset;
261 } 259 }
262 260
263 void SetDoubleSided(bool double_sided); 261 void SetDoubleSided(bool double_sided);
264 bool double_sided() const { return inputs_.double_sided; } 262 bool double_sided() const { return inputs_.double_sided; }
265 263
266 void SetShouldFlattenTransform(bool flatten); 264 void SetShouldFlattenTransform(bool flatten);
267 bool should_flatten_transform() const { 265 bool should_flatten_transform() const {
(...skipping 339 matching lines...) Expand 10 before | Expand all | Expand 10 after
607 int transform_tree_index_; 605 int transform_tree_index_;
608 int effect_tree_index_; 606 int effect_tree_index_;
609 int clip_tree_index_; 607 int clip_tree_index_;
610 int scroll_tree_index_; 608 int scroll_tree_index_;
611 int property_tree_sequence_number_; 609 int property_tree_sequence_number_;
612 gfx::Vector2dF offset_to_transform_parent_; 610 gfx::Vector2dF offset_to_transform_parent_;
613 bool should_flatten_transform_from_property_tree_ : 1; 611 bool should_flatten_transform_from_property_tree_ : 1;
614 bool draws_content_ : 1; 612 bool draws_content_ : 1;
615 bool use_local_transform_for_backface_visibility_ : 1; 613 bool use_local_transform_for_backface_visibility_ : 1;
616 bool should_check_backface_visibility_ : 1; 614 bool should_check_backface_visibility_ : 1;
617 bool force_render_surface_for_testing_ : 1; 615 bool force_render_surface_ : 1;
618 bool subtree_property_changed_ : 1; 616 bool subtree_property_changed_ : 1;
619 bool may_contain_video_ : 1; 617 bool may_contain_video_ : 1;
620 bool is_scroll_clip_layer_ : 1; 618 bool is_scroll_clip_layer_ : 1;
621 bool needs_show_scrollbars_ : 1; 619 bool needs_show_scrollbars_ : 1;
622 // This value is valid only when LayerTreeHost::has_copy_request() is true 620 // This value is valid only when LayerTreeHost::has_copy_request() is true
623 bool subtree_has_copy_request_ : 1; 621 bool subtree_has_copy_request_ : 1;
624 SkColor safe_opaque_background_color_; 622 SkColor safe_opaque_background_color_;
625 std::unique_ptr<std::set<Layer*>> scroll_children_; 623 std::unique_ptr<std::set<Layer*>> scroll_children_;
626 624
627 std::unique_ptr<std::set<Layer*>> clip_children_; 625 std::unique_ptr<std::set<Layer*>> clip_children_;
628 626
629 // These all act like draw properties, so don't need push properties. 627 // These all act like draw properties, so don't need push properties.
630 gfx::Rect visible_layer_rect_; 628 gfx::Rect visible_layer_rect_;
631 size_t num_unclipped_descendants_; 629 size_t num_unclipped_descendants_;
632 630
633 DISALLOW_COPY_AND_ASSIGN(Layer); 631 DISALLOW_COPY_AND_ASSIGN(Layer);
634 }; 632 };
635 633
636 } // namespace cc 634 } // namespace cc
637 635
638 #endif // CC_LAYERS_LAYER_H_ 636 #endif // CC_LAYERS_LAYER_H_
OLDNEW
« no previous file with comments | « cc/ipc/cc_param_traits.cc ('k') | cc/layers/layer.cc » ('j') | cc/quads/render_pass.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698