| 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_SINGLE_THREAD_PROXY_H_ | 5 #ifndef CC_SINGLE_THREAD_PROXY_H_ |
| 6 #define CC_SINGLE_THREAD_PROXY_H_ | 6 #define CC_SINGLE_THREAD_PROXY_H_ |
| 7 | 7 |
| 8 #include <limits> | 8 #include <limits> |
| 9 | 9 |
| 10 #include "base/time.h" | 10 #include "base/time.h" |
| 11 #include "cc/animation_events.h" | 11 #include "cc/animation_events.h" |
| 12 #include "cc/layer_tree_host_impl.h" | 12 #include "cc/layer_tree_host_impl.h" |
| 13 #include "cc/proxy.h" | 13 #include "cc/proxy.h" |
| 14 | 14 |
| 15 namespace cc { | 15 namespace cc { |
| 16 | 16 |
| 17 class LayerTreeHost; | 17 class LayerTreeHost; |
| 18 | 18 |
| 19 class SingleThreadProxy : public Proxy, LayerTreeHostImplClient { | 19 class SingleThreadProxy : public Proxy, LayerTreeHostImplClient { |
| 20 public: | 20 public: |
| 21 static scoped_ptr<Proxy> create(LayerTreeHost*); | 21 static scoped_ptr<Proxy> create(LayerTreeHost*); |
| 22 virtual ~SingleThreadProxy(); | 22 virtual ~SingleThreadProxy(); |
| 23 | 23 |
| 24 // Proxy implementation | 24 // Proxy implementation |
| 25 virtual bool compositeAndReadback(void *pixels, const gfx::Rect&) OVERRIDE; | 25 virtual bool compositeAndReadback(void *pixels, const gfx::Rect&) OVERRIDE; |
| 26 virtual void startPageScaleAnimation(const IntSize& targetPosition, bool use
Anchor, float scale, base::TimeDelta duration) OVERRIDE; | 26 virtual void startPageScaleAnimation(gfx::Vector2d targetOffset, bool useAnc
hor, float scale, base::TimeDelta duration) OVERRIDE; |
| 27 virtual void finishAllRendering() OVERRIDE; | 27 virtual void finishAllRendering() OVERRIDE; |
| 28 virtual bool isStarted() const OVERRIDE; | 28 virtual bool isStarted() const OVERRIDE; |
| 29 virtual bool initializeContext() OVERRIDE; | 29 virtual bool initializeContext() OVERRIDE; |
| 30 virtual void setSurfaceReady() OVERRIDE; | 30 virtual void setSurfaceReady() OVERRIDE; |
| 31 virtual void setVisible(bool) OVERRIDE; | 31 virtual void setVisible(bool) OVERRIDE; |
| 32 virtual bool initializeRenderer() OVERRIDE; | 32 virtual bool initializeRenderer() OVERRIDE; |
| 33 virtual bool recreateContext() OVERRIDE; | 33 virtual bool recreateContext() OVERRIDE; |
| 34 virtual void renderingStats(RenderingStats*) OVERRIDE; | 34 virtual void renderingStats(RenderingStats*) OVERRIDE; |
| 35 virtual const RendererCapabilities& rendererCapabilities() const OVERRIDE; | 35 virtual const RendererCapabilities& rendererCapabilities() const OVERRIDE; |
| 36 virtual void loseContext() OVERRIDE; | 36 virtual void loseContext() OVERRIDE; |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 128 // satisfy assertion checks | 128 // satisfy assertion checks |
| 129 class DebugScopedSetImplThreadAndMainThreadBlocked { | 129 class DebugScopedSetImplThreadAndMainThreadBlocked { |
| 130 private: | 130 private: |
| 131 DebugScopedSetImplThread m_implThread; | 131 DebugScopedSetImplThread m_implThread; |
| 132 DebugScopedSetMainThreadBlocked m_mainThreadBlocked; | 132 DebugScopedSetMainThreadBlocked m_mainThreadBlocked; |
| 133 }; | 133 }; |
| 134 | 134 |
| 135 } // namespace cc | 135 } // namespace cc |
| 136 | 136 |
| 137 #endif // CC_SINGLE_THREAD_PROXY_H_ | 137 #endif // CC_SINGLE_THREAD_PROXY_H_ |
| OLD | NEW |