diff options
author | Caolán McNamara <caolanm@redhat.com> | 2017-01-09 15:48:36 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2017-01-10 08:53:15 +0000 |
commit | 8564b5beb1c49104d555e70d3c6134908fc0811f (patch) | |
tree | f957e75ea90da318a21543497da4203bf7266d3c /svtools | |
parent | 48c100d7300c73a6501317c553a24adfca2a5f4c (diff) |
first GraphicManager* arg of ImplSetGraphicManager is thus always null
Change-Id: I3da98280d3c1d95663e6e43ce7a5ca82c001c334
Diffstat (limited to 'svtools')
-rw-r--r-- | svtools/source/graphic/grfmgr.cxx | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/svtools/source/graphic/grfmgr.cxx b/svtools/source/graphic/grfmgr.cxx index 0b04656bb8df..d0e27c408d80 100644 --- a/svtools/source/graphic/grfmgr.cxx +++ b/svtools/source/graphic/grfmgr.cxx @@ -77,7 +77,7 @@ GraphicObject::GraphicObject() : { ImplConstruct(); ImplAssignGraphicData(); - ImplSetGraphicManager( nullptr ); + ImplSetGraphicManager(); } GraphicObject::GraphicObject( const Graphic& rGraphic ) : @@ -87,7 +87,7 @@ GraphicObject::GraphicObject( const Graphic& rGraphic ) : { ImplConstruct(); ImplAssignGraphicData(); - ImplSetGraphicManager( nullptr ); + ImplSetGraphicManager(); } GraphicObject::GraphicObject( const GraphicObject& rGraphicObj ) : @@ -98,7 +98,7 @@ GraphicObject::GraphicObject( const GraphicObject& rGraphicObj ) : { ImplConstruct(); ImplAssignGraphicData(); - ImplSetGraphicManager( nullptr, nullptr, &rGraphicObj ); + ImplSetGraphicManager(nullptr, &rGraphicObj); if( rGraphicObj.HasUserData() && rGraphicObj.IsSwappedOut() ) SetSwapState(); } @@ -112,7 +112,7 @@ GraphicObject::GraphicObject( const OString& rUniqueID ) : // assign default properties ImplAssignGraphicData(); - ImplSetGraphicManager( nullptr, &rUniqueID ); + ImplSetGraphicManager(&rUniqueID); // update properties ImplAssignGraphicData(); @@ -161,11 +161,11 @@ void GraphicObject::ImplAssignGraphicData() ImplAfterDataChange(); } -void GraphicObject::ImplSetGraphicManager( const GraphicManager* pMgr, const OString* pID, const GraphicObject* pCopyObj ) +void GraphicObject::ImplSetGraphicManager(const OString* pID, const GraphicObject* pCopyObj) { - if( !mpMgr || ( pMgr != mpMgr ) ) + if (!mpMgr || mpMgr) { - if( !pMgr && mpMgr && ( mpMgr == mpGlobalMgr ) ) + if (mpMgr && mpMgr == mpGlobalMgr) return; else { @@ -180,7 +180,7 @@ void GraphicObject::ImplSetGraphicManager( const GraphicManager* pMgr, const OSt } } - if( !pMgr ) + if (true) { if( !mpGlobalMgr ) { @@ -208,7 +208,7 @@ void GraphicObject::ImplSetGraphicManager( const GraphicManager* pMgr, const OSt mpMgr = mpGlobalMgr; } else - mpMgr = const_cast<GraphicManager*>(pMgr); + mpMgr = nullptr; mpMgr->ImplRegisterObj( *this, maGraphic, pID, pCopyObj ); } @@ -473,7 +473,7 @@ void GraphicObject::GraphicManagerDestroyed() { // we're alive, but our manager doesn't live anymore ==> connect to default manager mpMgr = nullptr; - ImplSetGraphicManager( nullptr ); + ImplSetGraphicManager(); } bool GraphicObject::IsCached( OutputDevice* pOut, const Point& rPt, const Size& rSz, |