OLD | NEW |
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 <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
247 return draw_properties_.screen_space_transform_is_animating; | 247 return draw_properties_.screen_space_transform_is_animating; |
248 } | 248 } |
249 bool screen_space_opacity_is_animating() const { | 249 bool screen_space_opacity_is_animating() const { |
250 return draw_properties_.screen_space_opacity_is_animating; | 250 return draw_properties_.screen_space_opacity_is_animating; |
251 } | 251 } |
252 bool is_clipped() const { return draw_properties_.is_clipped; } | 252 bool is_clipped() const { return draw_properties_.is_clipped; } |
253 gfx::Rect clip_rect() const { return draw_properties_.clip_rect; } | 253 gfx::Rect clip_rect() const { return draw_properties_.clip_rect; } |
254 gfx::Rect drawable_content_rect() const { | 254 gfx::Rect drawable_content_rect() const { |
255 return draw_properties_.drawable_content_rect; | 255 return draw_properties_.drawable_content_rect; |
256 } | 256 } |
257 gfx::Rect visible_content_rect() const { | 257 gfx::Rect visible_layer_rect() const { |
258 return draw_properties_.visible_content_rect; | 258 return draw_properties_.visible_layer_rect; |
259 } | 259 } |
260 Layer* render_target() { | 260 Layer* render_target() { |
261 DCHECK(!draw_properties_.render_target || | 261 DCHECK(!draw_properties_.render_target || |
262 draw_properties_.render_target->render_surface()); | 262 draw_properties_.render_target->render_surface()); |
263 return draw_properties_.render_target; | 263 return draw_properties_.render_target; |
264 } | 264 } |
265 const Layer* render_target() const { | 265 const Layer* render_target() const { |
266 DCHECK(!draw_properties_.render_target || | 266 DCHECK(!draw_properties_.render_target || |
267 draw_properties_.render_target->render_surface()); | 267 draw_properties_.render_target->render_surface()); |
268 return draw_properties_.render_target; | 268 return draw_properties_.render_target; |
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
417 } | 417 } |
418 | 418 |
419 bool HasActiveAnimation() const; | 419 bool HasActiveAnimation() const; |
420 void RegisterForAnimations(AnimationRegistrar* registrar); | 420 void RegisterForAnimations(AnimationRegistrar* registrar); |
421 | 421 |
422 void AddLayerAnimationEventObserver( | 422 void AddLayerAnimationEventObserver( |
423 LayerAnimationEventObserver* animation_observer); | 423 LayerAnimationEventObserver* animation_observer); |
424 void RemoveLayerAnimationEventObserver( | 424 void RemoveLayerAnimationEventObserver( |
425 LayerAnimationEventObserver* animation_observer); | 425 LayerAnimationEventObserver* animation_observer); |
426 | 426 |
427 virtual SimpleEnclosedRegion VisibleContentOpaqueRegion() const; | |
428 | |
429 virtual ScrollbarLayerInterface* ToScrollbarLayer(); | 427 virtual ScrollbarLayerInterface* ToScrollbarLayer(); |
430 | 428 |
431 virtual skia::RefPtr<SkPicture> GetPicture() const; | 429 virtual skia::RefPtr<SkPicture> GetPicture() const; |
432 | 430 |
433 // Constructs a LayerImpl of the correct runtime type for this Layer type. | 431 // Constructs a LayerImpl of the correct runtime type for this Layer type. |
434 virtual scoped_ptr<LayerImpl> CreateLayerImpl(LayerTreeImpl* tree_impl); | 432 virtual scoped_ptr<LayerImpl> CreateLayerImpl(LayerTreeImpl* tree_impl); |
435 | 433 |
436 bool NeedsDisplayForTesting() const { return !update_rect_.IsEmpty(); } | 434 bool NeedsDisplayForTesting() const { return !update_rect_.IsEmpty(); } |
437 void ResetNeedsDisplayForTesting() { update_rect_ = gfx::Rect(); } | 435 void ResetNeedsDisplayForTesting() { update_rect_ = gfx::Rect(); } |
438 | 436 |
(...skipping 341 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
780 | 778 |
781 std::vector<FrameTimingRequest> frame_timing_requests_; | 779 std::vector<FrameTimingRequest> frame_timing_requests_; |
782 bool frame_timing_requests_dirty_; | 780 bool frame_timing_requests_dirty_; |
783 | 781 |
784 DISALLOW_COPY_AND_ASSIGN(Layer); | 782 DISALLOW_COPY_AND_ASSIGN(Layer); |
785 }; | 783 }; |
786 | 784 |
787 } // namespace cc | 785 } // namespace cc |
788 | 786 |
789 #endif // CC_LAYERS_LAYER_H_ | 787 #endif // CC_LAYERS_LAYER_H_ |
OLD | NEW |