| Index: Source/platform/graphics/GraphicsLayer.h
|
| diff --git a/Source/platform/graphics/GraphicsLayer.h b/Source/platform/graphics/GraphicsLayer.h
|
| index bcf2c948cf5ccb03a0d031ed02732cfed55e7425..d97dc4d0340df798a88945afc1cfd9e6b6fe899a 100644
|
| --- a/Source/platform/graphics/GraphicsLayer.h
|
| +++ b/Source/platform/graphics/GraphicsLayer.h
|
| @@ -38,7 +38,7 @@
|
| #include "platform/graphics/OpaqueRectTrackingContentLayerDelegate.h"
|
| #include "platform/graphics/filters/FilterOperations.h"
|
| #include "platform/transforms/TransformationMatrix.h"
|
| -#include "public/platform/WebCompositorAnimationDelegate.h"
|
| +#include "public/platform/WebAnimationDelegate.h"
|
| #include "public/platform/WebContentLayer.h"
|
| #include "public/platform/WebImageLayer.h"
|
| #include "public/platform/WebLayerClient.h"
|
| @@ -50,7 +50,7 @@
|
|
|
| namespace blink {
|
| class GraphicsLayerFactoryChromium;
|
| -class WebCompositorAnimation;
|
| +class WebAnimation;
|
| class WebLayer;
|
| }
|
|
|
| @@ -70,7 +70,7 @@
|
| public:
|
| virtual void invalidate() = 0;
|
| virtual void clearCurrentGraphicsLayer() = 0;
|
| - virtual WebLayer* layer() = 0;
|
| + virtual blink::WebLayer* layer() = 0;
|
|
|
| protected:
|
| virtual ~LinkHighlightClient() { }
|
| @@ -81,7 +81,7 @@
|
| // GraphicsLayer is an abstraction for a rendering surface with backing store,
|
| // which may have associated transformation and animations.
|
|
|
| -class PLATFORM_EXPORT GraphicsLayer : public GraphicsContextPainter, public WebCompositorAnimationDelegate, public WebLayerScrollClient, public WebLayerClient {
|
| +class PLATFORM_EXPORT GraphicsLayer : public GraphicsContextPainter, public blink::WebAnimationDelegate, public blink::WebLayerScrollClient, public blink::WebLayerClient {
|
| WTF_MAKE_NONCOPYABLE(GraphicsLayer); WTF_MAKE_FAST_ALLOCATED;
|
| public:
|
| static PassOwnPtr<GraphicsLayer> create(GraphicsLayerFactory*, GraphicsLayerClient*);
|
| @@ -90,8 +90,8 @@
|
|
|
| GraphicsLayerClient* client() const { return m_client; }
|
|
|
| - // WebLayerClient implementation.
|
| - virtual WebGraphicsLayerDebugInfo* takeDebugInfoFor(WebLayer*) OVERRIDE;
|
| + // blink::WebLayerClient implementation.
|
| + virtual blink::WebGraphicsLayerDebugInfo* takeDebugInfoFor(blink::WebLayer*) OVERRIDE;
|
|
|
| GraphicsLayerDebugInfo& debugInfo();
|
|
|
| @@ -158,8 +158,8 @@
|
| bool contentsAreVisible() const { return m_contentsVisible; }
|
| void setContentsVisible(bool);
|
|
|
| - void setScrollParent(WebLayer*);
|
| - void setClipParent(WebLayer*);
|
| + void setScrollParent(blink::WebLayer*);
|
| + void setClipParent(blink::WebLayer*);
|
|
|
| // For special cases, e.g. drawing missing tiles on Android.
|
| // The compositor should never paint this color in normal cases because the RenderLayer
|
| @@ -176,7 +176,7 @@
|
| float opacity() const { return m_opacity; }
|
| void setOpacity(float);
|
|
|
| - void setBlendMode(WebBlendMode);
|
| + void setBlendMode(blink::WebBlendMode);
|
| void setIsRootForIsolatedGroup(bool);
|
|
|
| void setFilters(const FilterOperations&);
|
| @@ -196,18 +196,18 @@
|
| // Return true if the animation is handled by the compositing system. If this returns
|
| // false, the animation will be run by AnimationController.
|
| // These methods handle both transitions and keyframe animations.
|
| - bool addAnimation(PassOwnPtr<WebCompositorAnimation>);
|
| + bool addAnimation(PassOwnPtr<blink::WebAnimation>);
|
| void pauseAnimation(int animationId, double /*timeOffset*/);
|
| void removeAnimation(int animationId);
|
|
|
| // Layer contents
|
| void setContentsToImage(Image*);
|
| void setContentsToNinePatch(Image*, const IntRect& aperture);
|
| - void setContentsToPlatformLayer(WebLayer* layer) { setContentsTo(layer); }
|
| + void setContentsToPlatformLayer(blink::WebLayer* layer) { setContentsTo(layer); }
|
| bool hasContentsLayer() const { return m_contentsLayer; }
|
|
|
| // For hosting this GraphicsLayer in a native layer hierarchy.
|
| - WebLayer* platformLayer() const;
|
| + blink::WebLayer* platformLayer() const;
|
|
|
| typedef HashMap<int, int> RenderingContextMap;
|
| PassRefPtr<JSONObject> layerTreeAsJSON(LayerTreeFlags, RenderingContextMap&) const;
|
| @@ -230,30 +230,30 @@
|
| void setScrollableArea(ScrollableArea*, bool isMainFrame);
|
| ScrollableArea* scrollableArea() const { return m_scrollableArea; }
|
|
|
| - WebContentLayer* contentLayer() const { return m_layer.get(); }
|
| -
|
| - static void registerContentsLayer(WebLayer*);
|
| - static void unregisterContentsLayer(WebLayer*);
|
| + blink::WebContentLayer* contentLayer() const { return m_layer.get(); }
|
| +
|
| + static void registerContentsLayer(blink::WebLayer*);
|
| + static void unregisterContentsLayer(blink::WebLayer*);
|
|
|
| // GraphicsContextPainter implementation.
|
| virtual void paint(GraphicsContext&, const IntRect& clip) OVERRIDE;
|
|
|
| - // WebCompositorAnimationDelegate implementation.
|
| - virtual void notifyAnimationStarted(double monotonicTime, WebCompositorAnimation::TargetProperty) OVERRIDE;
|
| - virtual void notifyAnimationFinished(double monotonicTime, WebCompositorAnimation::TargetProperty) OVERRIDE;
|
| + // WebAnimationDelegate implementation.
|
| + virtual void notifyAnimationStarted(double monotonicTime, blink::WebAnimation::TargetProperty) OVERRIDE;
|
| + virtual void notifyAnimationFinished(double monotonicTime, blink::WebAnimation::TargetProperty) OVERRIDE;
|
|
|
| // WebLayerScrollClient implementation.
|
| virtual void didScroll() OVERRIDE;
|
|
|
| protected:
|
| - String debugName(WebLayer*) const;
|
| + String debugName(blink::WebLayer*) const;
|
|
|
| explicit GraphicsLayer(GraphicsLayerClient*);
|
| // GraphicsLayerFactoryChromium that wants to create a GraphicsLayer need to be friends.
|
| - friend class GraphicsLayerFactoryChromium;
|
| + friend class blink::GraphicsLayerFactoryChromium;
|
|
|
| // Exposed for tests.
|
| - virtual WebLayer* contentsLayer() const { return m_contentsLayer; }
|
| + virtual blink::WebLayer* contentsLayer() const { return m_contentsLayer; }
|
|
|
| private:
|
| // Callback from the underlying graphics system to draw layer contents.
|
| @@ -276,10 +276,10 @@
|
| void updateLayerIsDrawable();
|
| void updateContentsRect();
|
|
|
| - void setContentsTo(WebLayer*);
|
| - void setupContentsLayer(WebLayer*);
|
| + void setContentsTo(blink::WebLayer*);
|
| + void setupContentsLayer(blink::WebLayer*);
|
| void clearContentsLayerIfUnregistered();
|
| - WebLayer* contentsLayerIfRegistered();
|
| + blink::WebLayer* contentsLayerIfRegistered();
|
|
|
| GraphicsLayerClient* m_client;
|
|
|
| @@ -296,7 +296,7 @@
|
| Color m_backgroundColor;
|
| float m_opacity;
|
|
|
| - WebBlendMode m_blendMode;
|
| + blink::WebBlendMode m_blendMode;
|
|
|
| bool m_hasTransformOrigin : 1;
|
| bool m_contentsOpaque : 1;
|
| @@ -327,10 +327,10 @@
|
|
|
| int m_paintCount;
|
|
|
| - OwnPtr<WebContentLayer> m_layer;
|
| - OwnPtr<WebImageLayer> m_imageLayer;
|
| - OwnPtr<WebNinePatchLayer> m_ninePatchLayer;
|
| - WebLayer* m_contentsLayer;
|
| + OwnPtr<blink::WebContentLayer> m_layer;
|
| + OwnPtr<blink::WebImageLayer> m_imageLayer;
|
| + OwnPtr<blink::WebNinePatchLayer> m_ninePatchLayer;
|
| + blink::WebLayer* m_contentsLayer;
|
| // We don't have ownership of m_contentsLayer, but we do want to know if a given layer is the
|
| // same as our current layer in setContentsTo(). Since m_contentsLayer may be deleted at this point,
|
| // we stash an ID away when we know m_contentsLayer is alive and use that for comparisons from that point
|
|
|