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

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

Issue 397443002: [not for review] Add Draw entries to window Performance Timeline Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: git pull of third_party/WebKit Created 6 years, 5 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 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 <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <utility>
11 #include <vector>
10 12
11 #include "base/logging.h" 13 #include "base/logging.h"
12 #include "base/memory/scoped_ptr.h" 14 #include "base/memory/scoped_ptr.h"
13 #include "base/values.h" 15 #include "base/values.h"
14 #include "cc/animation/animation_delegate.h" 16 #include "cc/animation/animation_delegate.h"
15 #include "cc/animation/layer_animation_controller.h" 17 #include "cc/animation/layer_animation_controller.h"
16 #include "cc/animation/layer_animation_value_observer.h" 18 #include "cc/animation/layer_animation_value_observer.h"
17 #include "cc/animation/layer_animation_value_provider.h" 19 #include "cc/animation/layer_animation_value_provider.h"
18 #include "cc/base/cc_export.h" 20 #include "cc/base/cc_export.h"
19 #include "cc/base/region.h" 21 #include "cc/base/region.h"
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 class ScrollOffsetDelegate { 76 class ScrollOffsetDelegate {
75 public: 77 public:
76 virtual void SetTotalScrollOffset(const gfx::Vector2dF& new_value) = 0; 78 virtual void SetTotalScrollOffset(const gfx::Vector2dF& new_value) = 0;
77 virtual gfx::Vector2dF GetTotalScrollOffset() = 0; 79 virtual gfx::Vector2dF GetTotalScrollOffset() = 0;
78 virtual bool IsExternalFlingActive() const = 0; 80 virtual bool IsExternalFlingActive() const = 0;
79 }; 81 };
80 82
81 typedef LayerImplList RenderSurfaceListType; 83 typedef LayerImplList RenderSurfaceListType;
82 typedef LayerImplList LayerListType; 84 typedef LayerImplList LayerListType;
83 typedef RenderSurfaceImpl RenderSurfaceType; 85 typedef RenderSurfaceImpl RenderSurfaceType;
86 typedef std::vector<std::pair<int64_t, gfx::Rect> > DrawFrameRequestRectsType;
enne (OOO) 2014/07/22 20:44:25 This could maybe go in LayerTreeHostCommon too wit
Mike B 2014/07/25 23:09:40 Done.
84 87
85 enum RenderingContextConstants { NO_RENDERING_CONTEXT = 0 }; 88 enum RenderingContextConstants { NO_RENDERING_CONTEXT = 0 };
86 89
87 static scoped_ptr<LayerImpl> Create(LayerTreeImpl* tree_impl, int id) { 90 static scoped_ptr<LayerImpl> Create(LayerTreeImpl* tree_impl, int id) {
88 return make_scoped_ptr(new LayerImpl(tree_impl, id)); 91 return make_scoped_ptr(new LayerImpl(tree_impl, id));
89 } 92 }
90 93
91 virtual ~LayerImpl(); 94 virtual ~LayerImpl();
92 95
93 int id() const { return layer_id_; } 96 int id() const { return layer_id_; }
(...skipping 341 matching lines...) Expand 10 before | Expand all | Expand 10 after
435 return non_fast_scrollable_region_; 438 return non_fast_scrollable_region_;
436 } 439 }
437 440
438 void SetTouchEventHandlerRegion(const Region& region) { 441 void SetTouchEventHandlerRegion(const Region& region) {
439 touch_event_handler_region_ = region; 442 touch_event_handler_region_ = region;
440 } 443 }
441 const Region& touch_event_handler_region() const { 444 const Region& touch_event_handler_region() const {
442 return touch_event_handler_region_; 445 return touch_event_handler_region_;
443 } 446 }
444 447
448 void SetDrawFrameRequestRects(const DrawFrameRequestRectsType& rects) {
449 draw_frame_request_rects_ = rects;
450 }
451 const DrawFrameRequestRectsType& draw_frame_request_rects() const {
452 return draw_frame_request_rects_;
453 }
454
445 void SetDrawCheckerboardForMissingTiles(bool checkerboard) { 455 void SetDrawCheckerboardForMissingTiles(bool checkerboard) {
446 draw_checkerboard_for_missing_tiles_ = checkerboard; 456 draw_checkerboard_for_missing_tiles_ = checkerboard;
447 } 457 }
448 bool draw_checkerboard_for_missing_tiles() const { 458 bool draw_checkerboard_for_missing_tiles() const {
449 return draw_checkerboard_for_missing_tiles_; 459 return draw_checkerboard_for_missing_tiles_;
450 } 460 }
451 461
452 InputHandler::ScrollStatus TryScroll( 462 InputHandler::ScrollStatus TryScroll(
453 const gfx::PointF& screen_space_point, 463 const gfx::PointF& screen_space_point,
454 InputHandler::ScrollInputType type) const; 464 InputHandler::ScrollInputType type) const;
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after
630 bool hide_layer_and_subtree_ : 1; 640 bool hide_layer_and_subtree_ : 1;
631 bool force_render_surface_ : 1; 641 bool force_render_surface_ : 1;
632 642
633 // Cache transform_'s invertibility. 643 // Cache transform_'s invertibility.
634 bool transform_is_invertible_ : 1; 644 bool transform_is_invertible_ : 1;
635 645
636 // Set for the layer that other layers are fixed to. 646 // Set for the layer that other layers are fixed to.
637 bool is_container_for_fixed_position_layers_ : 1; 647 bool is_container_for_fixed_position_layers_ : 1;
638 Region non_fast_scrollable_region_; 648 Region non_fast_scrollable_region_;
639 Region touch_event_handler_region_; 649 Region touch_event_handler_region_;
650 DrawFrameRequestRectsType draw_frame_request_rects_;
640 SkColor background_color_; 651 SkColor background_color_;
641 652
642 float opacity_; 653 float opacity_;
643 SkXfermode::Mode blend_mode_; 654 SkXfermode::Mode blend_mode_;
644 gfx::PointF position_; 655 gfx::PointF position_;
645 gfx::Transform transform_; 656 gfx::Transform transform_;
646 657
647 LayerPositionConstraint position_constraint_; 658 LayerPositionConstraint position_constraint_;
648 659
649 gfx::Vector2dF scroll_delta_; 660 gfx::Vector2dF scroll_delta_;
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
700 DrawProperties<LayerImpl> draw_properties_; 711 DrawProperties<LayerImpl> draw_properties_;
701 712
702 scoped_refptr<base::debug::ConvertableToTraceFormat> debug_info_; 713 scoped_refptr<base::debug::ConvertableToTraceFormat> debug_info_;
703 714
704 DISALLOW_COPY_AND_ASSIGN(LayerImpl); 715 DISALLOW_COPY_AND_ASSIGN(LayerImpl);
705 }; 716 };
706 717
707 } // namespace cc 718 } // namespace cc
708 719
709 #endif // CC_LAYERS_LAYER_IMPL_H_ 720 #endif // CC_LAYERS_LAYER_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698