Simplify ImplRepository::impl_getLocationForModel return type
Change-Id: I937f96457347195ed18ddcdc75b1106840f0522e
This commit is contained in:
@@ -122,7 +122,7 @@ namespace basic
|
|||||||
@precond
|
@precond
|
||||||
our mutex is locked
|
our mutex is locked
|
||||||
*/
|
*/
|
||||||
BasicManager*&
|
BasicManager*
|
||||||
impl_getLocationForModel( const Reference< XModel >& _rxDocumentModel );
|
impl_getLocationForModel( const Reference< XModel >& _rxDocumentModel );
|
||||||
|
|
||||||
/** creates a new BasicManager instance for the given model
|
/** creates a new BasicManager instance for the given model
|
||||||
@@ -247,7 +247,7 @@ namespace basic
|
|||||||
thus a recursive call of this function will find and return it
|
thus a recursive call of this function will find and return it
|
||||||
without creating another instance.
|
without creating another instance.
|
||||||
*/
|
*/
|
||||||
BasicManager*& pBasicManager = impl_getLocationForModel( _rxDocumentModel );
|
BasicManager* pBasicManager = impl_getLocationForModel( _rxDocumentModel );
|
||||||
if ( pBasicManager == NULL )
|
if ( pBasicManager == NULL )
|
||||||
impl_createManagerForModel( pBasicManager, _rxDocumentModel );
|
impl_createManagerForModel( pBasicManager, _rxDocumentModel );
|
||||||
|
|
||||||
@@ -378,12 +378,12 @@ namespace basic
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
BasicManager*& ImplRepository::impl_getLocationForModel( const Reference< XModel >& _rxDocumentModel )
|
BasicManager* ImplRepository::impl_getLocationForModel( const Reference< XModel >& _rxDocumentModel )
|
||||||
{
|
{
|
||||||
Reference< XInterface > xNormalized( _rxDocumentModel, UNO_QUERY );
|
Reference< XInterface > xNormalized( _rxDocumentModel, UNO_QUERY );
|
||||||
DBG_ASSERT( _rxDocumentModel.is(), "ImplRepository::impl_getLocationForModel: invalid model!" );
|
DBG_ASSERT( _rxDocumentModel.is(), "ImplRepository::impl_getLocationForModel: invalid model!" );
|
||||||
|
|
||||||
BasicManager*& location = m_aStore[ xNormalized ];
|
BasicManager* location = m_aStore[ xNormalized ];
|
||||||
return location;
|
return location;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user