Remove the remaining Skia #ifdefs
authormrobinson@webkit.org <mrobinson@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 26 Apr 2013 16:24:37 +0000 (16:24 +0000)
committermrobinson@webkit.org <mrobinson@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 26 Apr 2013 16:24:37 +0000 (16:24 +0000)
https://bugs.webkit.org/show_bug.cgi?id=114886

Reviewed by Benjamin Poulain.

Source/WebCore:

* html/HTMLCanvasElement.cpp: Remove Skia #ifdef references.
* platform/graphics/BitmapImage.cpp: Ditto.
* platform/graphics/FloatPoint.h: Ditto.
* platform/graphics/FloatRect.h: Ditto.
* platform/graphics/FontCache.h: Ditto.
* platform/graphics/Gradient.cpp: Ditto.
* platform/graphics/Gradient.h: Ditto.
* platform/graphics/GraphicsContext.cpp: Ditto.
* platform/graphics/GraphicsContext.h: Ditto.
* platform/graphics/GraphicsContext3D.h: Ditto.
* platform/graphics/ImageBuffer.cpp: Ditto.
* platform/graphics/ImageBuffer.h: Ditto.
* platform/graphics/ImageBufferData.h: Ditto.
* platform/graphics/IntPoint.h: Ditto.
* platform/graphics/IntRect.h: Ditto.
* platform/graphics/NativeImagePtr.h: Ditto.
* platform/graphics/Path.h: Ditto.
* platform/graphics/Pattern.cpp: Ditto.
* platform/graphics/Pattern.h: Ditto.
* platform/graphics/filters/FEBlend.h: Ditto.
* platform/graphics/filters/FEColorMatrix.h: Ditto.
* platform/graphics/filters/FEComponentTransfer.h: Ditto.
* platform/graphics/filters/FEComposite.h: Ditto.
* platform/graphics/filters/FEConvolveMatrix.h: Ditto.
* platform/graphics/filters/FEDisplacementMap.h: Ditto.
* platform/graphics/filters/FEGaussianBlur.h: Ditto.
* platform/graphics/filters/FELighting.h: Ditto.
* platform/graphics/filters/FEMorphology.h: Ditto.
* platform/graphics/filters/FEOffset.h: Ditto.
* platform/graphics/filters/FilterEffect.cpp: Ditto.
* platform/graphics/filters/FilterEffect.h: Ditto.
* platform/graphics/transforms/AffineTransform.h: Ditto.
* platform/graphics/transforms/TransformationMatrix.h: Ditto.
* platform/image-decoders/ImageDecoder.cpp: Ditto.
* platform/image-decoders/ImageDecoder.h: Ditto.
* platform/image-decoders/jpeg/JPEGImageDecoder.cpp: Ditto.
* platform/image-decoders/webp/WEBPImageDecoder.cpp: Ditto.
* platform/mac/LocalCurrentGraphicsContext.h: Ditto.
* platform/mac/LocalCurrentGraphicsContext.mm: Ditto.
* rendering/svg/RenderSVGResourceSolidColor.cpp: Ditto.
* svg/graphics/SVGImage.cpp: Ditto.
* svg/graphics/SVGImage.h: Ditto.

Source/WebKit/blackberry:

* Api/WebPage.cpp: Remove Skia #ifdef references.
* WebCoreSupport/AboutDataUseFeatures.in: Ditto.

Source/WTF:

* wtf/Platform.h:

Tools:

* DumpRenderTree/blackberry/PixelDumpSupportBlackBerry.cpp:
(createBitmapContextFromWebView): Remove Skia #ifdef references.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@149193 268f45cc-cd09-0410-ab3c-d52691b4dbfc

49 files changed:
Source/WTF/ChangeLog
Source/WTF/wtf/Platform.h
Source/WebCore/ChangeLog
Source/WebCore/html/HTMLCanvasElement.cpp
Source/WebCore/platform/graphics/FloatPoint.h
Source/WebCore/platform/graphics/FloatRect.h
Source/WebCore/platform/graphics/FontCache.h
Source/WebCore/platform/graphics/Gradient.cpp
Source/WebCore/platform/graphics/Gradient.h
Source/WebCore/platform/graphics/GraphicsContext.cpp
Source/WebCore/platform/graphics/GraphicsContext.h
Source/WebCore/platform/graphics/GraphicsContext3D.h
Source/WebCore/platform/graphics/ImageBuffer.cpp
Source/WebCore/platform/graphics/ImageBuffer.h
Source/WebCore/platform/graphics/ImageBufferData.h
Source/WebCore/platform/graphics/IntPoint.h
Source/WebCore/platform/graphics/IntRect.h
Source/WebCore/platform/graphics/NativeImagePtr.h
Source/WebCore/platform/graphics/Path.h
Source/WebCore/platform/graphics/Pattern.cpp
Source/WebCore/platform/graphics/Pattern.h
Source/WebCore/platform/graphics/filters/FEBlend.h
Source/WebCore/platform/graphics/filters/FEColorMatrix.h
Source/WebCore/platform/graphics/filters/FEComponentTransfer.h
Source/WebCore/platform/graphics/filters/FEComposite.h
Source/WebCore/platform/graphics/filters/FEConvolveMatrix.h
Source/WebCore/platform/graphics/filters/FEDisplacementMap.h
Source/WebCore/platform/graphics/filters/FEGaussianBlur.h
Source/WebCore/platform/graphics/filters/FELighting.h
Source/WebCore/platform/graphics/filters/FEMorphology.h
Source/WebCore/platform/graphics/filters/FEOffset.h
Source/WebCore/platform/graphics/filters/FilterEffect.cpp
Source/WebCore/platform/graphics/filters/FilterEffect.h
Source/WebCore/platform/graphics/transforms/AffineTransform.h
Source/WebCore/platform/graphics/transforms/TransformationMatrix.h
Source/WebCore/platform/image-decoders/ImageDecoder.cpp
Source/WebCore/platform/image-decoders/ImageDecoder.h
Source/WebCore/platform/image-decoders/jpeg/JPEGImageDecoder.cpp
Source/WebCore/platform/image-decoders/webp/WEBPImageDecoder.cpp
Source/WebCore/platform/mac/LocalCurrentGraphicsContext.h
Source/WebCore/platform/mac/LocalCurrentGraphicsContext.mm
Source/WebCore/rendering/svg/RenderSVGResourceSolidColor.cpp
Source/WebCore/svg/graphics/SVGImage.cpp
Source/WebCore/svg/graphics/SVGImage.h
Source/WebKit/blackberry/Api/WebPage.cpp
Source/WebKit/blackberry/ChangeLog
Source/WebKit/blackberry/WebCoreSupport/AboutDataUseFeatures.in
Tools/ChangeLog
Tools/DumpRenderTree/blackberry/PixelDumpSupportBlackBerry.cpp

index a5d985f..d1aabdf 100644 (file)
@@ -1,3 +1,12 @@
+2013-04-26  Martin Robinson  <mrobinson@igalia.com>
+
+        Remove the remaining Skia #ifdefs
+        https://bugs.webkit.org/show_bug.cgi?id=114886
+
+        Reviewed by Benjamin Poulain.
+
+        * wtf/Platform.h:
+
 2013-04-26  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
 
         Add move semantics to RefPtr
index fc8d348..c9c2c73 100644 (file)
 #endif
 
 #if PLATFORM(BLACKBERRY)
-#define WTF_USE_SKIA 1
 #define WTF_USE_LOW_QUALITY_IMAGE_INTERPOLATION 1
 #define WTF_USE_LOW_QUALITY_IMAGE_NO_JPEG_DITHERING 1
 #define WTF_USE_LOW_QUALITY_IMAGE_NO_JPEG_FANCY_UPSAMPLING 1
index ab73b96..77d1533 100644 (file)
@@ -1,3 +1,53 @@
+2013-04-26  Martin Robinson  <mrobinson@igalia.com>
+
+        Remove the remaining Skia #ifdefs
+        https://bugs.webkit.org/show_bug.cgi?id=114886
+
+        Reviewed by Benjamin Poulain.
+
+        * html/HTMLCanvasElement.cpp: Remove Skia #ifdef references.
+        * platform/graphics/BitmapImage.cpp: Ditto.
+        * platform/graphics/FloatPoint.h: Ditto.
+        * platform/graphics/FloatRect.h: Ditto.
+        * platform/graphics/FontCache.h: Ditto.
+        * platform/graphics/Gradient.cpp: Ditto.
+        * platform/graphics/Gradient.h: Ditto.
+        * platform/graphics/GraphicsContext.cpp: Ditto.
+        * platform/graphics/GraphicsContext.h: Ditto.
+        * platform/graphics/GraphicsContext3D.h: Ditto.
+        * platform/graphics/ImageBuffer.cpp: Ditto.
+        * platform/graphics/ImageBuffer.h: Ditto.
+        * platform/graphics/ImageBufferData.h: Ditto.
+        * platform/graphics/IntPoint.h: Ditto.
+        * platform/graphics/IntRect.h: Ditto.
+        * platform/graphics/NativeImagePtr.h: Ditto.
+        * platform/graphics/Path.h: Ditto.
+        * platform/graphics/Pattern.cpp: Ditto.
+        * platform/graphics/Pattern.h: Ditto.
+        * platform/graphics/filters/FEBlend.h: Ditto.
+        * platform/graphics/filters/FEColorMatrix.h: Ditto.
+        * platform/graphics/filters/FEComponentTransfer.h: Ditto.
+        * platform/graphics/filters/FEComposite.h: Ditto.
+        * platform/graphics/filters/FEConvolveMatrix.h: Ditto.
+        * platform/graphics/filters/FEDisplacementMap.h: Ditto.
+        * platform/graphics/filters/FEGaussianBlur.h: Ditto.
+        * platform/graphics/filters/FELighting.h: Ditto.
+        * platform/graphics/filters/FEMorphology.h: Ditto.
+        * platform/graphics/filters/FEOffset.h: Ditto.
+        * platform/graphics/filters/FilterEffect.cpp: Ditto.
+        * platform/graphics/filters/FilterEffect.h: Ditto.
+        * platform/graphics/transforms/AffineTransform.h: Ditto.
+        * platform/graphics/transforms/TransformationMatrix.h: Ditto.
+        * platform/image-decoders/ImageDecoder.cpp: Ditto.
+        * platform/image-decoders/ImageDecoder.h: Ditto.
+        * platform/image-decoders/jpeg/JPEGImageDecoder.cpp: Ditto.
+        * platform/image-decoders/webp/WEBPImageDecoder.cpp: Ditto.
+        * platform/mac/LocalCurrentGraphicsContext.h: Ditto.
+        * platform/mac/LocalCurrentGraphicsContext.mm: Ditto.
+        * rendering/svg/RenderSVGResourceSolidColor.cpp: Ditto.
+        * svg/graphics/SVGImage.cpp: Ditto.
+        * svg/graphics/SVGImage.h: Ditto.
+
 2013-04-26  Allan Sandfeld Jensen  <allan.jensen@digia.com>
 
         Assert in JSC::Heap::unprotect when closing facebook.com web site
index ebf7b11..70dd724 100644 (file)
@@ -418,7 +418,7 @@ String HTMLCanvasElement::toDataURL(const String& mimeType, const double* qualit
 
     String encodingMimeType = toEncodingMimeType(mimeType);
 
-#if USE(CG) || USE(SKIA)
+#if USE(CG)
     // Try to get ImageData first, as that may avoid lossy conversions.
     RefPtr<ImageData> imageData = getImageData();
 
@@ -524,21 +524,12 @@ void HTMLCanvasElement::createImageBuffer() const
 
     if (deviceSize.width() * deviceSize.height() > MaxCanvasArea)
         return;
-#if USE(SKIA)
-    if (deviceSize.width() > MaxSkiaDim || deviceSize.height() > MaxSkiaDim)
-        return;
-#endif
 
     IntSize bufferSize(deviceSize.width(), deviceSize.height());
     if (!bufferSize.width() || !bufferSize.height())
         return;
 
-    RenderingMode renderingMode = shouldAccelerate(bufferSize) ? Accelerated : 
-#if USE(SKIA)
-        UnacceleratedNonPlatformBuffer;
-#else
-        Unaccelerated;
-#endif
+    RenderingMode renderingMode = shouldAccelerate(bufferSize) ? Accelerated : Unaccelerated;
     m_imageBuffer = ImageBuffer::create(size(), m_deviceScaleFactor, ColorSpaceDeviceRGB, renderingMode);
     if (!m_imageBuffer)
         return;
index 17d4eba..7b40166 100644 (file)
@@ -58,10 +58,6 @@ class QPointF;
 QT_END_NAMESPACE
 #endif
 
-#if USE(SKIA)
-struct SkPoint;
-#endif
-
 namespace WebCore {
 
 class AffineTransform;
@@ -170,11 +166,6 @@ public:
     operator BlackBerry::Platform::FloatPoint() const;
 #endif
 
-#if USE(SKIA)
-    operator SkPoint() const;
-    FloatPoint(const SkPoint&);
-#endif
-
     FloatPoint matrixTransform(const TransformationMatrix&) const;
     FloatPoint matrixTransform(const AffineTransform&) const;
 
index 798d8c9..6ef33e2 100644 (file)
@@ -56,10 +56,6 @@ class FloatRect;
 }
 #endif
 
-#if USE(SKIA)
-struct SkRect;
-#endif
-
 #if USE(CAIRO)
 typedef struct _cairo_rectangle cairo_rectangle_t;
 #endif
@@ -203,11 +199,6 @@ public:
     FloatRect normalized() const;
 #endif
 
-#if USE(SKIA)
-    FloatRect(const SkRect&);
-    operator SkRect() const;
-#endif
-
 #if USE(CAIRO)
     FloatRect(const cairo_rectangle_t&);
     operator cairo_rectangle_t() const;
index 454cef2..050666d 100644 (file)
@@ -110,11 +110,7 @@ public:
 #endif
 
 #if ENABLE(OPENTYPE_VERTICAL)
-#if USE(SKIA)
-    typedef uint32_t FontFileKey;
-#else
     typedef AtomicString FontFileKey;
-#endif
     PassRefPtr<OpenTypeVerticalData> getVerticalData(const FontFileKey&, const FontPlatformData&);
 #endif
 
index e103684..7e7638b 100644 (file)
@@ -240,7 +240,7 @@ void Gradient::setGradientSpaceTransform(const AffineTransform& gradientSpaceTra
     invalidateHash();
 }
 
-#if !USE(SKIA) && !USE(CAIRO) && !PLATFORM(BLACKBERRY)
+#if !USE(CAIRO) && !PLATFORM(BLACKBERRY)
 void Gradient::setPlatformGradientSpaceTransform(const AffineTransform&)
 {
 }
index bd86ac5..03f8e66 100644 (file)
@@ -50,10 +50,6 @@ typedef QGradient* PlatformGradient;
 #elif USE(CAIRO)
 typedef struct _cairo_pattern cairo_pattern_t;
 typedef cairo_pattern_t* PlatformGradient;
-#elif USE(SKIA)
-class SkShader;
-typedef class SkShader* PlatformGradient;
-typedef class SkShader* PlatformPattern;
 #elif PLATFORM(BLACKBERRY)
 namespace BlackBerry {
 namespace Platform {
index a37e230..154ac62 100644 (file)
@@ -606,7 +606,6 @@ void GraphicsContext::clip(const IntRect& rect)
 }
 #endif
 
-#if !USE(SKIA)
 void GraphicsContext::clipRoundedRect(const RoundedRect& rect)
 {
     if (paintingDisabled())
@@ -621,7 +620,6 @@ void GraphicsContext::clipRoundedRect(const RoundedRect& rect)
     path.addRoundedRect(rect);
     clip(path);
 }
-#endif
 
 void GraphicsContext::clipOutRoundedRect(const RoundedRect& rect)
 {
@@ -740,7 +738,7 @@ BlendMode GraphicsContext::blendModeOperation() const
     return m_state.blendMode;
 }
 
-#if !USE(CG) && !USE(SKIA)
+#if !USE(CG)
 // Implement this if you want to go ahead and push the drawing mode into your native context
 // immediately.
 void GraphicsContext::setPlatformTextDrawingMode(TextDrawingModeFlags)
@@ -748,7 +746,7 @@ void GraphicsContext::setPlatformTextDrawingMode(TextDrawingModeFlags)
 }
 #endif
 
-#if !PLATFORM(QT) && !USE(CAIRO) && !USE(SKIA)
+#if !PLATFORM(QT) && !USE(CAIRO)
 void GraphicsContext::setPlatformStrokeStyle(StrokeStyle)
 {
 }
@@ -760,7 +758,7 @@ void GraphicsContext::setPlatformShouldSmoothFonts(bool)
 }
 #endif
 
-#if !USE(SKIA) && !USE(CG) && !USE(CAIRO)
+#if !USE(CG) && !USE(CAIRO)
 bool GraphicsContext::isAcceleratedContext() const
 {
     return false;
@@ -863,7 +861,7 @@ void GraphicsContext::strokeEllipseAsPath(const FloatRect& ellipse)
     strokePath(path);
 }
 
-#if !USE(CG) && !USE(SKIA) // append && !USE(MYPLATFORM) here to optimize ellipses on your platform.
+#if !USE(CG)
 void GraphicsContext::platformFillEllipse(const FloatRect& ellipse)
 {
     if (paintingDisabled())
index 8c6b07e..56f7645 100644 (file)
@@ -49,12 +49,6 @@ typedef WebCore::PlatformContextCairo PlatformGraphicsContext;
 #elif PLATFORM(QT)
 #include <QPainter>
 typedef QPainter PlatformGraphicsContext;
-#elif USE(SKIA)
-namespace WebCore {
-class PlatformContextSkia;
-typedef PlatformContextSkia GraphicsContextPlatformPrivate;
-}
-typedef WebCore::PlatformContextSkia PlatformGraphicsContext;
 #elif OS(WINCE)
 typedef struct HDC__ PlatformGraphicsContext;
 #else
@@ -89,9 +83,7 @@ namespace WebCore {
     class AffineTransform;
     class DrawingBuffer;
     class Generator;
-#if !USE(SKIA)
     class GraphicsContextPlatformPrivate;
-#endif
     class ImageBuffer;
     class IntRect;
     class RoundedRect;
index 6a04498..005623b 100644 (file)
@@ -80,10 +80,6 @@ typedef void* PlatformGraphicsContext3D;
 typedef void* PlatformGraphicsSurface3D;
 #endif
 
-#if PLATFORM(BLACKBERRY) && USE(SKIA)
-class GrContext;
-#endif
-
 // These are currently the same among all implementations.
 const PlatformGraphicsContext3D NullPlatformGraphicsContext3D = 0;
 const Platform3DObject NullPlatform3DObject = 0;
@@ -495,9 +491,6 @@ public:
 #elif PLATFORM(BLACKBERRY)
     PlatformGraphicsContext3D platformGraphicsContext3D() const;
     Platform3DObject platformTexture() const;
-#if USE(SKIA)
-    GrContext* grContext();
-#endif
 #if USE(ACCELERATED_COMPOSITING)
     PlatformLayer* platformLayer() const;
 #endif
@@ -919,10 +912,7 @@ public:
         // needs to lock the resources or relevant data if needed and returns true upon success
         bool extractImage(bool premultiplyAlpha, bool ignoreGammaAndColorProfile);
 
-#if USE(SKIA)
-        RefPtr<NativeImageSkia> m_nativeImage;
-        RefPtr<NativeImageSkia> m_skiaImage;
-#elif USE(CAIRO)
+#if USE(CAIRO)
         ImageSource* m_decoder;
         RefPtr<cairo_surface_t> m_imageSurface;
 #elif USE(CG)
index 348abed..6cf7cca 100644 (file)
@@ -98,14 +98,13 @@ void ImageBuffer::convertToLuminanceMask()
     genericConvertToLuminanceMask();
 }
 
-#if USE(ACCELERATED_COMPOSITING) && !USE(SKIA) && !USE(CAIRO) && !PLATFORM(BLACKBERRY)
+#if USE(ACCELERATED_COMPOSITING) && !USE(CAIRO) && !PLATFORM(BLACKBERRY)
 PlatformLayer* ImageBuffer::platformLayer() const
 {
     return 0;
 }
 #endif
 
-#if !USE(SKIA)
 bool ImageBuffer::copyToPlatformTexture(GraphicsContext3D&, Platform3DObject, GC3Denum, bool, bool)
 {
     return false;
@@ -115,6 +114,5 @@ PassOwnPtr<ImageBuffer> ImageBuffer::createCompatibleBuffer(const IntSize& size,
 {
     return create(size, resolutionScale, colorSpace, context->isAcceleratedContext() ? Accelerated : Unaccelerated);
 }
-#endif
 
 }
index d8c0d5a..a7386ae 100644 (file)
@@ -154,12 +154,9 @@ namespace WebCore {
         // This constructor will place its success into the given out-variable
         // so that create() knows when it should return failure.
         ImageBuffer(const IntSize&, float resolutionScale, ColorSpace, RenderingMode, bool& success);
-#if USE(SKIA)
-        ImageBuffer(const IntSize&, float resolutionScale, ColorSpace, const GraphicsContext*, bool hasAlpha, bool& success);
-#endif
     };
 
-#if USE(CG) || USE(SKIA)
+#if USE(CG)
     String ImageDataToDataURL(const ImageData&, const String& mimeType, const double* quality);
 #endif
 
index 15a17e8..286d7f3 100644 (file)
@@ -29,8 +29,6 @@
 #include "ImageBufferDataCairo.h"
 #elif PLATFORM(QT)
 #include "ImageBufferDataQt.h"
-#elif USE(SKIA)
-#include "ImageBufferDataSkia.h"
 #elif OS(WINCE)
 #include "ImageBufferDataWince.h"
 #endif
index e26eee0..619734e 100644 (file)
@@ -61,11 +61,6 @@ class IntPoint;
 typedef struct _Evas_Point Evas_Point;
 #endif
 
-#if USE(SKIA)
-struct SkPoint;
-struct SkIPoint;
-#endif
-
 namespace WebCore {
 
 class IntPoint {
@@ -144,12 +139,6 @@ public:
     operator Evas_Point() const;
 #endif
 
-#if USE(SKIA)
-    IntPoint(const SkIPoint&);
-    operator SkIPoint() const;
-    operator SkPoint() const;
-#endif
-
 private:
     int m_x, m_y;
 };
index dc16a28..f718939 100644 (file)
@@ -65,11 +65,6 @@ class IntRect;
 typedef struct _cairo_rectangle_int cairo_rectangle_int_t;
 #endif
 
-#if USE(SKIA)
-struct SkRect;
-struct SkIRect;
-#endif
-
 namespace WebCore {
 
 class FloatRect;
@@ -215,12 +210,6 @@ public:
     operator CGRect() const;
 #endif
 
-#if USE(SKIA)
-    IntRect(const SkIRect&);
-    operator SkRect() const;
-    operator SkIRect() const;
-#endif
-
 #if (PLATFORM(MAC) && !defined(NSGEOMETRY_TYPES_SAME_AS_CGGEOMETRY_TYPES)) || (PLATFORM(QT) && USE(QTKIT))
     operator NSRect() const;
 #endif
index 47f1d46..a8b0f74 100644 (file)
@@ -38,11 +38,6 @@ class QPixmap;
 QT_END_NAMESPACE
 #elif USE(CAIRO)
 #include "RefPtrCairo.h"
-#elif USE(SKIA)
-#include "NativeImageSkia.h"
-namespace WebCore {
-class NativeImageSkia;
-}
 #elif OS(WINCE)
 #include "SharedBitmap.h"
 #endif
@@ -58,16 +53,13 @@ typedef QPixmap* NativeImagePtr;
 #elif USE(CAIRO)
 typedef RefPtr<cairo_surface_t> NativeImagePtr;
 typedef PassRefPtr<cairo_surface_t> PassNativeImagePtr;
-#elif USE(SKIA)
-typedef RefPtr<NativeImageSkia> NativeImagePtr;
-typedef PassRefPtr<NativeImageSkia> PassNativeImagePtr;
 #elif OS(WINCE)
 typedef RefPtr<SharedBitmap> NativeImagePtr;
 #elif PLATFORM(BLACKBERRY)
 typedef void* NativeImagePtr;
 #endif
 
-#if !USE(SKIA) && !USE(CAIRO)
+#if !USE(CAIRO)
 typedef NativeImagePtr PassNativeImagePtr;
 #endif
 
index d455f0f..4734519 100644 (file)
@@ -42,9 +42,6 @@ namespace WebCore {
 class CairoPath;
 }
 typedef WebCore::CairoPath PlatformPath;
-#elif USE(SKIA)
-class SkPath;
-typedef SkPath PlatformPath;
 #elif OS(WINCE)
 namespace WebCore {
     class PlatformPath;
index 8d94d1f..3b32ebb 100644 (file)
@@ -40,10 +40,6 @@ Pattern::Pattern(PassRefPtr<Image> image, bool repeatX, bool repeatY)
     : m_tileImage(image)
     , m_repeatX(repeatX)
     , m_repeatY(repeatY)
-#if USE(SKIA)
-    , m_pattern(0)
-    , m_externalMemoryAllocated(0)
-#endif
 {
     ASSERT(m_tileImage);
 }
@@ -59,7 +55,6 @@ void Pattern::setPatternSpaceTransform(const AffineTransform& patternSpaceTransf
     setPlatformPatternSpaceTransform();
 }
 
-#if !USE(SKIA)
 void Pattern::platformDestroy()
 {
 }
@@ -67,6 +62,5 @@ void Pattern::platformDestroy()
 void Pattern::setPlatformPatternSpaceTransform()
 {
 }
-#endif
 
 }
index d8e2f6b..18b72e5 100644 (file)
@@ -40,9 +40,6 @@ typedef CGPatternRef PlatformPatternPtr;
 #elif USE(CAIRO)
 #include <cairo.h>
 typedef cairo_pattern_t* PlatformPatternPtr;
-#elif USE(SKIA)
-class SkShader;
-typedef SkShader* PlatformPatternPtr;
 #elif PLATFORM(QT)
 #include <QBrush>
 typedef QBrush PlatformPatternPtr;
@@ -65,9 +62,7 @@ public:
     void platformDestroy();
 
     // Pattern space is an abstract space that maps to the default user space by the transformation 'userSpaceTransformation' 
-#if USE(SKIA)
-    PlatformPatternPtr platformPattern(const AffineTransform& userSpaceTransformation);
-#elif PLATFORM(QT)
+#if PLATFORM(QT)
     // Qt ignores user space transformation and uses pattern's instead
     PlatformPatternPtr createPlatformPattern() const;
 #else
@@ -88,9 +83,6 @@ private:
     bool m_repeatY;
     AffineTransform m_patternSpaceTransformation;
     PlatformPatternPtr m_pattern;
-#if USE(SKIA)
-    int m_externalMemoryAllocated;
-#endif
 };
 
 } //namespace
index 5c71c2b..6b00080 100644 (file)
@@ -49,11 +49,6 @@ public:
                            unsigned colorArrayLength);
     void platformApplyNEON(unsigned char* srcPixelArrayA, unsigned char* srcPixelArrayB, unsigned char* dstPixelArray,
                            unsigned colorArrayLength);
-#if USE(SKIA)
-    virtual bool platformApplySkia();
-    virtual SkImageFilter* createImageFilter(SkiaImageFilterBuilder*);
-#endif
-
     virtual void platformApplySoftware();
     virtual void dump();
 
index 76b26c8..98905c5 100644 (file)
@@ -49,10 +49,6 @@ public:
     bool setValues(const Vector<float>&);
 
     virtual void platformApplySoftware();
-#if USE(SKIA)
-    virtual bool platformApplySkia();
-    virtual SkImageFilter* createImageFilter(SkiaImageFilterBuilder*);
-#endif
 #if ENABLE(OPENCL)
     virtual bool platformApplyOpenCL();
 #endif
index 68454fd..cf6b747 100644 (file)
@@ -79,10 +79,6 @@ public:
     void setAlphaFunction(const ComponentTransferFunction&);
 
     virtual void platformApplySoftware();
-#if USE(SKIA)
-    virtual bool platformApplySkia();
-    virtual SkImageFilter* createImageFilter(SkiaImageFilterBuilder*);
-#endif
     virtual void dump();
 
     virtual TextStream& externalRepresentation(TextStream&, int indention) const;
index 3eb9b86..df0426a 100644 (file)
@@ -68,10 +68,6 @@ public:
 
     virtual TextStream& externalRepresentation(TextStream&, int indention) const;
 
-#if USE(SKIA)
-    virtual SkImageFilter* createImageFilter(SkiaImageFilterBuilder*);
-#endif
-
 protected:
     virtual bool requiresValidPreMultipliedPixels() OVERRIDE { return m_type != FECOMPOSITE_OPERATOR_ARITHMETIC; }
 
index 91060a7..81eba1d 100644 (file)
@@ -71,9 +71,6 @@ public:
     bool setPreserveAlpha(bool);
 
     virtual void platformApplySoftware();
-#if USE(SKIA)
-    virtual SkImageFilter* createImageFilter(SkiaImageFilterBuilder*);
-#endif
     virtual void dump();
 
     virtual void determineAbsolutePaintRect() { setAbsolutePaintRect(enclosingIntRect(maxEffectRect())); }
index 815bcf8..1b4170e 100644 (file)
@@ -63,11 +63,6 @@ public:
 private:
     FEDisplacementMap(Filter*, ChannelSelectorType xChannelSelector, ChannelSelectorType yChannelSelector, float);
 
-#if USE(SKIA)
-    virtual bool platformApplySkia();
-    virtual SkImageFilter* createImageFilter(SkiaImageFilterBuilder*);
-#endif
-
     ChannelSelectorType m_xChannelSelector;
     ChannelSelectorType m_yChannelSelector;
     float m_scale;
index daf3ef1..f554ef8 100644 (file)
@@ -73,10 +73,6 @@ private:
     inline void platformApply(Uint8ClampedArray* srcPixelArray, Uint8ClampedArray* tmpPixelArray, unsigned kernelSizeX, unsigned kernelSizeY, IntSize& paintSize);
 
     inline void platformApplyGeneric(Uint8ClampedArray* srcPixelArray, Uint8ClampedArray* tmpPixelArray, unsigned kernelSizeX, unsigned kernelSizeY, IntSize& paintSize);
-#if USE(SKIA)
-    virtual bool platformApplySkia();
-    virtual SkImageFilter* createImageFilter(SkiaImageFilterBuilder*);
-#endif
 
     float m_stdX;
     float m_stdY;
index 448f02d..b40bb13 100644 (file)
@@ -45,10 +45,6 @@ struct FELightingPaintingDataForNeon;
 class FELighting : public FilterEffect {
 public:
     virtual void platformApplySoftware();
-#if USE(SKIA)
-    virtual SkImageFilter* createImageFilter(SkiaImageFilterBuilder*);
-    virtual bool platformApplySkia();
-#endif
 
     virtual void determineAbsolutePaintRect() { setAbsolutePaintRect(enclosingIntRect(maxEffectRect())); }
 
index b38e673..04a77f5 100644 (file)
@@ -47,11 +47,6 @@ public:
     bool setRadiusY(float);
 
     virtual void platformApplySoftware();
-#if USE(SKIA)
-    virtual bool platformApplySkia();
-    virtual SkImageFilter* createImageFilter(SkiaImageFilterBuilder*);
-
-#endif
     virtual void dump();
 
     virtual void determineAbsolutePaintRect();
index c2a4fa5..e75febd 100644 (file)
@@ -45,10 +45,6 @@ public:
 
     virtual TextStream& externalRepresentation(TextStream&, int indention) const;
 
-#if USE(SKIA)
-    virtual SkImageFilter* createImageFilter(SkiaImageFilterBuilder*);
-#endif
-
 private:
     FEOffset(Filter*, float dx, float dy);
 
index f78dd1f..5dd065d 100644 (file)
@@ -146,10 +146,6 @@ void FilterEffect::apply()
     if (platformApplyOpenCL())
         return;
 #endif
-#if USE(SKIA)
-    if (platformApplySkia())
-        return;
-#endif
     platformApplySoftware();
 }
 
index a7ea579..296461f 100644 (file)
 
 static const float kMaxFilterSize = 5000.0f;
 
-#if USE(SKIA)
-class SkImageFilter;
-#endif
-
 namespace WebCore {
 
 class Filter;
@@ -50,10 +46,6 @@ class FilterEffect;
 class ImageBuffer;
 class TextStream;
 
-#if USE(SKIA)
-class SkiaImageFilterBuilder;
-#endif
-
 typedef Vector<RefPtr<FilterEffect> > FilterEffectVector;
 
 enum FilterEffectType {
@@ -126,10 +118,6 @@ public:
 #if ENABLE(OPENCL)
     virtual bool platformApplyOpenCL();
 #endif
-#if USE(SKIA)
-    virtual bool platformApplySkia() { return false; }
-    virtual SkImageFilter* createImageFilter(SkiaImageFilterBuilder*) { return 0; }
-#endif
     virtual void dump() = 0;
 
     virtual void determineAbsolutePaintRect();
index 07df726..d8f323b 100644 (file)
@@ -36,8 +36,6 @@ typedef struct CGAffineTransform CGAffineTransform;
 #include <cairo.h>
 #elif PLATFORM(QT)
 #include <QTransform>
-#elif USE(SKIA)
-#include <SkMatrix.h>
 #endif
 
 namespace WebCore {
@@ -172,8 +170,6 @@ public:
     operator cairo_matrix_t() const;
 #elif PLATFORM(QT)
     operator QTransform() const;
-#elif USE(SKIA)
-    operator SkMatrix() const;
 #endif
 
     static AffineTransform translation(double x, double y)
index 4f5a68a..037c01e 100644 (file)
@@ -45,8 +45,6 @@ typedef struct CGAffineTransform CGAffineTransform;
 #elif PLATFORM(QT)
 #include <QMatrix4x4>
 #include <QTransform>
-#elif USE(SKIA)
-#include <SkMatrix.h>
 #endif
 
 #if PLATFORM(WIN) || (PLATFORM(GTK) && OS(WINDOWS)) || (PLATFORM(QT) && OS(WINDOWS))
@@ -348,8 +346,6 @@ public:
 #elif PLATFORM(QT)
     operator QTransform() const;
     operator QMatrix4x4() const;
-#elif USE(SKIA)
-    operator SkMatrix() const;
 #endif
 
 #if PLATFORM(WIN) || (PLATFORM(GTK) && OS(WINDOWS)) || (PLATFORM(QT) && OS(WINDOWS))
index 7c42f1b..b9d3cb5 100644 (file)
@@ -138,8 +138,6 @@ ImageDecoder* ImageDecoder::create(const SharedBuffer& data, ImageSource::AlphaO
     return 0;
 }
 
-#if !USE(SKIA)
-
 ImageFrame::ImageFrame()
     : m_hasAlpha(false)
     , m_status(FrameEmpty)
@@ -226,8 +224,6 @@ void ImageFrame::setStatus(FrameStatus status)
     m_status = status;
 }
 
-#endif
-
 namespace {
 
 enum MatchType {
index ab61df9..a32f8c9 100644 (file)
 #include <wtf/Vector.h>
 #include <wtf/text/WTFString.h>
 
-#if USE(SKIA)
-#include "NativeImageSkia.h"
-#include "SkColorPriv.h"
-#endif
-
 #if USE(QCMSLIB)
 #include "qcms.h"
 #if OS(DARWIN)
@@ -69,11 +64,7 @@ namespace WebCore {
             DisposeOverwritePrevious  // Clear frame to previous framebuffer
                                       // contents
         };
-#if USE(SKIA)
-        typedef uint32_t PixelData;
-#else
         typedef unsigned PixelData;
-#endif
 
         ImageFrame();
 
@@ -139,11 +130,7 @@ namespace WebCore {
 
         inline PixelData* getAddr(int x, int y)
         {
-#if USE(SKIA)
-            return m_bitmap->bitmap().getAddr32(x, y);
-#else
             return m_bytes + (y * width()) + x;
-#endif
         }
 
         // Use fix point multiplier instead of integer division or floating point math.
@@ -169,44 +156,25 @@ namespace WebCore {
                 g = fixPointUnsignedMultiply(g, alphaMult);
                 b = fixPointUnsignedMultiply(b, alphaMult);
             }
-#if USE(SKIA)
-            // Call the "NoCheck" version since we may deliberately pass non-premultiplied
-            // values, and we don't want an assert.
-            *dest = SkPackARGB32NoCheck(a, r, g, b);
-#else
             *dest = (a << 24 | r << 16 | g << 8 | b);
-#endif
         }
 
     private:
         int width() const
         {
-#if USE(SKIA)
-            return m_bitmap->bitmap().width();
-#else
             return m_size.width();
-#endif
         }
 
         int height() const
         {
-#if USE(SKIA)
-            return m_bitmap->bitmap().height();
-#else
             return m_size.height();
-#endif
         }
 
-#if USE(SKIA)
-        RefPtr<NativeImageSkia> m_bitmap;
-        SkBitmap::Allocator* m_allocator;
-#else
         Vector<PixelData> m_backingStore;
         PixelData* m_bytes; // The memory is backed by m_backingStore.
         IntSize m_size;
         // FIXME: Do we need m_colorProfile anymore?
         ColorProfile m_colorProfile;
-#endif
         bool m_hasAlpha;
         IntRect m_originalFrameRect; // This will always just be the entire
                                      // buffer except for GIF frames whose
@@ -392,32 +360,6 @@ namespace WebCore {
         // and returns true. Otherwise returns false.
         virtual bool hotSpot(IntPoint&) const { return false; }
 
-#if USE(SKIA)
-        virtual void setMemoryAllocator(SkBitmap::Allocator* allocator)
-        {
-            // FIXME: this doesn't work for images with multiple frames.
-            if (m_frameBufferCache.isEmpty())
-                m_frameBufferCache.resize(1);
-            m_frameBufferCache[0].setMemoryAllocator(allocator);
-        }
-
-        virtual bool lockFrameBuffers()
-        {
-            bool ret = true;
-            for (unsigned i = 0; i < m_frameBufferCache.size(); ++i) {
-                const SkBitmap& bitmap = m_frameBufferCache[i].getSkBitmap();
-                bitmap.lockPixels();
-                ret = ret && bitmap.getPixels();
-            }
-            return ret;
-        }
-
-        virtual void unlockFrameBuffers()
-        {
-            for (unsigned i = 0; i < m_frameBufferCache.size(); ++i)
-                m_frameBufferCache[i].getSkBitmap().unlockPixels();
-        }
-#endif
     protected:
         void prepareScaleDataIfNecessary();
         int upperBoundScaledX(int origX, int searchStart = 0);
index a9772fc..d15dce2 100644 (file)
@@ -60,11 +60,7 @@ extern "C" {
 
 #if defined(JCS_ALPHA_EXTENSIONS) && ASSUME_LITTLE_ENDIAN
 #define TURBO_JPEG_RGB_SWIZZLE
-#if USE(SKIA) && (!SK_R32_SHIFT && SK_G32_SHIFT == 8 && SK_B32_SHIFT == 16)
-inline J_COLOR_SPACE rgbOutputColorSpace() { return JCS_EXT_RGBA; }
-#else
 inline J_COLOR_SPACE rgbOutputColorSpace() { return JCS_EXT_BGRA; }
-#endif
 inline bool turboSwizzled(J_COLOR_SPACE colorSpace) { return colorSpace == JCS_EXT_RGBA || colorSpace == JCS_EXT_BGRA; }
 inline bool colorSpaceHasAlpha(J_COLOR_SPACE colorSpace) { return turboSwizzled(colorSpace); }
 #else
index ce85863..d00eb5d 100644 (file)
@@ -49,8 +49,6 @@
 
 #if CPU(BIG_ENDIAN) || CPU(MIDDLE_ENDIAN)
 inline WEBP_CSP_MODE outputMode(bool hasAlpha) { return hasAlpha ? MODE_rgbA : MODE_RGBA; }
-#elif USE(SKIA) && SK_B32_SHIFT
-inline WEBP_CSP_MODE outputMode(bool hasAlpha) { return hasAlpha ? MODE_rgbA : MODE_RGBA; }
 #else // LITTLE_ENDIAN, output BGRA pixels.
 inline WEBP_CSP_MODE outputMode(bool hasAlpha) { return hasAlpha ? MODE_bgrA : MODE_BGRA; }
 #endif
index 824f2ff..06676c8 100644 (file)
 #include "GraphicsContext.h"
 #include <wtf/Noncopyable.h>
 
-#if USE(SKIA)
-#include "skia/ext/skia_utils_mac.h"
-#endif
-
 OBJC_CLASS NSGraphicsContext;
 
 namespace WebCore {
@@ -40,34 +36,19 @@ private:
     GraphicsContext* m_savedGraphicsContext;
     NSGraphicsContext* m_savedNSGraphicsContext;
     bool m_didSetGraphicsContext;
-#if USE(SKIA)
-    gfx::SkiaBitLocker m_skiaBitLocker;
-#endif
 };
 
 class ContextContainer {
     WTF_MAKE_NONCOPYABLE(ContextContainer);
 public:
-#if USE(SKIA)
-    ContextContainer(GraphicsContext*);
-    
-    // This synchronizes the CGContext to reflect the current SkCanvas state.
-    // The implementation may not return the same CGContext each time.
-    CGContextRef context() { return m_skiaBitLocker.cgContext(); }
-#else
     ContextContainer(GraphicsContext* graphicsContext)
         : m_graphicsContext(graphicsContext->platformContext())
     {
     }
 
     CGContextRef context() { return m_graphicsContext; }
-#endif
 private:
-#if USE(SKIA)
-    gfx::SkiaBitLocker m_skiaBitLocker;
-#else
     PlatformGraphicsContext* m_graphicsContext;
-#endif
 };
 
 }
index f033df3..7d2f6ff 100644 (file)
 
 #include <AppKit/NSGraphicsContext.h>
 
-#if USE(SKIA)
-#include "platform_canvas.h"
-#include "PlatformContextSkia.h"
-#endif
-
 namespace WebCore {
 
 LocalCurrentGraphicsContext::LocalCurrentGraphicsContext(GraphicsContext* graphicsContext)
     : m_didSetGraphicsContext(false)
-#if USE(SKIA)
-    , m_skiaBitLocker(graphicsContext->platformContext()->canvas())
-#endif
 {
     m_savedGraphicsContext = graphicsContext;
     graphicsContext->save();
@@ -62,21 +54,8 @@ LocalCurrentGraphicsContext::~LocalCurrentGraphicsContext()
 
 CGContextRef LocalCurrentGraphicsContext::cgContext()
 {
-#if USE(SKIA)
-    // This synchronizes the CGContext to reflect the current SkCanvas state.
-    // The implementation may not return the same CGContext each time.
-    CGContextRef cgContext = m_skiaBitLocker.cgContext();
-#else
     CGContextRef cgContext = m_savedGraphicsContext->platformContext();
-#endif
     return cgContext;
 }
 
-#if USE(SKIA)
-ContextContainer::ContextContainer(GraphicsContext* graphicsContext) 
-    : m_skiaBitLocker(graphicsContext->platformContext()->canvas())
-{
-}
-#endif
-
 }
index a81c369..ca5cad4 100644 (file)
 #include "RenderStyle.h"
 #include "SVGRenderSupport.h"
 
-#if USE(SKIA)
-#include "PlatformContextSkia.h"
-#endif
-
 namespace WebCore {
 
 RenderSVGResourceType RenderSVGResourceSolidColor::s_resourceType = SolidColorResourceType;
index 9f6acc7..d5b8d37 100644 (file)
@@ -142,7 +142,7 @@ void SVGImage::drawForContainer(GraphicsContext* context, const FloatSize contai
     setImageObserver(observer);
 }
 
-#if USE(SKIA) || USE(CAIRO)
+#if USE(CAIRO)
 // Passes ownership of the native image to the caller so PassNativeImagePtr needs
 // to be a smart pointer type.
 PassNativeImagePtr SVGImage::nativeImageForCurrentFrame()
index 143f0a6..660a37b 100644 (file)
@@ -60,7 +60,7 @@ public:
     virtual void stopAnimation() OVERRIDE;
     virtual void resetAnimation() OVERRIDE;
 
-#if USE(SKIA) || USE(CAIRO)
+#if USE(CAIRO)
     virtual PassNativeImagePtr nativeImageForCurrentFrame() OVERRIDE;
 #endif
 
index d647802..f590b1f 100644 (file)
 #include "MediaPlayerPrivateBlackBerry.h"
 #endif
 
-#if USE(SKIA)
-#include "PlatformContextSkia.h"
-#endif
-
 #if USE(ACCELERATED_COMPOSITING)
 #include "FrameLayers.h"
 #include "WebPageCompositorClient.h"
index 9efb9c9..3758886 100644 (file)
@@ -1,3 +1,13 @@
+2013-04-26  Martin Robinson  <mrobinson@igalia.com>
+
+        Remove the remaining Skia #ifdefs
+        https://bugs.webkit.org/show_bug.cgi?id=114886
+
+        Reviewed by Benjamin Poulain.
+
+        * Api/WebPage.cpp: Remove Skia #ifdef references.
+        * WebCoreSupport/AboutDataUseFeatures.in: Ditto.
+
 2013-04-26  Mary Wu  <mary.wu@torchmobile.com.cn>
 
         [BlackBerry] Should check if it's cached resource before download
index d5ee1ab..13f9b59 100644 (file)
@@ -90,9 +90,6 @@ RTL_SCROLLBAR
 SAFARI_THEME
 SCROLLBAR_PAINTER
 SECURITY_FRAMEWORK
-SKIA
-SKIA_ON_MAC_CHROMIUM
-SKIA_TEXT
 SOUP
 STORAGE_STRATEGIES
 TEXMAP_OPENGL_ES_2
index 01871b9..d050926 100644 (file)
@@ -1,3 +1,13 @@
+2013-04-26  Martin Robinson  <mrobinson@igalia.com>
+
+        Remove the remaining Skia #ifdefs
+        https://bugs.webkit.org/show_bug.cgi?id=114886
+
+        Reviewed by Benjamin Poulain.
+
+        * DumpRenderTree/blackberry/PixelDumpSupportBlackBerry.cpp:
+        (createBitmapContextFromWebView): Remove Skia #ifdef references.
+
 2013-04-26  Mary Wu  <mary.wu@torchmobile.com.cn>
 
         [BlackBerry] Clean up load interface in WebPage
index 37d95ff..82b448d 100644 (file)
@@ -32,9 +32,6 @@
 #include "WebPageClient.h"
 
 #include <BlackBerryPlatformWindow.h>
-#if USE(SKIA)
-#include <SkDevice.h>
-#endif
 #include <wtf/MD5.h>
 #include <wtf/Vector.h>
 
@@ -62,30 +59,6 @@ PassRefPtr<BitmapContext> createBitmapContextFromWebView(bool /*onscreen*/, bool
     const Platform::IntSize& windowSize = window->viewportSize();
     unsigned char* data = new unsigned char[windowSize.width() * windowSize.height() * 4];
 
-#if USE(SKIA)
-    // We need to force a synchronous update to the window or we may get an empty bitmap.
-    // For example, running DRT with one test case that finishes before the screen is updated.
-    window->post(windowRect);
-
-    SkBitmap bitmap;
-    bitmap.setConfig(SkBitmap::kARGB_8888_Config, windowSize.width(), windowSize.height());
-    bitmap.allocPixels();
-    bitmap.eraseARGB(0, 0, 0, 0);
-
-    SkCanvas canvas(bitmap);
-    backingStore->drawContents(&canvas, windowRect, windowSize);
-
-    // Read that SkBitmap rather than change it. So use false on accessBitmap.
-    const SkBitmap& contentsBitmap = canvas.getDevice()->accessBitmap(false/*changePixels*/);
-    contentsBitmap.lockPixels();
-
-    const unsigned char* windowPixels = 0;
-    if (!contentsBitmap.empty()) {
-        windowPixels = static_cast<const unsigned char*>(contentsBitmap.getPixels());
-        if (windowPixels)
-            memcpy(data, windowPixels, windowSize.width() * windowSize.height() * 4);
-    }
-#else
     BlackBerry::Platform::Graphics::Buffer* buffer = BlackBerry::Platform::Graphics::createBuffer(windowSize, BlackBerry::Platform::Graphics::AlwaysBacked);
     BlackBerry::Platform::Graphics::Drawable* drawable = BlackBerry::Platform::Graphics::lockBufferDrawable(buffer);
     if (drawable) {
@@ -95,7 +68,6 @@ PassRefPtr<BitmapContext> createBitmapContextFromWebView(bool /*onscreen*/, bool
         BlackBerry::Platform::Graphics::releaseBufferDrawable(buffer);
     }
     BlackBerry::Platform::Graphics::destroyBuffer(buffer);
-#endif
     return BitmapContext::createByAdoptingData(data, windowSize.width(), windowSize.height());
 }