diff options
Diffstat (limited to 'Source/WebCore/platform/graphics/qt/GraphicsContextQt.cpp')
-rw-r--r-- | Source/WebCore/platform/graphics/qt/GraphicsContextQt.cpp | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/Source/WebCore/platform/graphics/qt/GraphicsContextQt.cpp b/Source/WebCore/platform/graphics/qt/GraphicsContextQt.cpp index d1ab885d9..00bcb8532 100644 --- a/Source/WebCore/platform/graphics/qt/GraphicsContextQt.cpp +++ b/Source/WebCore/platform/graphics/qt/GraphicsContextQt.cpp @@ -49,6 +49,7 @@ #include "FloatConversion.h" #include "Font.h" #include "ImageBuffer.h" +#include "ImageBufferDataQt.h" #include "NotImplemented.h" #include "Path.h" #include "Pattern.h" @@ -959,15 +960,8 @@ void GraphicsContext::clipToImageBuffer(ImageBuffer& buffer, const FloatRect& de if (paintingDisabled()) return; - RefPtr<Image> image = buffer.copyImage(DontCopyBackingStore); - QPixmap* nativeImage = image->nativeImageForCurrentFrame(); - if (!nativeImage) - return; - IntRect rect = enclosingIntRect(destRect); - QPixmap alphaMask = *nativeImage; - - pushTransparencyLayerInternal(rect, 1.0, alphaMask); + buffer.m_data.m_impl->clip(*this, rect); } void drawFocusRingForPath(QPainter* p, const QPainterPath& path, const Color& color, bool antiAliasing) @@ -1553,7 +1547,7 @@ void GraphicsContext::setCTM(const AffineTransform& transform) m_data->p()->setWorldTransform(transform); } -#if ENABLE(3D_RENDERING) +#if ENABLE(3D_TRANSFORMS) TransformationMatrix GraphicsContext::get3DTransform() const { if (paintingDisabled()) @@ -1757,6 +1751,10 @@ void GraphicsContext::takeOwnershipOfPlatformContext() m_data->takeOwnershipOfPlatformContext(); } +bool GraphicsContext::isAcceleratedContext() const +{ + return (platformContext()->paintEngine()->type() == QPaintEngine::OpenGL2); } +} // vim: ts=4 sw=4 et |