summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--vcl/qt5/Qt5SvpGraphics.cxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/vcl/qt5/Qt5SvpGraphics.cxx b/vcl/qt5/Qt5SvpGraphics.cxx
index 4edf55d55644..fc58bbcfcc15 100644
--- a/vcl/qt5/Qt5SvpGraphics.cxx
+++ b/vcl/qt5/Qt5SvpGraphics.cxx
@@ -81,12 +81,12 @@ void Qt5SvpGraphics::handleDamage(const tools::Rectangle& rDamagedRegion)
QImage* pImage = static_cast<Qt5Graphics_Controls*>(m_pWidgetDraw.get())->getImage();
assert(pImage);
- BitmapBuffer* pBuffer = new BitmapBuffer;
- QImage2BitmapBuffer(*pImage, *pBuffer);
+ BitmapBuffer aBuffer;
+ QImage2BitmapBuffer(*pImage, aBuffer);
SalTwoRect aTR(0, 0, pImage->width(), pImage->height(), rDamagedRegion.getX(),
rDamagedRegion.getY(), rDamagedRegion.GetWidth(), rDamagedRegion.GetHeight());
- drawBitmap(aTR, pBuffer, CAIRO_OPERATOR_OVER);
+ drawBitmap(aTR, &aBuffer, CAIRO_OPERATOR_OVER);
}
void Qt5SvpGraphics::GetResolution(sal_Int32& rDPIX, sal_Int32& rDPIY)