diff options
author | Eike Rathke <erack@redhat.com> | 2016-11-28 10:40:23 +0100 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2016-11-28 10:41:48 +0100 |
commit | dd974413acc6ab00168a301cbb53b3c9caa11e32 (patch) | |
tree | 651227b2a4a97ccbdd6bc1f7a9848f019ed6545d /sc | |
parent | 0b719cd36d57a628fd1ab79d0371fb46e6c1bf1d (diff) |
nitpicks, tdf#43544 follow-up
Address nitpicks stated in https://gerrit.libreoffice.org/29274
Change-Id: If7ce8a7239a65a2ff619259622b85ce239060e52
Diffstat (limited to 'sc')
-rw-r--r-- | sc/inc/styleuno.hxx | 2 | ||||
-rw-r--r-- | sc/source/ui/unoobj/styleuno.cxx | 13 |
2 files changed, 10 insertions, 5 deletions
diff --git a/sc/inc/styleuno.hxx b/sc/inc/styleuno.hxx index b1b5fe7184ff..ff48b6d092e6 100644 --- a/sc/inc/styleuno.hxx +++ b/sc/inc/styleuno.hxx @@ -223,7 +223,7 @@ private: OUString aStyleName; SfxStyleSheetBase* pStyle_cached; - SfxStyleSheetBase* GetStyle_Impl( bool useCachedValue = false ); + SfxStyleSheetBase* GetStyle_Impl( bool bUseCachedValue = false ); const SfxItemSet* GetStyleItemSet_Impl( const OUString& rPropName, const SfxItemPropertySimpleEntry*& rpEntry ); css::beans::PropertyState getPropertyState_Impl( const OUString& PropertyName ) throw(css::beans::UnknownPropertyException, css::uno::RuntimeException, std::exception); diff --git a/sc/source/ui/unoobj/styleuno.cxx b/sc/source/ui/unoobj/styleuno.cxx index f0a2be6d4cdf..d12373484ded 100644 --- a/sc/source/ui/unoobj/styleuno.cxx +++ b/sc/source/ui/unoobj/styleuno.cxx @@ -582,8 +582,11 @@ void ScStyleFamiliesObj::loadStylesFromDocShell( ScDocShell* pSource, bool bLoadCellStyles = true; bool bLoadPageStyles = true; - for ( const beans::PropertyValue& rProp : aOptions ) + const beans::PropertyValue* pPropArray = aOptions.getConstArray(); + sal_Int32 nPropCount = aOptions.getLength(); + for (sal_Int32 i = 0; i < nPropCount; i++) { + const beans::PropertyValue& rProp = pPropArray[i]; OUString aPropName(rProp.Name); if (aPropName == SC_UNONAME_OVERWSTL) @@ -1013,10 +1016,11 @@ void ScStyleObj::Notify( SfxBroadcaster&, const SfxHint& rHint ) } } -SfxStyleSheetBase* ScStyleObj::GetStyle_Impl( bool useCachedValue ) +SfxStyleSheetBase* ScStyleObj::GetStyle_Impl( bool bUseCachedValue ) { - if ( useCachedValue ) + if ( bUseCachedValue ) return pStyle_cached; + pStyle_cached = nullptr; if ( pDocShell ) { @@ -1249,10 +1253,11 @@ uno::Sequence<beans::PropertyState> SAL_CALL ScStyleObj::getPropertyStates( cons SolarMutexGuard aGuard; GetStyle_Impl(); + const OUString* pNames = aPropertyNames.getConstArray(); uno::Sequence<beans::PropertyState> aRet( aPropertyNames.getLength() ); beans::PropertyState* pStates = aRet.getArray(); for ( sal_Int32 i = 0; i < aPropertyNames.getLength(); i++ ) - pStates[i] = getPropertyState_Impl( aPropertyNames[i] ); + pStates[i] = getPropertyState_Impl( pNames[i] ); return aRet; } |