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_LAYER_IMPL_H_ | 5 #ifndef CC_LAYER_IMPL_H_ |
6 #define CC_LAYER_IMPL_H_ | 6 #define CC_LAYER_IMPL_H_ |
7 | 7 |
8 #include <public/WebFilterOperations.h> | 8 #include <public/WebFilterOperations.h> |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "base/logging.h" | 11 #include "base/logging.h" |
12 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
13 #include "cc/cc_export.h" | 13 #include "cc/cc_export.h" |
14 #include "cc/draw_properties.h" | 14 #include "cc/draw_properties.h" |
15 #include "cc/input_handler.h" | 15 #include "cc/input_handler.h" |
16 #include "cc/layer_animation_controller.h" | 16 #include "cc/layer_animation_controller.h" |
17 #include "cc/region.h" | 17 #include "cc/region.h" |
18 #include "cc/render_pass.h" | 18 #include "cc/render_pass.h" |
19 #include "cc/render_surface_impl.h" | 19 #include "cc/render_surface_impl.h" |
20 #include "cc/resource_provider.h" | 20 #include "cc/resource_provider.h" |
21 #include "cc/scoped_ptr_vector.h" | 21 #include "cc/scoped_ptr_vector.h" |
22 #include "cc/shared_quad_state.h" | 22 #include "cc/shared_quad_state.h" |
23 #include "skia/ext/refptr.h" | 23 #include "skia/ext/refptr.h" |
24 #include "third_party/skia/include/core/SkColor.h" | 24 #include "third_party/skia/include/core/SkColor.h" |
25 #include "third_party/skia/include/core/SkImageFilter.h" | 25 #include "third_party/skia/include/core/SkImageFilter.h" |
26 #include "ui/gfx/rect.h" | 26 #include "ui/gfx/rect.h" |
27 #include "ui/gfx/rect_f.h" | 27 #include "ui/gfx/rect_f.h" |
28 #include "ui/gfx/transform.h" | 28 #include "ui/gfx/transform.h" |
29 | 29 |
| 30 namespace base { |
| 31 class DictionaryValue; |
| 32 } |
| 33 |
30 namespace cc { | 34 namespace cc { |
31 | 35 |
32 class LayerTreeHostImpl; | 36 class LayerTreeHostImpl; |
33 class QuadSink; | 37 class QuadSink; |
34 class Renderer; | 38 class Renderer; |
35 class ScrollbarAnimationController; | 39 class ScrollbarAnimationController; |
36 class ScrollbarLayerImpl; | 40 class ScrollbarLayerImpl; |
37 class Layer; | 41 class Layer; |
38 | 42 |
39 struct AppendQuadsData; | 43 struct AppendQuadsData; |
(...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
235 void setDoubleSided(bool); | 239 void setDoubleSided(bool); |
236 | 240 |
237 void setTransform(const gfx::Transform&); | 241 void setTransform(const gfx::Transform&); |
238 const gfx::Transform& transform() const; | 242 const gfx::Transform& transform() const; |
239 bool transformIsAnimating() const; | 243 bool transformIsAnimating() const; |
240 | 244 |
241 const gfx::RectF& updateRect() const { return m_updateRect; } | 245 const gfx::RectF& updateRect() const { return m_updateRect; } |
242 void setUpdateRect(const gfx::RectF& updateRect) { m_updateRect = updateRect
; } | 246 void setUpdateRect(const gfx::RectF& updateRect) { m_updateRect = updateRect
; } |
243 | 247 |
244 std::string layerTreeAsText() const; | 248 std::string layerTreeAsText() const; |
| 249 virtual base::DictionaryValue* layerTreeAsJson() const; |
245 | 250 |
246 void setStackingOrderChanged(bool); | 251 void setStackingOrderChanged(bool); |
247 | 252 |
248 bool layerPropertyChanged() const { return m_layerPropertyChanged || layerIs
AlwaysDamaged(); } | 253 bool layerPropertyChanged() const { return m_layerPropertyChanged || layerIs
AlwaysDamaged(); } |
249 bool layerSurfacePropertyChanged() const; | 254 bool layerSurfacePropertyChanged() const; |
250 | 255 |
251 void resetAllChangeTrackingForSubtree(); | 256 void resetAllChangeTrackingForSubtree(); |
252 | 257 |
253 virtual bool layerIsAlwaysDamaged() const; | 258 virtual bool layerIsAlwaysDamaged() const; |
254 | 259 |
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
389 // Group of properties that need to be computed based on the layer tree | 394 // Group of properties that need to be computed based on the layer tree |
390 // hierarchy before layers can be drawn. | 395 // hierarchy before layers can be drawn. |
391 DrawProperties<LayerImpl, RenderSurfaceImpl> m_drawProperties; | 396 DrawProperties<LayerImpl, RenderSurfaceImpl> m_drawProperties; |
392 | 397 |
393 DISALLOW_COPY_AND_ASSIGN(LayerImpl); | 398 DISALLOW_COPY_AND_ASSIGN(LayerImpl); |
394 }; | 399 }; |
395 | 400 |
396 } | 401 } |
397 | 402 |
398 #endif // CC_LAYER_IMPL_H_ | 403 #endif // CC_LAYER_IMPL_H_ |
OLD | NEW |