diff options
author | Michael Meeks <michael.meeks@collabora.com> | 2015-03-20 18:58:34 +0000 |
---|---|---|
committer | Michael Meeks <michael.meeks@collabora.com> | 2015-04-10 13:01:49 +0100 |
commit | ad8a2074c6143d3ce05c0a5d93a553c13b950520 (patch) | |
tree | 2f47189a78e80d478a15a3360906131fc9c16428 /vcl/source/gdi/gdimtf.cxx | |
parent | 8fb4672aef888fc5a582ca9508799ecdbe777c42 (diff) |
cure a lot of unfortunate ScopedVclPtrs.
Change-Id: I2149511f958ba75e81dc41b10b01eb9d19610037
Diffstat (limited to 'vcl/source/gdi/gdimtf.cxx')
-rw-r--r-- | vcl/source/gdi/gdimtf.cxx | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/vcl/source/gdi/gdimtf.cxx b/vcl/source/gdi/gdimtf.cxx index 9772a570387d..0720b7f91a29 100644 --- a/vcl/source/gdi/gdimtf.cxx +++ b/vcl/source/gdi/gdimtf.cxx @@ -723,7 +723,7 @@ void GDIMetaFile::Move( long nX, long nY ) { const Size aBaseOffset( nX, nY ); Size aOffset( aBaseOffset ); - ScopedVclPtr<VirtualDevice> aMapVDev = new VirtualDevice; + ScopedVclPtr<VirtualDevice> aMapVDev( new VirtualDevice() ); aMapVDev->EnableOutput( false ); aMapVDev->SetMapMode( GetPrefMapMode() ); @@ -757,7 +757,7 @@ void GDIMetaFile::Move( long nX, long nY, long nDPIX, long nDPIY ) { const Size aBaseOffset( nX, nY ); Size aOffset( aBaseOffset ); - ScopedVclPtr<VirtualDevice> aMapVDev = new VirtualDevice; + ScopedVclPtr<VirtualDevice> aMapVDev( new VirtualDevice() ); aMapVDev->EnableOutput( false ); aMapVDev->SetReferenceDevice( nDPIX, nDPIY ); @@ -825,7 +825,7 @@ void GDIMetaFile::Scale( const Fraction& rScaleX, const Fraction& rScaleY ) void GDIMetaFile::Clip( const Rectangle& i_rClipRect ) { Rectangle aCurRect( i_rClipRect ); - ScopedVclPtr<VirtualDevice> aMapVDev = new VirtualDevice; + ScopedVclPtr<VirtualDevice> aMapVDev( new VirtualDevice() ); aMapVDev->EnableOutput( false ); aMapVDev->SetMapMode( GetPrefMapMode() ); @@ -892,7 +892,7 @@ void GDIMetaFile::ImplAddGradientEx( GDIMetaFile& rMtf, const Gradient& rGrad ) { // Generate comment, GradientEx and Gradient actions (within DrawGradient) - ScopedVclPtr<VirtualDevice> aVDev = new VirtualDevice( rMapDev, 0 ); + ScopedVclPtr<VirtualDevice> aVDev( new VirtualDevice( rMapDev, 0 ) ); aVDev->EnableOutput( false ); GDIMetaFile aGradMtf; @@ -917,7 +917,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) if( nAngle10 ) { GDIMetaFile aMtf; - ScopedVclPtr<VirtualDevice> aMapVDev = new VirtualDevice; + ScopedVclPtr<VirtualDevice> aMapVDev( new VirtualDevice() ); const double fAngle = F_PI1800 * nAngle10; const double fSin = sin( fAngle ); const double fCos = cos( fAngle ); @@ -1400,7 +1400,7 @@ static void ImplActionBounds( Rectangle& o_rOutBounds, Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, Rectangle* pHairline ) const { GDIMetaFile aMtf; - ScopedVclPtr<VirtualDevice> aMapVDev = new VirtualDevice( i_rReference ); + ScopedVclPtr<VirtualDevice> aMapVDev( new VirtualDevice( i_rReference ) ); aMapVDev->EnableOutput( false ); aMapVDev->SetMapMode( GetPrefMapMode() ); @@ -2890,7 +2890,7 @@ SvStream& GDIMetaFile::Write( SvStream& rOStm ) bool GDIMetaFile::CreateThumbnail(BitmapEx& rBitmapEx, sal_uInt32 nMaximumExtent, BmpConversion eColorConversion, long nScaleFlag) const { // initialization seems to be complicated but is used to avoid rounding errors - ScopedVclPtr<VirtualDevice> aVDev = new VirtualDevice; + ScopedVclPtr<VirtualDevice> aVDev( new VirtualDevice() ); const Point aNullPt; const Point aTLPix( aVDev->LogicToPixel( aNullPt, GetPrefMapMode() ) ); const Point aBRPix( aVDev->LogicToPixel( Point( GetPrefSize().Width() - 1, GetPrefSize().Height() - 1 ), GetPrefMapMode() ) ); |