summaryrefslogtreecommitdiff
path: root/canvas/source
diff options
context:
space:
mode:
Diffstat (limited to 'canvas/source')
-rw-r--r--canvas/source/vcl/cachedbitmap.cxx8
-rw-r--r--canvas/source/vcl/cachedbitmap.hxx5
-rw-r--r--canvas/source/vcl/canvas.cxx2
-rw-r--r--canvas/source/vcl/canvas.hxx2
-rw-r--r--canvas/source/vcl/canvasbitmap.cxx2
-rw-r--r--canvas/source/vcl/canvasbitmap.hxx2
-rw-r--r--canvas/source/vcl/canvascustomsprite.cxx2
-rw-r--r--canvas/source/vcl/canvascustomsprite.hxx2
-rw-r--r--canvas/source/vcl/canvashelper.cxx19
-rw-r--r--canvas/source/vcl/canvashelper.hxx2
-rw-r--r--canvas/source/vcl/canvashelper_texturefill.cxx20
-rw-r--r--canvas/source/vcl/repainttarget.hxx2
-rw-r--r--canvas/source/vcl/spritecanvas.cxx2
-rw-r--r--canvas/source/vcl/spritecanvas.hxx2
14 files changed, 36 insertions, 36 deletions
diff --git a/canvas/source/vcl/cachedbitmap.cxx b/canvas/source/vcl/cachedbitmap.cxx
index bdbbcab79996..c3941c2bae24 100644
--- a/canvas/source/vcl/cachedbitmap.cxx
+++ b/canvas/source/vcl/cachedbitmap.cxx
@@ -35,7 +35,7 @@ using namespace ::com::sun::star;
namespace vclcanvas
{
- CachedBitmap::CachedBitmap( const GraphicObjectSharedPtr& rGraphicObject,
+ CachedBitmap::CachedBitmap( const rtl::Reference<GraphicObject>& rGraphicObject,
const ::Point& rPoint,
const ::Size& rSize,
const GraphicAttr& rAttr,
@@ -43,7 +43,7 @@ namespace vclcanvas
const rendering::RenderState& rUsedRenderState,
const uno::Reference< rendering::XCanvas >& rTarget ) :
CachedPrimitiveBase( rUsedViewState, rTarget, true ),
- mpGraphicObject( rGraphicObject ),
+ m_rGraphicObject( rGraphicObject ),
maRenderState(rUsedRenderState),
maPoint( rPoint ),
maSize( rSize ),
@@ -55,7 +55,7 @@ namespace vclcanvas
{
::osl::MutexGuard aGuard( m_aMutex );
- mpGraphicObject.reset();
+ m_rGraphicObject = rtl::Reference<GraphicObject>();
CachedPrimitiveBase::disposing();
}
@@ -78,7 +78,7 @@ namespace vclcanvas
ENSURE_OR_THROW( pTarget,
"CachedBitmap::redraw(): cannot cast target to RepaintTarget" );
- if( !pTarget->repaint( mpGraphicObject,
+ if( !pTarget->repaint( m_rGraphicObject,
rNewState,
maRenderState,
maPoint,
diff --git a/canvas/source/vcl/cachedbitmap.hxx b/canvas/source/vcl/cachedbitmap.hxx
index 4065fdc7fcfb..255aeb60ed8a 100644
--- a/canvas/source/vcl/cachedbitmap.hxx
+++ b/canvas/source/vcl/cachedbitmap.hxx
@@ -31,7 +31,6 @@
namespace vclcanvas
{
- typedef ::boost::shared_ptr< GraphicObject > GraphicObjectSharedPtr;
class CachedBitmap : public ::canvas::CachedPrimitiveBase
{
@@ -39,7 +38,7 @@ namespace vclcanvas
/** Create an XCachedPrimitive for given GraphicObject
*/
- CachedBitmap( const GraphicObjectSharedPtr& rGraphicObject,
+ CachedBitmap( const rtl::Reference<GraphicObject>& rGraphicObject,
const ::Point& rPoint,
const ::Size& rSize,
const GraphicAttr& rAttr,
@@ -59,7 +58,7 @@ namespace vclcanvas
bool bSameViewTransform );
- GraphicObjectSharedPtr mpGraphicObject;
+ rtl::Reference<GraphicObject> m_rGraphicObject;
const ::com::sun::star::rendering::RenderState maRenderState;
const ::Point maPoint;
const ::Size maSize;
diff --git a/canvas/source/vcl/canvas.cxx b/canvas/source/vcl/canvas.cxx
index 5a44e4016307..9f3df1855e5a 100644
--- a/canvas/source/vcl/canvas.cxx
+++ b/canvas/source/vcl/canvas.cxx
@@ -135,7 +135,7 @@ namespace vclcanvas
return OUString( CANVAS_SERVICE_NAME );
}
- bool Canvas::repaint( const GraphicObjectSharedPtr& rGrf,
+ bool Canvas::repaint( const rtl::Reference<GraphicObject>& rGrf,
const rendering::ViewState& viewState,
const rendering::RenderState& renderState,
const ::Point& rPt,
diff --git a/canvas/source/vcl/canvas.hxx b/canvas/source/vcl/canvas.hxx
index 10bee3b48783..3706efa1d71e 100644
--- a/canvas/source/vcl/canvas.hxx
+++ b/canvas/source/vcl/canvas.hxx
@@ -101,7 +101,7 @@ namespace vclcanvas
virtual OUString SAL_CALL getServiceName( ) throw (::com::sun::star::uno::RuntimeException);
// RepaintTarget
- virtual bool repaint( const GraphicObjectSharedPtr& rGrf,
+ virtual bool repaint( const rtl::Reference<GraphicObject>& rGrf,
const com::sun::star::rendering::ViewState& viewState,
const com::sun::star::rendering::RenderState& renderState,
const ::Point& rPt,
diff --git a/canvas/source/vcl/canvasbitmap.cxx b/canvas/source/vcl/canvasbitmap.cxx
index a469e448ed41..e145379e5329 100644
--- a/canvas/source/vcl/canvasbitmap.cxx
+++ b/canvas/source/vcl/canvasbitmap.cxx
@@ -101,7 +101,7 @@ namespace vclcanvas
return maCanvasHelper.getBitmap();
}
- bool CanvasBitmap::repaint( const GraphicObjectSharedPtr& rGrf,
+ bool CanvasBitmap::repaint( const rtl::Reference<GraphicObject>& rGrf,
const rendering::ViewState& viewState,
const rendering::RenderState& renderState,
const ::Point& rPt,
diff --git a/canvas/source/vcl/canvasbitmap.hxx b/canvas/source/vcl/canvasbitmap.hxx
index 176d4faea3bf..826582f104da 100644
--- a/canvas/source/vcl/canvasbitmap.hxx
+++ b/canvas/source/vcl/canvasbitmap.hxx
@@ -84,7 +84,7 @@ namespace vclcanvas
virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames( ) throw (::com::sun::star::uno::RuntimeException);
// RepaintTarget interface
- virtual bool repaint( const GraphicObjectSharedPtr& rGrf,
+ virtual bool repaint( const rtl::Reference<GraphicObject>& rGrf,
const ::com::sun::star::rendering::ViewState& viewState,
const ::com::sun::star::rendering::RenderState& renderState,
const ::Point& rPt,
diff --git a/canvas/source/vcl/canvascustomsprite.cxx b/canvas/source/vcl/canvascustomsprite.cxx
index 9dead83713de..17d0a2d64451 100644
--- a/canvas/source/vcl/canvascustomsprite.cxx
+++ b/canvas/source/vcl/canvascustomsprite.cxx
@@ -161,7 +161,7 @@ namespace vclcanvas
mbSurfaceDirty = false;
}
- bool CanvasCustomSprite::repaint( const GraphicObjectSharedPtr& rGrf,
+ bool CanvasCustomSprite::repaint( const rtl::Reference<GraphicObject>& rGrf,
const rendering::ViewState& viewState,
const rendering::RenderState& renderState,
const ::Point& rPt,
diff --git a/canvas/source/vcl/canvascustomsprite.hxx b/canvas/source/vcl/canvascustomsprite.hxx
index 0014c3f91392..5ca7fc608826 100644
--- a/canvas/source/vcl/canvascustomsprite.hxx
+++ b/canvas/source/vcl/canvascustomsprite.hxx
@@ -111,7 +111,7 @@ namespace vclcanvas
bool bBufferedUpdate ) const;
// RepaintTarget
- virtual bool repaint( const GraphicObjectSharedPtr& rGrf,
+ virtual bool repaint( const rtl::Reference<GraphicObject>& rGrf,
const ::com::sun::star::rendering::ViewState& viewState,
const ::com::sun::star::rendering::RenderState& renderState,
const ::Point& rPt,
diff --git a/canvas/source/vcl/canvashelper.cxx b/canvas/source/vcl/canvashelper.cxx
index 54fff82b4d74..c1a28dfd7a72 100644
--- a/canvas/source/vcl/canvashelper.cxx
+++ b/canvas/source/vcl/canvashelper.cxx
@@ -763,7 +763,7 @@ namespace vclcanvas
aMatrix.decompose( aScale, aOutputPos, nRotate, nShearX );
GraphicAttr aGrfAttr;
- GraphicObjectSharedPtr pGrfObj;
+ rtl::Reference<GraphicObject> rGrfObj;
::Size aBmpSize( aBmpEx.GetSizePixel() );
@@ -803,7 +803,7 @@ namespace vclcanvas
const double nAngleInTenthOfDegrees (3600.0 - nRotate * 3600.0 / (2*M_PI));
aGrfAttr.SetRotation( static_cast< sal_uInt16 >(::basegfx::fround(nAngleInTenthOfDegrees)) );
- pGrfObj.reset( new GraphicObject( aBmpEx ) );
+ rGrfObj = GraphicObject::Create( aBmpEx );
}
else
{
@@ -828,7 +828,7 @@ namespace vclcanvas
renderState.DeviceColor,
tools::MODULATE_NONE );
- pGrfObj.reset( new GraphicObject( aBmpEx ) );
+ rGrfObj = GraphicObject::Create( aBmpEx );
// clear scale values, generated bitmap already
// contains scaling
@@ -843,22 +843,23 @@ namespace vclcanvas
const ::Size aSz( ::basegfx::fround( aScale.getX() * aBmpSize.Width() ),
::basegfx::fround( aScale.getY() * aBmpSize.Height() ) );
- pGrfObj->Draw( &mpOutDev->getOutDev(),
+ rGrfObj->Draw( &mpOutDev->getOutDev(),
aPt,
aSz,
&aGrfAttr );
if( mp2ndOutDev )
- pGrfObj->Draw( &mp2ndOutDev->getOutDev(),
+ {
+ rGrfObj->Draw( &mp2ndOutDev->getOutDev(),
aPt,
aSz,
&aGrfAttr );
-
+ }
// created GraphicObject, which possibly cached
// display bitmap - return cache object, to retain
// that information.
return uno::Reference< rendering::XCachedPrimitive >(
- new CachedBitmap( pGrfObj,
+ new CachedBitmap( rGrfObj,
aPt,
aSz,
aGrfAttr,
@@ -1410,14 +1411,14 @@ namespace vclcanvas
return true;
}
- bool CanvasHelper::repaint( const GraphicObjectSharedPtr& rGrf,
+bool CanvasHelper::repaint( const rtl::Reference<GraphicObject>& rGrf,
const rendering::ViewState& viewState,
const rendering::RenderState& renderState,
const ::Point& rPt,
const ::Size& rSz,
const GraphicAttr& rAttr ) const
{
- ENSURE_OR_RETURN_FALSE( rGrf,
+ ENSURE_OR_RETURN_FALSE( rGrf.is(),
"Invalid Graphic" );
if( !mpOutDev )
diff --git a/canvas/source/vcl/canvashelper.hxx b/canvas/source/vcl/canvashelper.hxx
index 5729d60c103e..a37496160e6c 100644
--- a/canvas/source/vcl/canvashelper.hxx
+++ b/canvas/source/vcl/canvashelper.hxx
@@ -264,7 +264,7 @@ namespace vclcanvas
::com::sun::star::rendering::IntegerBitmapLayout getMemoryLayout();
/// Repaint a cached bitmap
- bool repaint( const GraphicObjectSharedPtr& rGrf,
+ bool repaint( const rtl::Reference<GraphicObject>& rGrf,
const ::com::sun::star::rendering::ViewState& viewState,
const ::com::sun::star::rendering::RenderState& renderState,
const ::Point& rPt,
diff --git a/canvas/source/vcl/canvashelper_texturefill.cxx b/canvas/source/vcl/canvashelper_texturefill.cxx
index 2da3dc607ae8..a235b7b093e1 100644
--- a/canvas/source/vcl/canvashelper_texturefill.cxx
+++ b/canvas/source/vcl/canvashelper_texturefill.cxx
@@ -69,7 +69,7 @@ namespace vclcanvas
namespace
{
bool textureFill( OutputDevice& rOutDev,
- GraphicObject& rGraphic,
+ rtl::Reference<GraphicObject>& rGraphicObject,
const ::Point& rPosPixel,
const ::Size& rNextTileX,
const ::Size& rNextTileY,
@@ -91,7 +91,7 @@ namespace vclcanvas
{
// update return value. This method should return true, if
// at least one of the looped Draws succeeded.
- bRet |= ( sal_True == rGraphic.Draw( &rOutDev,
+ bRet |= ( sal_True == rGraphicObject->Draw( &rOutDev,
aCurrPos,
rTileSize,
&rAttr ) );
@@ -842,7 +842,7 @@ namespace vclcanvas
aTotalTransform.decompose( aScale, aOutputPos, nRotate, nShearX );
GraphicAttr aGrfAttr;
- GraphicObjectSharedPtr pGrfObj;
+ rtl::Reference<GraphicObject> rGrfObj;
if( ::basegfx::fTools::equalZero( nShearX ) )
{
@@ -856,7 +856,7 @@ namespace vclcanvas
( aScale.getY() < 0.0 ? BMP_MIRROR_VERT : 0 ) );
aGrfAttr.SetRotation( static_cast< sal_uInt16 >(::basegfx::fround( nRotate*10.0 )) );
- pGrfObj.reset( new GraphicObject( aBmpEx ) );
+ rGrfObj = GraphicObject::Create( aBmpEx );
}
else
{
@@ -867,7 +867,7 @@ namespace vclcanvas
uno::Sequence< double >(),
tools::MODULATE_NONE);
- pGrfObj.reset( new GraphicObject( aBmpEx ) );
+ rGrfObj = GraphicObject::Create( aBmpEx );
// clear scale values, generated bitmap already
// contains scaling
@@ -989,7 +989,7 @@ namespace vclcanvas
rOutDev.IntersectClipRegion( aPolygonDeviceRect );
textureFill( rOutDev,
- *pGrfObj,
+ rGrfObj,
aPt,
aIntegerNextTileX,
aIntegerNextTileY,
@@ -1003,7 +1003,7 @@ namespace vclcanvas
OutputDevice& r2ndOutDev( mp2ndOutDev->getOutDev() );
r2ndOutDev.IntersectClipRegion( aPolygonDeviceRect );
textureFill( r2ndOutDev,
- *pGrfObj,
+ rGrfObj,
aPt,
aIntegerNextTileX,
aIntegerNextTileY,
@@ -1038,7 +1038,7 @@ namespace vclcanvas
aVDev.SetClipRegion( aPolyClipRegion );
textureFill( aVDev,
- *pGrfObj,
+ rGrfObj,
aOutPos,
aIntegerNextTileX,
aIntegerNextTileY,
@@ -1075,7 +1075,7 @@ namespace vclcanvas
rOutDev.SetClipRegion( aPolyClipRegion );
textureFill( rOutDev,
- *pGrfObj,
+ rGrfObj,
aPt,
aIntegerNextTileX,
aIntegerNextTileY,
@@ -1092,7 +1092,7 @@ namespace vclcanvas
r2ndOutDev.SetClipRegion( aPolyClipRegion );
textureFill( r2ndOutDev,
- *pGrfObj,
+ rGrfObj,
aPt,
aIntegerNextTileX,
aIntegerNextTileY,
diff --git a/canvas/source/vcl/repainttarget.hxx b/canvas/source/vcl/repainttarget.hxx
index 84363da81e99..89a495267afa 100644
--- a/canvas/source/vcl/repainttarget.hxx
+++ b/canvas/source/vcl/repainttarget.hxx
@@ -43,7 +43,7 @@ namespace vclcanvas
virtual ~RepaintTarget() {}
// call this when a bitmap is repainted
- virtual bool repaint( const GraphicObjectSharedPtr& rGrf,
+ virtual bool repaint( const rtl::Reference<GraphicObject>& rGrf,
const ::com::sun::star::rendering::ViewState& viewState,
const ::com::sun::star::rendering::RenderState& renderState,
const ::Point& rPt,
diff --git a/canvas/source/vcl/spritecanvas.cxx b/canvas/source/vcl/spritecanvas.cxx
index c18a7f9e6a58..b0ea7250b9a5 100644
--- a/canvas/source/vcl/spritecanvas.cxx
+++ b/canvas/source/vcl/spritecanvas.cxx
@@ -154,7 +154,7 @@ namespace vclcanvas
return OUString( SPRITECANVAS_SERVICE_NAME );
}
- bool SpriteCanvas::repaint( const GraphicObjectSharedPtr& rGrf,
+ bool SpriteCanvas::repaint( const rtl::Reference<GraphicObject>& rGrf,
const rendering::ViewState& viewState,
const rendering::RenderState& renderState,
const ::Point& rPt,
diff --git a/canvas/source/vcl/spritecanvas.hxx b/canvas/source/vcl/spritecanvas.hxx
index 5ca1f77d25f0..83c96549f88a 100644
--- a/canvas/source/vcl/spritecanvas.hxx
+++ b/canvas/source/vcl/spritecanvas.hxx
@@ -135,7 +135,7 @@ namespace vclcanvas
virtual OUString SAL_CALL getServiceName( ) throw (::com::sun::star::uno::RuntimeException);
// RepaintTarget
- virtual bool repaint( const GraphicObjectSharedPtr& rGrf,
+ virtual bool repaint( const rtl::Reference<GraphicObject>& rGrf,
const ::com::sun::star::rendering::ViewState& viewState,
const ::com::sun::star::rendering::RenderState& renderState,
const ::Point& rPt,