| 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 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 44 class LayerTreeHost; | 44 class LayerTreeHost; |
| 45 class RendererSettings; | 45 class RendererSettings; |
| 46 class SharedBitmapManager; | 46 class SharedBitmapManager; |
| 47 class SurfaceIdAllocator; | 47 class SurfaceIdAllocator; |
| 48 class SurfaceManager; | 48 class SurfaceManager; |
| 49 class TaskGraphRunner; | 49 class TaskGraphRunner; |
| 50 } | 50 } |
| 51 | 51 |
| 52 namespace gfx { | 52 namespace gfx { |
| 53 class Rect; | 53 class Rect; |
| 54 class ScrollOffset; |
| 54 class Size; | 55 class Size; |
| 55 } | 56 } |
| 56 | 57 |
| 57 namespace gpu { | 58 namespace gpu { |
| 58 class GpuMemoryBufferManager; | 59 class GpuMemoryBufferManager; |
| 59 struct Mailbox; | 60 struct Mailbox; |
| 60 } | 61 } |
| 61 | 62 |
| 62 namespace ui { | 63 namespace ui { |
| 63 | 64 |
| (...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 259 // Sets the background color used for areas that aren't covered by | 260 // Sets the background color used for areas that aren't covered by |
| 260 // the |root_layer|. | 261 // the |root_layer|. |
| 261 void SetBackgroundColor(SkColor color); | 262 void SetBackgroundColor(SkColor color); |
| 262 | 263 |
| 263 // Sets the visibility of the underlying compositor. | 264 // Sets the visibility of the underlying compositor. |
| 264 void SetVisible(bool visible); | 265 void SetVisible(bool visible); |
| 265 | 266 |
| 266 // Gets the visibility of the underlying compositor. | 267 // Gets the visibility of the underlying compositor. |
| 267 bool IsVisible(); | 268 bool IsVisible(); |
| 268 | 269 |
| 270 // Gets or sets the scroll offset for the given layer in step with the |
| 271 // cc::InputHandler. Returns true if the layer is active on the impl side. |
| 272 bool GetScrollOffsetForLayer(int layer_id, gfx::ScrollOffset* offset) const; |
| 273 bool ScrollLayerTo(int layer_id, const gfx::ScrollOffset& offset); |
| 274 |
| 269 // The "authoritative" vsync interval, if provided, will override interval | 275 // The "authoritative" vsync interval, if provided, will override interval |
| 270 // reported from 3D context. This is typically the value reported by a more | 276 // reported from 3D context. This is typically the value reported by a more |
| 271 // reliable source, e.g, the platform display configuration. | 277 // reliable source, e.g, the platform display configuration. |
| 272 // In the particular case of ChromeOS -- this is the value queried through | 278 // In the particular case of ChromeOS -- this is the value queried through |
| 273 // XRandR, which is more reliable than the value queried through the 3D | 279 // XRandR, which is more reliable than the value queried through the 3D |
| 274 // context. | 280 // context. |
| 275 void SetAuthoritativeVSyncInterval(const base::TimeDelta& interval); | 281 void SetAuthoritativeVSyncInterval(const base::TimeDelta& interval); |
| 276 | 282 |
| 277 // Sets the widget for the compositor to render into. | 283 // Sets the widget for the compositor to render into. |
| 278 void SetAcceleratedWidget(gfx::AcceleratedWidget widget); | 284 void SetAcceleratedWidget(gfx::AcceleratedWidget widget); |
| (...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 407 scoped_refptr<cc::AnimationTimeline> animation_timeline_; | 413 scoped_refptr<cc::AnimationTimeline> animation_timeline_; |
| 408 | 414 |
| 409 base::WeakPtrFactory<Compositor> weak_ptr_factory_; | 415 base::WeakPtrFactory<Compositor> weak_ptr_factory_; |
| 410 | 416 |
| 411 DISALLOW_COPY_AND_ASSIGN(Compositor); | 417 DISALLOW_COPY_AND_ASSIGN(Compositor); |
| 412 }; | 418 }; |
| 413 | 419 |
| 414 } // namespace ui | 420 } // namespace ui |
| 415 | 421 |
| 416 #endif // UI_COMPOSITOR_COMPOSITOR_H_ | 422 #endif // UI_COMPOSITOR_COMPOSITOR_H_ |
| OLD | NEW |