| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 UI_COMPOSITOR_COMPOSITOR_H_ | 5 #ifndef UI_COMPOSITOR_COMPOSITOR_H_ |
| 6 #define UI_COMPOSITOR_COMPOSITOR_H_ | 6 #define UI_COMPOSITOR_COMPOSITOR_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 45 class LayerTreeHost; | 45 class LayerTreeHost; |
| 46 class RendererSettings; | 46 class RendererSettings; |
| 47 class SharedBitmapManager; | 47 class SharedBitmapManager; |
| 48 class SurfaceIdAllocator; | 48 class SurfaceIdAllocator; |
| 49 class SurfaceManager; | 49 class SurfaceManager; |
| 50 class TaskGraphRunner; | 50 class TaskGraphRunner; |
| 51 } | 51 } |
| 52 | 52 |
| 53 namespace gfx { | 53 namespace gfx { |
| 54 class Rect; | 54 class Rect; |
| 55 class ScrollOffset; |
| 55 class Size; | 56 class Size; |
| 56 } | 57 } |
| 57 | 58 |
| 58 namespace gpu { | 59 namespace gpu { |
| 59 class GpuMemoryBufferManager; | 60 class GpuMemoryBufferManager; |
| 60 struct Mailbox; | 61 struct Mailbox; |
| 61 } | 62 } |
| 62 | 63 |
| 63 namespace ui { | 64 namespace ui { |
| 64 | 65 |
| (...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 261 // Sets the background color used for areas that aren't covered by | 262 // Sets the background color used for areas that aren't covered by |
| 262 // the |root_layer|. | 263 // the |root_layer|. |
| 263 void SetBackgroundColor(SkColor color); | 264 void SetBackgroundColor(SkColor color); |
| 264 | 265 |
| 265 // Sets the visibility of the underlying compositor. | 266 // Sets the visibility of the underlying compositor. |
| 266 void SetVisible(bool visible); | 267 void SetVisible(bool visible); |
| 267 | 268 |
| 268 // Gets the visibility of the underlying compositor. | 269 // Gets the visibility of the underlying compositor. |
| 269 bool IsVisible(); | 270 bool IsVisible(); |
| 270 | 271 |
| 272 // Gets or sets the scroll offset for the given layer in step with the |
| 273 // cc::InputHandler. Returns true if the layer is active on the impl side. |
| 274 bool GetScrollOffsetForLayer(int layer_id, gfx::ScrollOffset* offset) const; |
| 275 bool ScrollLayerTo(int layer_id, const gfx::ScrollOffset& offset); |
| 276 |
| 271 // The "authoritative" vsync interval, if provided, will override interval | 277 // The "authoritative" vsync interval, if provided, will override interval |
| 272 // reported from 3D context. This is typically the value reported by a more | 278 // reported from 3D context. This is typically the value reported by a more |
| 273 // reliable source, e.g, the platform display configuration. | 279 // reliable source, e.g, the platform display configuration. |
| 274 // In the particular case of ChromeOS -- this is the value queried through | 280 // In the particular case of ChromeOS -- this is the value queried through |
| 275 // XRandR, which is more reliable than the value queried through the 3D | 281 // XRandR, which is more reliable than the value queried through the 3D |
| 276 // context. | 282 // context. |
| 277 void SetAuthoritativeVSyncInterval(const base::TimeDelta& interval); | 283 void SetAuthoritativeVSyncInterval(const base::TimeDelta& interval); |
| 278 | 284 |
| 279 // Sets the widget for the compositor to render into. | 285 // Sets the widget for the compositor to render into. |
| 280 void SetAcceleratedWidget(gfx::AcceleratedWidget widget); | 286 void SetAcceleratedWidget(gfx::AcceleratedWidget widget); |
| (...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 418 scoped_refptr<cc::AnimationTimeline> animation_timeline_; | 424 scoped_refptr<cc::AnimationTimeline> animation_timeline_; |
| 419 | 425 |
| 420 base::WeakPtrFactory<Compositor> weak_ptr_factory_; | 426 base::WeakPtrFactory<Compositor> weak_ptr_factory_; |
| 421 | 427 |
| 422 DISALLOW_COPY_AND_ASSIGN(Compositor); | 428 DISALLOW_COPY_AND_ASSIGN(Compositor); |
| 423 }; | 429 }; |
| 424 | 430 |
| 425 } // namespace ui | 431 } // namespace ui |
| 426 | 432 |
| 427 #endif // UI_COMPOSITOR_COMPOSITOR_H_ | 433 #endif // UI_COMPOSITOR_COMPOSITOR_H_ |
| OLD | NEW |