summaryrefslogtreecommitdiffstats
path: root/WebCore/platform/graphics/qt/PathQt.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'WebCore/platform/graphics/qt/PathQt.cpp')
-rw-r--r--WebCore/platform/graphics/qt/PathQt.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/WebCore/platform/graphics/qt/PathQt.cpp b/WebCore/platform/graphics/qt/PathQt.cpp
index a8adb31..de9de07 100644
--- a/WebCore/platform/graphics/qt/PathQt.cpp
+++ b/WebCore/platform/graphics/qt/PathQt.cpp
@@ -123,8 +123,10 @@ bool Path::contains(const FloatPoint& point, WindRule rule) const
static GraphicsContext* scratchContext()
{
- static ImageBuffer* scratch = ImageBuffer::create(IntSize(1, 1)).leakPtr();
- return scratch->context();
+ static QImage image(1, 1, QImage::Format_ARGB32_Premultiplied);
+ static QPainter painter(&image);
+ static GraphicsContext* context = new GraphicsContext(&painter);
+ return context;
}
bool Path::strokeContains(StrokeStyleApplier* applier, const FloatPoint& point) const