summaryrefslogtreecommitdiff
path: root/Source/WebKit/chromium/src/WebLayerTreeViewImpl.h
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@nokia.com>2012-09-10 19:10:20 +0200
committerSimon Hausmann <simon.hausmann@nokia.com>2012-09-10 19:10:20 +0200
commit284837daa07b29d6a63a748544a90b1f5842ac5c (patch)
treeecd258180bde91fe741e0cfd2638beb3c6da7e8e /Source/WebKit/chromium/src/WebLayerTreeViewImpl.h
parent2e2ba8ff45915f40ed3e014101269c175f2a89a0 (diff)
downloadqtwebkit-284837daa07b29d6a63a748544a90b1f5842ac5c.tar.gz
Imported WebKit commit 68645295d2e3e09af2c942f092556f06aa5f8b0d (http://svn.webkit.org/repository/webkit/trunk@128073)
New snapshot
Diffstat (limited to 'Source/WebKit/chromium/src/WebLayerTreeViewImpl.h')
-rw-r--r--Source/WebKit/chromium/src/WebLayerTreeViewImpl.h51
1 files changed, 45 insertions, 6 deletions
diff --git a/Source/WebKit/chromium/src/WebLayerTreeViewImpl.h b/Source/WebKit/chromium/src/WebLayerTreeViewImpl.h
index 3bc43410d..a1dbd7404 100644
--- a/Source/WebKit/chromium/src/WebLayerTreeViewImpl.h
+++ b/Source/WebKit/chromium/src/WebLayerTreeViewImpl.h
@@ -26,6 +26,7 @@
#ifndef WebLayerTreeViewImpl_h
#define WebLayerTreeViewImpl_h
+#include "CCLayerTreeHostClient.h"
#include <public/WebLayerTreeView.h>
#include <wtf/OwnPtr.h>
#include <wtf/PassOwnPtr.h>
@@ -39,17 +40,55 @@ class WebLayer;
class WebLayerTreeViewClient;
class WebLayerTreeViewClientAdapter;
-class WebLayerTreeViewImpl {
+class WebLayerTreeViewImpl : public WebLayerTreeView, public WebCore::CCLayerTreeHostClient {
public:
- static PassOwnPtr<WebLayerTreeViewImpl> create(WebLayerTreeViewClient*, const WebLayer& root, const WebLayerTreeView::Settings&);
+ explicit WebLayerTreeViewImpl(WebLayerTreeViewClient*);
virtual ~WebLayerTreeViewImpl();
- WebCore::CCLayerTreeHost* layerTreeHost() { return m_layerTreeHost.get(); }
+ bool initialize(const Settings&);
-private:
- WebLayerTreeViewImpl(WebLayerTreeViewClient*, const WebLayerTreeView::Settings&);
+ // WebLayerTreeView implementation.
+ virtual void setSurfaceReady() OVERRIDE;
+ virtual void setRootLayer(const WebLayer&) OVERRIDE;
+ virtual void clearRootLayer() OVERRIDE;
+ virtual void setViewportSize(const WebSize& layoutViewportSize, const WebSize& deviceViewportSize = WebSize()) OVERRIDE;
+ virtual WebSize layoutViewportSize() const OVERRIDE;
+ virtual WebSize deviceViewportSize() const OVERRIDE;
+ virtual void setDeviceScaleFactor(float) OVERRIDE;
+ virtual float deviceScaleFactor() const OVERRIDE;
+ virtual void setBackgroundColor(WebColor) OVERRIDE;
+ virtual void setHasTransparentBackground(bool) OVERRIDE;
+ virtual void setVisible(bool) OVERRIDE;
+ virtual void setPageScaleFactorAndLimits(float pageScaleFactor, float minimum, float maximum) OVERRIDE;
+ virtual void startPageScaleAnimation(const WebPoint& destination, bool useAnchor, float newPageScale, double durationSec) OVERRIDE;
+ virtual void setNeedsAnimate() OVERRIDE;
+ virtual void setNeedsRedraw() OVERRIDE;
+ virtual bool commitRequested() const OVERRIDE;
+ virtual void composite() OVERRIDE;
+ virtual void updateAnimations(double frameBeginTime) OVERRIDE;
+ virtual bool compositeAndReadback(void *pixels, const WebRect&) OVERRIDE;
+ virtual void finishAllRendering() OVERRIDE;
+ virtual void renderingStats(WebRenderingStats&) const OVERRIDE;
+ virtual void setFontAtlas(SkBitmap, WebRect asciiToRectTable[128], int fontHeight) OVERRIDE;
+ virtual void loseCompositorContext(int numTimes) OVERRIDE;
+
+ // WebCore::CCLayerTreeHostClient implementation.
+ virtual void willBeginFrame() OVERRIDE;
+ virtual void didBeginFrame() OVERRIDE;
+ virtual void animate(double monotonicFrameBeginTime) OVERRIDE;
+ virtual void layout() OVERRIDE;
+ virtual void applyScrollAndScale(const WebCore::IntSize& scrollDelta, float pageScale) OVERRIDE;
+ virtual PassOwnPtr<WebCompositorOutputSurface> createOutputSurface() OVERRIDE;
+ virtual void didRecreateOutputSurface(bool success) OVERRIDE;
+ virtual PassOwnPtr<WebCore::CCInputHandler> createInputHandler() OVERRIDE;
+ virtual void willCommit() OVERRIDE;
+ virtual void didCommit() OVERRIDE;
+ virtual void didCommitAndDrawFrame() OVERRIDE;
+ virtual void didCompleteSwapBuffers() OVERRIDE;
+ virtual void scheduleComposite() OVERRIDE;
- OwnPtr<WebLayerTreeViewClientAdapter> m_clientAdapter;
+private:
+ WebLayerTreeViewClient* m_client;
OwnPtr<WebCore::CCLayerTreeHost> m_layerTreeHost;
};