| 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 WebLayerTreeViewImpl_h | 5 #ifndef WebLayerTreeViewImpl_h |
| 6 #define WebLayerTreeViewImpl_h | 6 #define WebLayerTreeViewImpl_h |
| 7 | 7 |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "cc/layer_tree_host_client.h" | 9 #include "cc/layer_tree_host_client.h" |
| 10 #include "third_party/WebKit/Source/Platform/chromium/public/WebLayerTreeView.h" | 10 #include "third_party/WebKit/Source/Platform/chromium/public/WebLayerTreeView.h" |
| 11 | 11 |
| 12 namespace cc { | 12 namespace cc { |
| 13 class CCLayerTreeHost; | 13 class CCLayerTreeHost; |
| 14 class CompositorSupportState; |
| 14 } | 15 } |
| 15 | 16 |
| 16 namespace WebKit { | 17 namespace WebKit { |
| 17 class WebLayer; | 18 class WebLayer; |
| 18 class WebLayerTreeViewClient; | 19 class WebLayerTreeViewClient; |
| 19 class WebLayerTreeViewClientAdapter; | 20 class WebLayerTreeViewClientAdapter; |
| 20 | 21 |
| 21 class WebLayerTreeViewImpl : public WebLayerTreeView, public cc::CCLayerTreeHost
Client { | 22 class WebLayerTreeViewImpl : public WebLayerTreeView, public cc::CCLayerTreeHost
Client { |
| 22 public: | 23 public: |
| 23 explicit WebLayerTreeViewImpl(WebLayerTreeViewClient*); | 24 explicit WebLayerTreeViewImpl(WebLayerTreeViewClient*); |
| 24 virtual ~WebLayerTreeViewImpl(); | 25 virtual ~WebLayerTreeViewImpl(); |
| 25 | 26 |
| 26 bool initialize(const Settings&); | 27 bool initialize(const Settings&, CompositorSupportState*); |
| 27 | 28 |
| 28 // WebLayerTreeView implementation. | 29 // WebLayerTreeView implementation. |
| 29 virtual void setSurfaceReady() OVERRIDE; | 30 virtual void setSurfaceReady() OVERRIDE; |
| 30 virtual void setRootLayer(const WebLayer&) OVERRIDE; | 31 virtual void setRootLayer(const WebLayer&) OVERRIDE; |
| 31 virtual void clearRootLayer() OVERRIDE; | 32 virtual void clearRootLayer() OVERRIDE; |
| 32 virtual void setViewportSize(const WebSize& layoutViewportSize, const WebSiz
e& deviceViewportSize = WebSize()) OVERRIDE; | 33 virtual void setViewportSize(const WebSize& layoutViewportSize, const WebSiz
e& deviceViewportSize = WebSize()) OVERRIDE; |
| 33 virtual WebSize layoutViewportSize() const OVERRIDE; | 34 virtual WebSize layoutViewportSize() const OVERRIDE; |
| 34 virtual WebSize deviceViewportSize() const OVERRIDE; | 35 virtual WebSize deviceViewportSize() const OVERRIDE; |
| 35 virtual void setDeviceScaleFactor(float) OVERRIDE; | 36 virtual void setDeviceScaleFactor(float) OVERRIDE; |
| 36 virtual float deviceScaleFactor() const OVERRIDE; | 37 virtual float deviceScaleFactor() const OVERRIDE; |
| (...skipping 29 matching lines...) Expand all Loading... |
| 66 virtual void scheduleComposite() OVERRIDE; | 67 virtual void scheduleComposite() OVERRIDE; |
| 67 | 68 |
| 68 private: | 69 private: |
| 69 WebLayerTreeViewClient* m_client; | 70 WebLayerTreeViewClient* m_client; |
| 70 scoped_ptr<cc::CCLayerTreeHost> m_layerTreeHost; | 71 scoped_ptr<cc::CCLayerTreeHost> m_layerTreeHost; |
| 71 }; | 72 }; |
| 72 | 73 |
| 73 } // namespace WebKit | 74 } // namespace WebKit |
| 74 | 75 |
| 75 #endif // WebLayerTreeViewImpl_h | 76 #endif // WebLayerTreeViewImpl_h |
| OLD | NEW |