[Libreoffice-commits] core.git: 4 commits - basctl/source framework/inc framework/source sd/inc sd/source starmath/inc starmath/source
Noel Grandin
noel at peralex.com
Tue Apr 12 10:06:45 UTC 2016
basctl/source/basicide/basides1.cxx | 4
basctl/source/basicide/bastype2.cxx | 13 +-
basctl/source/basicide/localizationmgr.cxx | 39 +++----
basctl/source/basicide/moduldl2.cxx | 37 +++----
basctl/source/dlged/dlged.cxx | 4
basctl/source/inc/dlged.hxx | 2
basctl/source/inc/localizationmgr.hxx | 29 ++---
framework/inc/classes/actiontriggerpropertyset.hxx | 8 -
framework/inc/dispatch/dispatchprovider.hxx | 6 -
framework/inc/recording/dispatchrecorder.hxx | 2
framework/inc/uielement/toolbarmanager.hxx | 2
framework/source/dispatch/dispatchprovider.cxx | 4
framework/source/fwe/classes/actiontriggerpropertyset.cxx | 4
framework/source/fwe/helper/actiontriggerhelper.cxx | 6 -
framework/source/recording/dispatchrecorder.cxx | 2
framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx | 4
framework/source/uielement/toolbarmanager.cxx | 2
sd/inc/CustomAnimationEffect.hxx | 12 +-
sd/inc/CustomAnimationPreset.hxx | 4
sd/source/core/CustomAnimationEffect.cxx | 12 +-
sd/source/core/CustomAnimationPreset.cxx | 4
sd/source/filter/eppt/eppt.cxx | 4
sd/source/filter/eppt/epptooxml.hxx | 36 +++----
sd/source/filter/eppt/pptx-epptooxml.cxx | 50 +++++-----
sd/source/filter/xml/sdxmlwrp.cxx | 6 -
sd/source/ui/animations/CustomAnimationList.cxx | 10 +-
sd/source/ui/animations/CustomAnimationList.hxx | 4
sd/source/ui/animations/CustomAnimationPane.cxx | 8 -
sd/source/ui/animations/CustomAnimationPane.hxx | 4
sd/source/ui/annotations/annotationmanager.cxx | 6 -
sd/source/ui/annotations/annotationmanagerimpl.hxx | 6 -
sd/source/ui/dlg/PhotoAlbumDialog.cxx | 4
sd/source/ui/dlg/PhotoAlbumDialog.hxx | 4
sd/source/ui/dlg/RemoteDialogClientBox.cxx | 2
sd/source/ui/dlg/RemoteDialogClientBox.hxx | 2
sd/source/ui/dlg/dlgass.cxx | 4
sd/source/ui/func/fuinsfil.cxx | 2
sd/source/ui/inc/RemoteServer.hxx | 6 -
sd/source/ui/inc/SlideSorterViewShell.hxx | 2
sd/source/ui/inc/View.hxx | 2
sd/source/ui/inc/ViewShell.hxx | 2
sd/source/ui/inc/tools/SdGlobalResourceContainer.hxx | 2
sd/source/ui/inc/unosrch.hxx | 8 -
sd/source/ui/remotecontrol/Server.cxx | 4
sd/source/ui/slidesorter/cache/SlsPageCacheManager.cxx | 10 +-
sd/source/ui/slidesorter/inc/cache/SlsPageCacheManager.hxx | 10 +-
sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx | 2
sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx | 2
sd/source/ui/tools/SdGlobalResourceContainer.cxx | 2
sd/source/ui/unoidl/unolayer.cxx | 2
sd/source/ui/unoidl/unomodel.cxx | 4
sd/source/ui/unoidl/unosrch.cxx | 8 -
sd/source/ui/unoidl/unowcntr.cxx | 2
sd/source/ui/unoidl/unowcntr.hxx | 4
sd/source/ui/view/sdview3.cxx | 2
sd/source/ui/view/viewshel.cxx | 2
starmath/inc/document.hxx | 2
starmath/source/document.cxx | 2
starmath/source/mathmlexport.cxx | 6 -
starmath/source/mathmlexport.hxx | 6 -
starmath/source/mathmlimport.cxx | 6 -
starmath/source/mathmlimport.hxx | 6 -
starmath/source/ooxmlexport.cxx | 2
starmath/source/ooxmlexport.hxx | 2
64 files changed, 225 insertions(+), 235 deletions(-)
New commits:
commit 48b8898bd7a4c51eb541edfd1aa51ac71c5ac5af
Author: Noel Grandin <noel at peralex.com>
Date: Tue Apr 12 12:04:56 2016 +0200
clang-tidy performance-unnecessary-value-param in basctl
Change-Id: Ie48eb08edd1335661d1ef57ae652713143951317
diff --git a/basctl/source/basicide/basides1.cxx b/basctl/source/basicide/basides1.cxx
index b4b5090..23e25cb 100644
--- a/basctl/source/basicide/basides1.cxx
+++ b/basctl/source/basicide/basides1.cxx
@@ -345,7 +345,7 @@ void Shell::ExecuteGlobal( SfxRequest& rReq )
if ( aWindowTable.find( rTabId.GetValue() ) != aWindowTable.end() )
{
BaseWindow* pWin = aWindowTable[ rTabId.GetValue() ];
- OUString aNewName( rModName.GetValue() );
+ const OUString& aNewName( rModName.GetValue() );
OUString aOldName( pWin->GetName() );
if ( aNewName != aOldName )
{
@@ -431,7 +431,7 @@ void Shell::ExecuteGlobal( SfxRequest& rReq )
uno::Reference< frame::XModel > xModel( rShellItem.GetValue(), UNO_QUERY );
ScriptDocument aDocument( xModel.is() ? ScriptDocument( xModel ) : ScriptDocument::getApplicationScriptDocument() );
const SfxStringItem& rLibNameItem = static_cast<const SfxStringItem&>(rReq.GetArgs()->Get( SID_BASICIDE_ARG_LIBNAME ));
- OUString aLibName( rLibNameItem.GetValue() );
+ const OUString& aLibName( rLibNameItem.GetValue() );
if ( nSlot == SID_BASICIDE_LIBSELECTED )
{
diff --git a/basctl/source/basicide/bastype2.cxx b/basctl/source/basicide/bastype2.cxx
index 6d450e2..20a4ecc 100644
--- a/basctl/source/basicide/bastype2.cxx
+++ b/basctl/source/basicide/bastype2.cxx
@@ -257,15 +257,14 @@ void TreeListBox::ImpCreateLibEntries( SvTreeListEntry* pDocumentRootEntry, cons
{
// check, if the module library is loaded
bool bModLibLoaded = false;
- OUString aOULibName( aLibName );
Reference< script::XLibraryContainer > xModLibContainer( rDocument.getLibraryContainer( E_SCRIPTS ) );
- if ( xModLibContainer.is() && xModLibContainer->hasByName( aOULibName ) && xModLibContainer->isLibraryLoaded( aOULibName ) )
+ if ( xModLibContainer.is() && xModLibContainer->hasByName( aLibName ) && xModLibContainer->isLibraryLoaded( aLibName ) )
bModLibLoaded = true;
// check, if the dialog library is loaded
bool bDlgLibLoaded = false;
Reference< script::XLibraryContainer > xDlgLibContainer( rDocument.getLibraryContainer( E_DIALOGS ) );
- if ( xDlgLibContainer.is() && xDlgLibContainer->hasByName( aOULibName ) && xDlgLibContainer->isLibraryLoaded( aOULibName ) )
+ if ( xDlgLibContainer.is() && xDlgLibContainer->hasByName( aLibName ) && xDlgLibContainer->isLibraryLoaded( aLibName ) )
bDlgLibLoaded = true;
bool bLoaded = bModLibLoaded || bDlgLibLoaded;
@@ -273,11 +272,11 @@ void TreeListBox::ImpCreateLibEntries( SvTreeListEntry* pDocumentRootEntry, cons
// if only one of the libraries is loaded, load also the other
if ( bLoaded )
{
- if ( xModLibContainer.is() && xModLibContainer->hasByName( aOULibName ) && !xModLibContainer->isLibraryLoaded( aOULibName ) )
- xModLibContainer->loadLibrary( aOULibName );
+ if ( xModLibContainer.is() && xModLibContainer->hasByName( aLibName ) && !xModLibContainer->isLibraryLoaded( aLibName ) )
+ xModLibContainer->loadLibrary( aLibName );
- if ( xDlgLibContainer.is() && xDlgLibContainer->hasByName( aOULibName ) && !xDlgLibContainer->isLibraryLoaded( aOULibName ) )
- xDlgLibContainer->loadLibrary( aOULibName );
+ if ( xDlgLibContainer.is() && xDlgLibContainer->hasByName( aLibName ) && !xDlgLibContainer->isLibraryLoaded( aLibName ) )
+ xDlgLibContainer->loadLibrary( aLibName );
}
// create tree list box entry
diff --git a/basctl/source/basicide/localizationmgr.cxx b/basctl/source/basicide/localizationmgr.cxx
index b109e68..0fb4244 100644
--- a/basctl/source/basicide/localizationmgr.cxx
+++ b/basctl/source/basicide/localizationmgr.cxx
@@ -168,7 +168,7 @@ void LocalizationMgr::implEnableDisableResourceForAllLibraryDialogs( HandleResou
OUString implCreatePureResourceId
( const OUString& aDialogName, const OUString& aCtrlName,
const OUString& aPropName,
- Reference< XStringResourceManager > xStringResourceManager )
+ const Reference< XStringResourceManager >& xStringResourceManager )
{
sal_Int32 nUniqueId = xStringResourceManager->getUniqueNumericId();
OUString aPureIdStr = OUString::number( nUniqueId );
@@ -189,8 +189,8 @@ OUString implCreatePureResourceId
// either the first one for mode SET_IDS or the last one for mode RESET_IDS
sal_Int32 LocalizationMgr::implHandleControlResourceProperties
(const Any& rControlAny, const OUString& aDialogName, const OUString& aCtrlName,
- Reference< XStringResourceManager > xStringResourceManager,
- Reference< XStringResourceResolver > xSourceStringResolver, HandleResourceMode eMode )
+ const Reference< XStringResourceManager >& xStringResourceManager,
+ const Reference< XStringResourceResolver >& xSourceStringResolver, HandleResourceMode eMode )
{
sal_Int32 nChangedCount = 0;
@@ -296,8 +296,7 @@ sal_Int32 LocalizationMgr::implHandleControlResourceProperties
// Rename resource id
else if( eMode == RENAME_DIALOG_IDS || eMode == RENAME_CONTROL_IDS )
{
- OUString aSourceIdStr = aPropStr;
- OUString aPureSourceIdStr = aSourceIdStr.copy( 1 );
+ OUString aPureSourceIdStr = aPropStr.copy( 1 );
OUString aPureIdStr = implCreatePureResourceId
( aDialogName, aCtrlName, aPropName, xStringResourceManager );
@@ -329,8 +328,7 @@ sal_Int32 LocalizationMgr::implHandleControlResourceProperties
// Replace string by string from source StringResourceResolver
else if( eMode == MOVE_RESOURCES && xSourceStringResolver.is() )
{
- OUString aSourceIdStr = aPropStr;
- OUString aPureSourceIdStr = aSourceIdStr.copy( 1 );
+ OUString aPureSourceIdStr = aPropStr.copy( 1 );
OUString aPureIdStr = implCreatePureResourceId
( aDialogName, aCtrlName, aPropName, xStringResourceManager );
@@ -366,8 +364,7 @@ sal_Int32 LocalizationMgr::implHandleControlResourceProperties
// Copy string from source to target resource
else if( eMode == COPY_RESOURCES && xSourceStringResolver.is() )
{
- OUString aSourceIdStr = aPropStr;
- OUString aPureSourceIdStr = aSourceIdStr.copy( 1 );
+ OUString aPureSourceIdStr = aPropStr.copy( 1 );
const Locale& rDefaultLocale = xSourceStringResolver->getDefaultLocale();
@@ -899,7 +896,7 @@ void LocalizationMgr::deleteControlResourceIDsForDeletedEditorObject( DlgEditor*
}
void LocalizationMgr::setStringResourceAtDialog( const ScriptDocument& rDocument, const OUString& aLibName,
- const OUString& aDlgName, Reference< container::XNameContainer > xDialogModel )
+ const OUString& aDlgName, const Reference< container::XNameContainer >& xDialogModel )
{
static const char aResourceResolverPropName[] = "ResourceResolver";
@@ -931,7 +928,7 @@ void LocalizationMgr::setStringResourceAtDialog( const ScriptDocument& rDocument
}
void LocalizationMgr::renameStringResourceIDs( const ScriptDocument& rDocument, const OUString& aLibName,
- const OUString& aDlgName, Reference< container::XNameContainer > xDialogModel )
+ const OUString& aDlgName, const Reference< container::XNameContainer >& xDialogModel )
{
// Get library
Reference< container::XNameContainer > xDialogLib( rDocument.getLibrary( E_DIALOGS, aLibName, true ) );
@@ -962,7 +959,7 @@ void LocalizationMgr::renameStringResourceIDs( const ScriptDocument& rDocument,
}
void LocalizationMgr::removeResourceForDialog( const ScriptDocument& rDocument, const OUString& aLibName,
- const OUString& aDlgName, Reference< container::XNameContainer > xDialogModel )
+ const OUString& aDlgName, const Reference< container::XNameContainer >& xDialogModel )
{
// Get library
Reference< container::XNameContainer > xDialogLib( rDocument.getLibrary( E_DIALOGS, aLibName, true ) );
@@ -992,8 +989,8 @@ void LocalizationMgr::removeResourceForDialog( const ScriptDocument& rDocument,
}
}
-void LocalizationMgr::resetResourceForDialog( Reference< container::XNameContainer > xDialogModel,
- Reference< XStringResourceManager > xStringResourceManager )
+void LocalizationMgr::resetResourceForDialog( const Reference< container::XNameContainer >& xDialogModel,
+ const Reference< XStringResourceManager >& xStringResourceManager )
{
if( !xStringResourceManager.is() )
return;
@@ -1019,8 +1016,8 @@ void LocalizationMgr::resetResourceForDialog( Reference< container::XNameContain
}
}
-void LocalizationMgr::setResourceIDsForDialog( Reference< container::XNameContainer > xDialogModel,
- Reference< XStringResourceManager > xStringResourceManager )
+void LocalizationMgr::setResourceIDsForDialog( const Reference< container::XNameContainer >& xDialogModel,
+ const Reference< XStringResourceManager >& xStringResourceManager )
{
if( !xStringResourceManager.is() )
return;
@@ -1048,7 +1045,7 @@ void LocalizationMgr::setResourceIDsForDialog( Reference< container::XNameContai
void LocalizationMgr::copyResourcesForPastedEditorObject( DlgEditor* pEditor,
const Any& rControlAny, const OUString& aCtrlName,
- Reference< XStringResourceResolver > xSourceStringResolver )
+ const Reference< XStringResourceResolver >& xSourceStringResolver )
{
// Get library for DlgEditor
DialogWindow* pDlgWin = FindDialogWindowForEditor( pEditor );
@@ -1073,9 +1070,9 @@ void LocalizationMgr::copyResourcesForPastedEditorObject( DlgEditor* pEditor,
xSourceStringResolver, MOVE_RESOURCES );
}
-void LocalizationMgr::copyResourceForDroppedDialog( Reference< container::XNameContainer > xDialogModel,
- const OUString& aDialogName, Reference< XStringResourceManager > xStringResourceManager,
- Reference< XStringResourceResolver > xSourceStringResolver )
+void LocalizationMgr::copyResourceForDroppedDialog( const Reference< container::XNameContainer >& xDialogModel,
+ const OUString& aDialogName, const Reference< XStringResourceManager >& xStringResourceManager,
+ const Reference< XStringResourceResolver >& xSourceStringResolver )
{
if( !xStringResourceManager.is() )
return;
@@ -1129,7 +1126,7 @@ void LocalizationMgr::copyResourceForDialog(
}
Reference< XStringResourceManager > LocalizationMgr::getStringResourceFromDialogLibrary
- ( Reference< container::XNameContainer > xDialogLib )
+ ( const Reference< container::XNameContainer >& xDialogLib )
{
Reference< XStringResourceManager > xStringResourceManager;
if( xDialogLib.is() )
diff --git a/basctl/source/basicide/moduldl2.cxx b/basctl/source/basicide/moduldl2.cxx
index 3ca7477..e577325 100644
--- a/basctl/source/basicide/moduldl2.cxx
+++ b/basctl/source/basicide/moduldl2.cxx
@@ -1011,8 +1011,7 @@ void LibPage::InsertLib()
{
try
{
- OUString _aPassword( aPassword );
- xPasswd->changeLibraryPassword( aLibName, OUString(), _aPassword );
+ xPasswd->changeLibraryPassword( aLibName, OUString(), aPassword );
}
catch (...)
{
@@ -1101,16 +1100,15 @@ void LibPage::Export()
OUString aLibName( SvTabListBox::GetEntryText( pCurEntry, 0 ) );
// Password verification
- OUString aOULibName( aLibName );
Reference< script::XLibraryContainer2 > xModLibContainer( m_aCurDocument.getLibraryContainer( E_SCRIPTS ), UNO_QUERY );
- if ( xModLibContainer.is() && xModLibContainer->hasByName( aOULibName ) && !xModLibContainer->isLibraryLoaded( aOULibName ) )
+ if ( xModLibContainer.is() && xModLibContainer->hasByName( aLibName ) && !xModLibContainer->isLibraryLoaded( aLibName ) )
{
bool bOK = true;
// check password
Reference< script::XLibraryContainerPassword > xPasswd( xModLibContainer, UNO_QUERY );
- if ( xPasswd.is() && xPasswd->isLibraryPasswordProtected( aOULibName ) && !xPasswd->isLibraryPasswordVerified( aOULibName ) )
+ if ( xPasswd.is() && xPasswd->isLibraryPasswordProtected( aLibName ) && !xPasswd->isLibraryPasswordVerified( aLibName ) )
{
OUString aPassword;
Reference< script::XLibraryContainer > xModLibContainer1( xModLibContainer, UNO_QUERY );
@@ -1139,22 +1137,21 @@ void LibPage::Export()
void LibPage::implExportLib( const OUString& aLibName, const OUString& aTargetURL,
const Reference< task::XInteractionHandler >& Handler )
{
- OUString aOULibName( aLibName );
Reference< script::XLibraryContainerExport > xModLibContainerExport
( m_aCurDocument.getLibraryContainer( E_SCRIPTS ), UNO_QUERY );
Reference< script::XLibraryContainerExport > xDlgLibContainerExport
( m_aCurDocument.getLibraryContainer( E_DIALOGS ), UNO_QUERY );
if ( xModLibContainerExport.is() )
- xModLibContainerExport->exportLibrary( aOULibName, aTargetURL, Handler );
+ xModLibContainerExport->exportLibrary( aLibName, aTargetURL, Handler );
if (!xDlgLibContainerExport.is())
return;
Reference<container::XNameAccess> xNameAcc(xDlgLibContainerExport, UNO_QUERY);
if (!xNameAcc.is())
return;
- if (!xNameAcc->hasByName(aOULibName))
+ if (!xNameAcc->hasByName(aLibName))
return;
- xDlgLibContainerExport->exportLibrary(aOULibName, aTargetURL, Handler);
+ xDlgLibContainerExport->exportLibrary(aLibName, aTargetURL, Handler);
}
// Implementation XCommandEnvironment
@@ -1342,11 +1339,10 @@ void LibPage::DeleteCurrent()
// check, if library is link
bool bIsLibraryLink = false;
- OUString aOULibName( aLibName );
Reference< script::XLibraryContainer2 > xModLibContainer( m_aCurDocument.getLibraryContainer( E_SCRIPTS ), UNO_QUERY );
Reference< script::XLibraryContainer2 > xDlgLibContainer( m_aCurDocument.getLibraryContainer( E_DIALOGS ), UNO_QUERY );
- if ( ( xModLibContainer.is() && xModLibContainer->hasByName( aOULibName ) && xModLibContainer->isLibraryLink( aOULibName ) ) ||
- ( xDlgLibContainer.is() && xDlgLibContainer->hasByName( aOULibName ) && xDlgLibContainer->isLibraryLink( aOULibName ) ) )
+ if ( ( xModLibContainer.is() && xModLibContainer->hasByName( aLibName ) && xModLibContainer->isLibraryLink( aLibName ) ) ||
+ ( xDlgLibContainer.is() && xDlgLibContainer->hasByName( aLibName ) && xDlgLibContainer->isLibraryLink( aLibName ) ) )
{
bIsLibraryLink = true;
}
@@ -1361,10 +1357,10 @@ void LibPage::DeleteCurrent()
SfxCallMode::SYNCHRON, { &aDocItem, &aLibNameItem });
// remove library from module and dialog library containers
- if ( xModLibContainer.is() && xModLibContainer->hasByName( aOULibName ) )
- xModLibContainer->removeLibrary( aOULibName );
- if ( xDlgLibContainer.is() && xDlgLibContainer->hasByName( aOULibName ) )
- xDlgLibContainer->removeLibrary( aOULibName );
+ if ( xModLibContainer.is() && xModLibContainer->hasByName( aLibName ) )
+ xModLibContainer->removeLibrary( aLibName );
+ if ( xDlgLibContainer.is() && xDlgLibContainer->hasByName( aLibName ) )
+ xDlgLibContainer->removeLibrary( aLibName );
static_cast<SvTreeListBox&>(*m_pLibBox).GetModel()->Remove( pCurEntry );
MarkDocumentModified( m_aCurDocument );
@@ -1442,14 +1438,13 @@ SvTreeListEntry* LibPage::ImpInsertLibEntry( const OUString& rLibName, sal_uLong
{
// check, if library is password protected
bool bProtected = false;
- OUString aOULibName( rLibName );
Reference< script::XLibraryContainer2 > xModLibContainer( m_aCurDocument.getLibraryContainer( E_SCRIPTS ), UNO_QUERY );
- if ( xModLibContainer.is() && xModLibContainer->hasByName( aOULibName ) )
+ if ( xModLibContainer.is() && xModLibContainer->hasByName( rLibName ) )
{
Reference< script::XLibraryContainerPassword > xPasswd( xModLibContainer, UNO_QUERY );
if ( xPasswd.is() )
{
- bProtected = xPasswd->isLibraryPasswordProtected( aOULibName );
+ bProtected = xPasswd->isLibraryPasswordProtected( rLibName );
}
}
@@ -1464,9 +1459,9 @@ SvTreeListEntry* LibPage::ImpInsertLibEntry( const OUString& rLibName, sal_uLong
}
// check, if library is link
- if ( xModLibContainer.is() && xModLibContainer->hasByName( aOULibName ) && xModLibContainer->isLibraryLink( aOULibName ) )
+ if ( xModLibContainer.is() && xModLibContainer->hasByName( rLibName ) && xModLibContainer->isLibraryLink( rLibName ) )
{
- OUString aLinkURL = xModLibContainer->getLibraryLinkURL( aOULibName );
+ OUString aLinkURL = xModLibContainer->getLibraryLinkURL( rLibName );
m_pLibBox->SetEntryText( aLinkURL, pNewEntry, 1 );
}
diff --git a/basctl/source/dlged/dlged.cxx b/basctl/source/dlged/dlged.cxx
index 5ecdd24..af96640 100644
--- a/basctl/source/dlged/dlged.cxx
+++ b/basctl/source/dlged/dlged.cxx
@@ -345,7 +345,7 @@ void DlgEditor::UpdateScrollBars()
}
-void DlgEditor::SetDialog( uno::Reference< container::XNameContainer > xUnoControlDialogModel )
+void DlgEditor::SetDialog( const uno::Reference< container::XNameContainer >& xUnoControlDialogModel )
{
// set dialog model
m_xUnoControlDialogModel = xUnoControlDialogModel;
@@ -645,7 +645,7 @@ void DlgEditor::Cut()
}
-void implCopyStreamToByteSequence( Reference< XInputStream > xStream,
+void implCopyStreamToByteSequence( const Reference< XInputStream >& xStream,
Sequence< sal_Int8 >& bytes )
{
xStream->readBytes( bytes, xStream->available() );
diff --git a/basctl/source/inc/dlged.hxx b/basctl/source/inc/dlged.hxx
index 958aa1d..ba1427a 100644
--- a/basctl/source/inc/dlged.hxx
+++ b/basctl/source/inc/dlged.hxx
@@ -159,7 +159,7 @@ public:
void DoScroll( ScrollBar* pActScroll );
void UpdateScrollBars();
- void SetDialog (css::uno::Reference<css::container::XNameContainer> xUnoControlDialogModel);
+ void SetDialog (const css::uno::Reference<css::container::XNameContainer>& xUnoControlDialogModel);
void ResetDialog ();
css::uno::Reference< css::container::XNameContainer > GetDialog() const
{return m_xUnoControlDialogModel;}
diff --git a/basctl/source/inc/localizationmgr.hxx b/basctl/source/inc/localizationmgr.hxx
index 9bf2710..ed1e6c7 100644
--- a/basctl/source/inc/localizationmgr.hxx
+++ b/basctl/source/inc/localizationmgr.hxx
@@ -54,8 +54,8 @@ class LocalizationMgr
static sal_Int32 implHandleControlResourceProperties(const css::uno::Any& rControlAny,
const OUString& aDialogName,
const OUString& aCtrlName,
- css::uno::Reference< css::resource::XStringResourceManager > xStringResourceManager,
- css::uno::Reference< css::resource::XStringResourceResolver > xSourceStringResolver,
+ const css::uno::Reference< css::resource::XStringResourceManager >& xStringResourceManager,
+ const css::uno::Reference< css::resource::XStringResourceResolver >& xSourceStringResolver,
HandleResourceMode eMode );
void enableResourceForAllLibraryDialogs()
@@ -105,36 +105,35 @@ public:
const css::uno::Any& rControlAny, const OUString& aCtrlName);
static void setStringResourceAtDialog( const ScriptDocument& rDocument, const OUString& aLibName, const OUString& aDlgName,
- css::uno::Reference< css::container::XNameContainer > xDialogModel );
+ const css::uno::Reference< css::container::XNameContainer >& xDialogModel );
static void renameStringResourceIDs( const ScriptDocument& rDocument, const OUString& aLibName, const OUString& aDlgName,
- css::uno::Reference< css::container::XNameContainer > xDialogModel );
+ const css::uno::Reference< css::container::XNameContainer >& xDialogModel );
static void removeResourceForDialog( const ScriptDocument& rDocument, const OUString& aLibName, const OUString& aDlgName,
- css::uno::Reference< css::container::XNameContainer > xDialogModel );
+ const css::uno::Reference< css::container::XNameContainer >& xDialogModel );
static css::uno::Reference< css::resource::XStringResourceManager >
- getStringResourceFromDialogLibrary( css::uno::Reference
- < css::container::XNameContainer > xDialogLib );
+ getStringResourceFromDialogLibrary( const css::uno::Reference< css::container::XNameContainer >& xDialogLib );
// Clipboard / Drag & Drop
static void resetResourceForDialog(
- css::uno::Reference< css::container::XNameContainer > xDialogModel,
- css::uno::Reference< css::resource::XStringResourceManager > xStringResourceManager );
+ const css::uno::Reference< css::container::XNameContainer >& xDialogModel,
+ const css::uno::Reference< css::resource::XStringResourceManager >& xStringResourceManager );
static void setResourceIDsForDialog(
- css::uno::Reference< css::container::XNameContainer > xDialogModel,
- css::uno::Reference< css::resource::XStringResourceManager > xStringResourceManager );
+ const css::uno::Reference< css::container::XNameContainer >& xDialogModel,
+ const css::uno::Reference< css::resource::XStringResourceManager >& xStringResourceManager );
static void copyResourcesForPastedEditorObject( DlgEditor* pEditor,
const css::uno::Any& rControlAny, const OUString& aCtrlName,
- css::uno::Reference< css::resource::XStringResourceResolver > xSourceStringResolver );
+ const css::uno::Reference< css::resource::XStringResourceResolver >& xSourceStringResolver );
static void copyResourceForDroppedDialog(
- css::uno::Reference< css::container::XNameContainer > xDialogModel,
+ const css::uno::Reference< css::container::XNameContainer >& xDialogModel,
const OUString& aDialogName,
- css::uno::Reference< css::resource::XStringResourceManager > xStringResourceManager,
- css::uno::Reference< css::resource::XStringResourceResolver > xSourceStringResolver );
+ const css::uno::Reference< css::resource::XStringResourceManager >& xStringResourceManager,
+ const css::uno::Reference< css::resource::XStringResourceResolver >& xSourceStringResolver );
static void copyResourceForDialog(
const css::uno::Reference< css::container::XNameContainer >& xDialogModel,
commit f045c536db5bdeacd36c075d3428e1a644bbc348
Author: Noel Grandin <noel at peralex.com>
Date: Tue Apr 12 11:56:07 2016 +0200
clang-tidy performance-unnecessary-value-param in framework
Change-Id: I80987ea1bfac7478574de46ee30fc58fcc17eb68
diff --git a/framework/inc/classes/actiontriggerpropertyset.hxx b/framework/inc/classes/actiontriggerpropertyset.hxx
index 0b90142..a1cddc6 100644
--- a/framework/inc/classes/actiontriggerpropertyset.hxx
+++ b/framework/inc/classes/actiontriggerpropertyset.hxx
@@ -94,13 +94,13 @@ class ActionTriggerPropertySet : private cppu::BaseMutex,
css::uno::Any& aOldValue ,
css::uno::Any& aConvertedValue ) throw( css::lang::IllegalArgumentException );
- bool impl_tryToChangeProperty( const css::uno::Reference< css::awt::XBitmap > xBitmap,
- const css::uno::Any& aNewValue ,
+ bool impl_tryToChangeProperty( const css::uno::Reference< css::awt::XBitmap >& xBitmap,
+ const css::uno::Any& aNewValue ,
css::uno::Any& aOldValue ,
css::uno::Any& aConvertedValue ) throw( css::lang::IllegalArgumentException );
- bool impl_tryToChangeProperty( const css::uno::Reference< css::uno::XInterface > xInterface,
- const css::uno::Any& aNewValue ,
+ bool impl_tryToChangeProperty( const css::uno::Reference< css::uno::XInterface >& xInterface,
+ const css::uno::Any& aNewValue ,
css::uno::Any& aOldValue ,
css::uno::Any& aConvertedValue ) throw( css::lang::IllegalArgumentException );
diff --git a/framework/inc/dispatch/dispatchprovider.hxx b/framework/inc/dispatch/dispatchprovider.hxx
index dee2bdb..945fbaa 100644
--- a/framework/inc/dispatch/dispatchprovider.hxx
+++ b/framework/inc/dispatch/dispatchprovider.hxx
@@ -103,12 +103,12 @@ class DispatchProvider: public ::cppu::WeakImplHelper< css::frame::XDispatchProv
const css::uno::Reference< css::frame::XFrame >& xOwner ,
const OUString& sTarget = OUString() ,
sal_Int32 nSearchFlags = 0 );
- bool implts_isLoadableContent ( const css::util::URL& aURL );
- css::uno::Reference< css::frame::XDispatch > implts_queryDesktopDispatch ( const css::uno::Reference< css::frame::XFrame > xDesktop ,
+ bool implts_isLoadableContent ( const css::util::URL& aURL );
+ css::uno::Reference< css::frame::XDispatch > implts_queryDesktopDispatch ( const css::uno::Reference< css::frame::XFrame >& xDesktop ,
const css::util::URL& aURL ,
const OUString& sTargetFrameName ,
sal_Int32 nSearchFlags );
- css::uno::Reference< css::frame::XDispatch > implts_queryFrameDispatch ( const css::uno::Reference< css::frame::XFrame > xFrame ,
+ css::uno::Reference< css::frame::XDispatch > implts_queryFrameDispatch ( const css::uno::Reference< css::frame::XFrame >& xFrame ,
const css::util::URL& aURL ,
const OUString& sTargetFrameName ,
sal_Int32 nSearchFlags );
diff --git a/framework/inc/recording/dispatchrecorder.hxx b/framework/inc/recording/dispatchrecorder.hxx
index 738a061..a03f6f1 100644
--- a/framework/inc/recording/dispatchrecorder.hxx
+++ b/framework/inc/recording/dispatchrecorder.hxx
@@ -86,7 +86,7 @@ class DispatchRecorder
void SAL_CALL implts_recordMacro( const OUString& aURL,
const css::uno::Sequence< css::beans::PropertyValue >& lArguments,
bool bAsComment, OUStringBuffer& );
- void SAL_CALL AppendToBuffer( css::uno::Any aValue, OUStringBuffer& aArgumentBuffer );
+ void SAL_CALL AppendToBuffer( const css::uno::Any& aValue, OUStringBuffer& aArgumentBuffer );
}; // class DispatcRecorder
diff --git a/framework/inc/uielement/toolbarmanager.hxx b/framework/inc/uielement/toolbarmanager.hxx
index be165b4..41e2539 100644
--- a/framework/inc/uielement/toolbarmanager.hxx
+++ b/framework/inc/uielement/toolbarmanager.hxx
@@ -138,7 +138,7 @@ class ToolBarManager : public ToolbarManager_Base
void CreateControllers();
void UpdateControllers();
//for update controller via Support Visiable
- void UpdateController( css::uno::Reference< css::frame::XToolbarController > xController);
+ void UpdateController( const css::uno::Reference< css::frame::XToolbarController >& xController);
//end
void AddFrameActionListener();
void ImplClearPopupMenu( ToolBox *pToolBar );
diff --git a/framework/source/dispatch/dispatchprovider.cxx b/framework/source/dispatch/dispatchprovider.cxx
index e9662cc..28ab6e4 100644
--- a/framework/source/dispatch/dispatchprovider.cxx
+++ b/framework/source/dispatch/dispatchprovider.cxx
@@ -158,7 +158,7 @@ bool lcl_isStartModuleDispatch (const css::util::URL& aURL)
@threadsafe yes
*/
-css::uno::Reference< css::frame::XDispatch > DispatchProvider::implts_queryDesktopDispatch( const css::uno::Reference< css::frame::XFrame > xDesktop ,
+css::uno::Reference< css::frame::XDispatch > DispatchProvider::implts_queryDesktopDispatch( const css::uno::Reference< css::frame::XFrame >& xDesktop ,
const css::util::URL& aURL ,
const OUString& sTargetFrameName ,
sal_Int32 nSearchFlags )
@@ -241,7 +241,7 @@ css::uno::Reference< css::frame::XDispatch > DispatchProvider::implts_queryDeskt
return xDispatcher;
}
-css::uno::Reference< css::frame::XDispatch > DispatchProvider::implts_queryFrameDispatch( const css::uno::Reference< css::frame::XFrame > xFrame ,
+css::uno::Reference< css::frame::XDispatch > DispatchProvider::implts_queryFrameDispatch( const css::uno::Reference< css::frame::XFrame >& xFrame ,
const css::util::URL& aURL ,
const OUString& sTargetFrameName ,
sal_Int32 nSearchFlags )
diff --git a/framework/source/fwe/classes/actiontriggerpropertyset.cxx b/framework/source/fwe/classes/actiontriggerpropertyset.cxx
index 969bab6..fb217fd 100644
--- a/framework/source/fwe/classes/actiontriggerpropertyset.cxx
+++ b/framework/source/fwe/classes/actiontriggerpropertyset.cxx
@@ -357,7 +357,7 @@ throw( IllegalArgumentException )
}
bool ActionTriggerPropertySet::impl_tryToChangeProperty(
- const Reference< XBitmap > aCurrentValue ,
+ const Reference< XBitmap >& aCurrentValue ,
const Any& aNewValue ,
Any& aOldValue ,
Any& aConvertedValue )
@@ -392,7 +392,7 @@ throw( IllegalArgumentException )
}
bool ActionTriggerPropertySet::impl_tryToChangeProperty(
- const Reference< XInterface > aCurrentValue ,
+ const Reference< XInterface >& aCurrentValue ,
const Any& aNewValue ,
Any& aOldValue ,
Any& aConvertedValue )
diff --git a/framework/source/fwe/helper/actiontriggerhelper.cxx b/framework/source/fwe/helper/actiontriggerhelper.cxx
index 2bb7593..3749606 100644
--- a/framework/source/fwe/helper/actiontriggerhelper.cxx
+++ b/framework/source/fwe/helper/actiontriggerhelper.cxx
@@ -45,7 +45,7 @@ namespace framework
// implementation helper ( menu => ActionTrigger )
-bool IsSeparator( Reference< XPropertySet > xPropertySet )
+bool IsSeparator( const Reference< XPropertySet >& xPropertySet )
{
Reference< XServiceInfo > xServiceInfo( xPropertySet, UNO_QUERY );
try
@@ -59,7 +59,7 @@ bool IsSeparator( Reference< XPropertySet > xPropertySet )
return false;
}
-void GetMenuItemAttributes( Reference< XPropertySet > xActionTriggerPropertySet,
+void GetMenuItemAttributes( const Reference< XPropertySet >& xActionTriggerPropertySet,
OUString& aMenuLabel,
OUString& aCommandURL,
OUString& aHelpURL,
@@ -95,7 +95,7 @@ void GetMenuItemAttributes( Reference< XPropertySet > xActionTriggerPropertySet,
}
}
-void InsertSubMenuItems( Menu* pSubMenu, sal_uInt16& nItemId, Reference< XIndexContainer > xActionTriggerContainer )
+void InsertSubMenuItems( Menu* pSubMenu, sal_uInt16& nItemId, const Reference< XIndexContainer >& xActionTriggerContainer )
{
if ( xActionTriggerContainer.is() )
{
diff --git a/framework/source/recording/dispatchrecorder.cxx b/framework/source/recording/dispatchrecorder.cxx
index e15621d..78c7317 100644
--- a/framework/source/recording/dispatchrecorder.cxx
+++ b/framework/source/recording/dispatchrecorder.cxx
@@ -157,7 +157,7 @@ OUString SAL_CALL DispatchRecorder::getRecordedMacro() throw( css::uno::RuntimeE
return sScript;
}
-void SAL_CALL DispatchRecorder::AppendToBuffer( css::uno::Any aValue, OUStringBuffer& aArgumentBuffer )
+void SAL_CALL DispatchRecorder::AppendToBuffer( const css::uno::Any& aValue, OUStringBuffer& aArgumentBuffer )
{
// if value == bool
if (aValue.getValueTypeClass() == css::uno::TypeClass_STRUCT )
diff --git a/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx b/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx
index 1baca80..8764e6a 100644
--- a/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx
+++ b/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx
@@ -195,7 +195,7 @@ private:
void impl_preloadUIElementTypeList( Layer eLayer, sal_Int16 nElementType );
UIElementData* impl_findUIElementData( const OUString& aResourceURL, sal_Int16 nElementType, bool bLoad = true );
void impl_requestUIElementData( sal_Int16 nElementType, Layer eLayer, UIElementData& aUIElementData );
- void impl_storeElementTypeData( css::uno::Reference< css::embed::XStorage > xStorage, UIElementType& rElementType, bool bResetModifyState = true );
+ void impl_storeElementTypeData( const css::uno::Reference< css::embed::XStorage >& xStorage, UIElementType& rElementType, bool bResetModifyState = true );
void impl_resetElementTypeData( UIElementType& rUserElementType, UIElementType& rDefaultElementType, ConfigEventNotifyContainer& rRemoveNotifyContainer, ConfigEventNotifyContainer& rReplaceNotifyContainer );
void impl_reloadElementTypeData( UIElementType& rUserElementType, UIElementType& rDefaultElementType, ConfigEventNotifyContainer& rRemoveNotifyContainer, ConfigEventNotifyContainer& rReplaceNotifyContainer );
@@ -541,7 +541,7 @@ ModuleUIConfigurationManager::UIElementData* ModuleUIConfigurationManager::impl
return nullptr;
}
-void ModuleUIConfigurationManager::impl_storeElementTypeData( Reference< XStorage > xStorage, UIElementType& rElementType, bool bResetModifyState )
+void ModuleUIConfigurationManager::impl_storeElementTypeData( const Reference< XStorage >& xStorage, UIElementType& rElementType, bool bResetModifyState )
{
UIElementDataHashMap& rHashMap = rElementType.aElementsHashMap;
UIElementDataHashMap::iterator pIter = rHashMap.begin();
diff --git a/framework/source/uielement/toolbarmanager.cxx b/framework/source/uielement/toolbarmanager.cxx
index 1b79d3d..7c324fe 100644
--- a/framework/source/uielement/toolbarmanager.cxx
+++ b/framework/source/uielement/toolbarmanager.cxx
@@ -347,7 +347,7 @@ void ToolBarManager::UpdateControllers()
}
//for update toolbar controller via Support Visible
-void ToolBarManager::UpdateController( css::uno::Reference< css::frame::XToolbarController > xController)
+void ToolBarManager::UpdateController( const css::uno::Reference< css::frame::XToolbarController >& xController)
{
if ( !m_bUpdateControllers )
commit 230cd638676fc5adf7e3fe5e69d29eadb194d7f8
Author: Noel Grandin <noel at peralex.com>
Date: Tue Apr 12 11:55:28 2016 +0200
clang-tidy performance-unnecessary-value-param in starmath
Change-Id: Ic8d319dac1d18f548d47ac84e489c04412a38d1a
diff --git a/starmath/inc/document.hxx b/starmath/inc/document.hxx
index e761604..1eb676c 100644
--- a/starmath/inc/document.hxx
+++ b/starmath/inc/document.hxx
@@ -141,7 +141,7 @@ class SM_DLLPUBLIC SmDocShell : public SfxObjectShell, public SfxListener
*/
void InvalidateCursor();
- bool writeFormulaOoxml(::sax_fastparser::FSHelperPtr pSerializer,
+ bool writeFormulaOoxml(const ::sax_fastparser::FSHelperPtr& pSerializer,
oox::core::OoxmlVersion version,
oox::drawingml::DocumentType documentType);
void writeFormulaRtf(OStringBuffer& rBuffer, rtl_TextEncoding nEncoding);
diff --git a/starmath/source/document.cxx b/starmath/source/document.cxx
index 9cb102e..ebe552a 100644
--- a/starmath/source/document.cxx
+++ b/starmath/source/document.cxx
@@ -888,7 +888,7 @@ bool SmDocShell::ConvertTo( SfxMedium &rMedium )
}
bool SmDocShell::writeFormulaOoxml(
- ::sax_fastparser::FSHelperPtr const pSerializer,
+ ::sax_fastparser::FSHelperPtr const& pSerializer,
oox::core::OoxmlVersion const version,
oox::drawingml::DocumentType const documentType)
{
diff --git a/starmath/source/mathmlexport.cxx b/starmath/source/mathmlexport.cxx
index aa94160..3bb91d9 100644
--- a/starmath/source/mathmlexport.cxx
+++ b/starmath/source/mathmlexport.cxx
@@ -251,8 +251,8 @@ bool SmXMLExportWrapper::Export(SfxMedium &rMedium)
/// export through an XML exporter component (output stream version)
bool SmXMLExportWrapper::WriteThroughComponent(
- Reference<io::XOutputStream> xOutputStream,
- Reference<XComponent> xComponent,
+ const Reference<io::XOutputStream>& xOutputStream,
+ const Reference<XComponent>& xComponent,
Reference<uno::XComponentContext> & rxContext,
Reference<beans::XPropertySet> & rPropSet,
const sal_Char* pComponentName )
@@ -303,7 +303,7 @@ bool SmXMLExportWrapper::WriteThroughComponent(
/// export through an XML exporter component (storage version)
bool SmXMLExportWrapper::WriteThroughComponent(
const Reference < embed::XStorage >& xStorage,
- Reference<XComponent> xComponent,
+ const Reference<XComponent>& xComponent,
const sal_Char* pStreamName,
Reference<uno::XComponentContext> & rxContext,
Reference<beans::XPropertySet> & rPropSet,
diff --git a/starmath/source/mathmlexport.hxx b/starmath/source/mathmlexport.hxx
index 7c11d66..2a58f57 100644
--- a/starmath/source/mathmlexport.hxx
+++ b/starmath/source/mathmlexport.hxx
@@ -49,15 +49,15 @@ public:
void SetFlat(bool bIn) {bFlat = bIn;}
static bool WriteThroughComponent(
- css::uno::Reference< css::io::XOutputStream > xOutputStream,
- css::uno::Reference< css::lang::XComponent > xComponent,
+ const css::uno::Reference< css::io::XOutputStream >& xOutputStream,
+ const css::uno::Reference< css::lang::XComponent >& xComponent,
css::uno::Reference< css::uno::XComponentContext > & rxContext,
css::uno::Reference< css::beans::XPropertySet > & rPropSet,
const sal_Char* pComponentName );
static bool WriteThroughComponent(
const css::uno::Reference< css::embed::XStorage >& xStor,
- css::uno::Reference< css::lang::XComponent > xComponent,
+ const css::uno::Reference< css::lang::XComponent >& xComponent,
const sal_Char* pStreamName,
css::uno::Reference< css::uno::XComponentContext > & rxContext,
css::uno::Reference< css::beans::XPropertySet > & rPropSet,
diff --git a/starmath/source/mathmlimport.cxx b/starmath/source/mathmlimport.cxx
index 81a10df..fe76543 100644
--- a/starmath/source/mathmlimport.cxx
+++ b/starmath/source/mathmlimport.cxx
@@ -237,8 +237,8 @@ sal_uLong SmXMLImportWrapper::Import(SfxMedium &rMedium)
/// read a component (file + filter version)
sal_uLong SmXMLImportWrapper::ReadThroughComponent(
- Reference<io::XInputStream> xInputStream,
- Reference<XComponent> xModelComponent,
+ const Reference<io::XInputStream>& xInputStream,
+ const Reference<XComponent>& xModelComponent,
Reference<uno::XComponentContext> & rxContext,
Reference<beans::XPropertySet> & rPropSet,
const sal_Char* pFilterName,
@@ -334,7 +334,7 @@ sal_uLong SmXMLImportWrapper::ReadThroughComponent(
sal_uLong SmXMLImportWrapper::ReadThroughComponent(
const uno::Reference< embed::XStorage >& xStorage,
- Reference<XComponent> xModelComponent,
+ const Reference<XComponent>& xModelComponent,
const sal_Char* pStreamName,
const sal_Char* pCompatibilityStreamName,
Reference<uno::XComponentContext> & rxContext,
diff --git a/starmath/source/mathmlimport.hxx b/starmath/source/mathmlimport.hxx
index bef17d2..7c26518 100644
--- a/starmath/source/mathmlimport.hxx
+++ b/starmath/source/mathmlimport.hxx
@@ -48,8 +48,8 @@ public:
sal_uLong Import(SfxMedium &rMedium);
static sal_uLong ReadThroughComponent(
- css::uno::Reference< css::io::XInputStream > xInputStream,
- css::uno::Reference< css::lang::XComponent > xModelComponent,
+ const css::uno::Reference< css::io::XInputStream >& xInputStream,
+ const css::uno::Reference< css::lang::XComponent >& xModelComponent,
css::uno::Reference< css::uno::XComponentContext > & rxContext,
css::uno::Reference< css::beans::XPropertySet > & rPropSet,
const sal_Char* pFilterName,
@@ -57,7 +57,7 @@ public:
static sal_uLong ReadThroughComponent(
const css::uno::Reference< css::embed::XStorage >& xStorage,
- css::uno::Reference< css::lang::XComponent > xModelComponent,
+ const css::uno::Reference< css::lang::XComponent >& xModelComponent,
const sal_Char* pStreamName,
const sal_Char* pCompatibilityStreamName,
css::uno::Reference< css::uno::XComponentContext > & rxContext,
diff --git a/starmath/source/ooxmlexport.cxx b/starmath/source/ooxmlexport.cxx
index 63f7cd4..911ab81 100644
--- a/starmath/source/ooxmlexport.cxx
+++ b/starmath/source/ooxmlexport.cxx
@@ -24,7 +24,7 @@ SmOoxmlExport::SmOoxmlExport(const SmNode *const pIn, OoxmlVersion const v,
{
}
-bool SmOoxmlExport::ConvertFromStarMath( ::sax_fastparser::FSHelperPtr serializer )
+bool SmOoxmlExport::ConvertFromStarMath( const ::sax_fastparser::FSHelperPtr& serializer )
{
if( m_pTree == nullptr )
return false;
diff --git a/starmath/source/ooxmlexport.hxx b/starmath/source/ooxmlexport.hxx
index 5bd69bf..5899a49 100644
--- a/starmath/source/ooxmlexport.hxx
+++ b/starmath/source/ooxmlexport.hxx
@@ -24,7 +24,7 @@ class SmOoxmlExport : public SmWordExportBase
public:
SmOoxmlExport(const SmNode* pIn, oox::core::OoxmlVersion version,
oox::drawingml::DocumentType documentType);
- bool ConvertFromStarMath( ::sax_fastparser::FSHelperPtr m_pSerializer );
+ bool ConvertFromStarMath( const ::sax_fastparser::FSHelperPtr& m_pSerializer );
private:
virtual void HandleVerticalStack( const SmNode* pNode, int nLevel ) override;
virtual void HandleText( const SmNode* pNode, int nLevel ) override;
commit 9649026cf50533595c172cd81b96acd45603d86b
Author: Noel Grandin <noel at peralex.com>
Date: Tue Apr 12 11:54:45 2016 +0200
clang-tidy performance-unnecessary-value-param in sd
Change-Id: Id55410931305a9695a001977a5227b430a984e99
diff --git a/sd/inc/CustomAnimationEffect.hxx b/sd/inc/CustomAnimationEffect.hxx
index a8dcbe5..507bd9f 100644
--- a/sd/inc/CustomAnimationEffect.hxx
+++ b/sd/inc/CustomAnimationEffect.hxx
@@ -206,7 +206,7 @@ private:
struct stl_CustomAnimationEffect_search_node_predict
{
stl_CustomAnimationEffect_search_node_predict( const css::uno::Reference< css::animations::XAnimationNode >& xSearchNode );
- bool operator()( CustomAnimationEffectPtr pEffect ) const;
+ bool operator()( const CustomAnimationEffectPtr& pEffect ) const;
const css::uno::Reference< css::animations::XAnimationNode >& mxSearchNode;
};
@@ -310,10 +310,10 @@ public:
SAL_DLLPRIVATE CustomAnimationTextGroupPtr findGroup( sal_Int32 nGroupId );
CustomAnimationTextGroupPtr createTextGroup( CustomAnimationEffectPtr pEffect, sal_Int32 nTextGrouping, double fTextGroupingAuto, bool bAnimateForm, bool bTextReverse );
- SAL_DLLPRIVATE void setTextGrouping( CustomAnimationTextGroupPtr pTextGroup, sal_Int32 nTextGrouping );
- SAL_DLLPRIVATE void setAnimateForm( CustomAnimationTextGroupPtr pTextGroup, bool bAnimateForm );
- SAL_DLLPRIVATE void setTextGroupingAuto( CustomAnimationTextGroupPtr pTextGroup, double fTextGroupingAuto );
- SAL_DLLPRIVATE void setTextReverse( CustomAnimationTextGroupPtr pTextGroup, bool bAnimateForm );
+ SAL_DLLPRIVATE void setTextGrouping( const CustomAnimationTextGroupPtr& pTextGroup, sal_Int32 nTextGrouping );
+ SAL_DLLPRIVATE void setAnimateForm( const CustomAnimationTextGroupPtr& pTextGroup, bool bAnimateForm );
+ SAL_DLLPRIVATE void setTextGroupingAuto( const CustomAnimationTextGroupPtr& pTextGroup, double fTextGroupingAuto );
+ SAL_DLLPRIVATE void setTextReverse( const CustomAnimationTextGroupPtr& pTextGroup, bool bAnimateForm );
SAL_DLLPRIVATE sal_Int32 getSequenceType() const { return mnSequenceType; }
@@ -327,7 +327,7 @@ protected:
SAL_DLLPRIVATE virtual void implRebuild();
SAL_DLLPRIVATE virtual void reset();
- SAL_DLLPRIVATE void createTextGroupParagraphEffects( CustomAnimationTextGroupPtr pTextGroup, CustomAnimationEffectPtr pEffect, bool bUsed );
+ SAL_DLLPRIVATE void createTextGroupParagraphEffects( const CustomAnimationTextGroupPtr& pTextGroup, const CustomAnimationEffectPtr& pEffect, bool bUsed );
SAL_DLLPRIVATE void notify_listeners();
diff --git a/sd/inc/CustomAnimationPreset.hxx b/sd/inc/CustomAnimationPreset.hxx
index 8c8ef2f..bd3da58 100644
--- a/sd/inc/CustomAnimationPreset.hxx
+++ b/sd/inc/CustomAnimationPreset.hxx
@@ -45,7 +45,7 @@ class CustomAnimationPreset
public:
CustomAnimationPreset( CustomAnimationEffectPtr pEffect );
- void add( CustomAnimationEffectPtr pEffect );
+ void add( const CustomAnimationEffectPtr& pEffect );
SD_DLLPUBLIC css::uno::Reference< css::animations::XAnimationNode > create( const OUString& rstrSubType );
@@ -109,7 +109,7 @@ public:
SAL_DLLPRIVATE const PresetCategoryList& getMotionPathsPresets() const { return maMotionPathsPresets; }
SAL_DLLPRIVATE const PresetCategoryList& getMiscPresets() const { return maMiscPresets; }
- SAL_DLLPRIVATE void changePresetSubType( CustomAnimationEffectPtr pEffect, const OUString& rPresetSubType ) const;
+ SAL_DLLPRIVATE void changePresetSubType( const CustomAnimationEffectPtr& pEffect, const OUString& rPresetSubType ) const;
private:
SAL_DLLPRIVATE void importEffects();
diff --git a/sd/source/core/CustomAnimationEffect.cxx b/sd/source/core/CustomAnimationEffect.cxx
index 674f311..14c6590 100644
--- a/sd/source/core/CustomAnimationEffect.cxx
+++ b/sd/source/core/CustomAnimationEffect.cxx
@@ -1992,7 +1992,7 @@ stl_CustomAnimationEffect_search_node_predict::stl_CustomAnimationEffect_search_
{
}
-bool stl_CustomAnimationEffect_search_node_predict::operator()( CustomAnimationEffectPtr pEffect ) const
+bool stl_CustomAnimationEffect_search_node_predict::operator()( const CustomAnimationEffectPtr& pEffect ) const
{
return pEffect->getNode() == mxSearchNode;
}
@@ -2450,7 +2450,7 @@ CustomAnimationTextGroupPtr EffectSequenceHelper::createTextGroup( CustomAnimati
return pTextGroup;
}
-void EffectSequenceHelper::createTextGroupParagraphEffects( CustomAnimationTextGroupPtr pTextGroup, CustomAnimationEffectPtr pEffect, bool bUsed )
+void EffectSequenceHelper::createTextGroupParagraphEffects( const CustomAnimationTextGroupPtr& pTextGroup, const CustomAnimationEffectPtr& pEffect, bool bUsed )
{
Reference< XShape > xTarget( pTextGroup->maTarget );
@@ -2543,7 +2543,7 @@ void EffectSequenceHelper::createTextGroupParagraphEffects( CustomAnimationTextG
}
}
-void EffectSequenceHelper::setTextGrouping( CustomAnimationTextGroupPtr pTextGroup, sal_Int32 nTextGrouping )
+void EffectSequenceHelper::setTextGrouping( const CustomAnimationTextGroupPtr& pTextGroup, sal_Int32 nTextGrouping )
{
if( pTextGroup->mnTextGrouping == nTextGrouping )
{
@@ -2623,7 +2623,7 @@ void EffectSequenceHelper::setTextGrouping( CustomAnimationTextGroupPtr pTextGro
}
}
-void EffectSequenceHelper::setAnimateForm( CustomAnimationTextGroupPtr pTextGroup, bool bAnimateForm )
+void EffectSequenceHelper::setAnimateForm( const CustomAnimationTextGroupPtr& pTextGroup, bool bAnimateForm )
{
if( pTextGroup->mbAnimateForm == bAnimateForm )
{
@@ -2695,7 +2695,7 @@ void EffectSequenceHelper::setAnimateForm( CustomAnimationTextGroupPtr pTextGrou
}
}
-void EffectSequenceHelper::setTextGroupingAuto( CustomAnimationTextGroupPtr pTextGroup, double fTextGroupingAuto )
+void EffectSequenceHelper::setTextGroupingAuto( const CustomAnimationTextGroupPtr& pTextGroup, double fTextGroupingAuto )
{
sal_Int32 nTextGrouping = pTextGroup->mnTextGrouping;
@@ -2772,7 +2772,7 @@ bool ImplStlTextGroupSortHelper::operator()( const CustomAnimationEffectPtr& p1,
}
}
-void EffectSequenceHelper::setTextReverse( CustomAnimationTextGroupPtr pTextGroup, bool bTextReverse )
+void EffectSequenceHelper::setTextReverse( const CustomAnimationTextGroupPtr& pTextGroup, bool bTextReverse )
{
if( pTextGroup->mbTextReverse == bTextReverse )
{
diff --git a/sd/source/core/CustomAnimationPreset.cxx b/sd/source/core/CustomAnimationPreset.cxx
index 024684e..9f7bb73 100644
--- a/sd/source/core/CustomAnimationPreset.cxx
+++ b/sd/source/core/CustomAnimationPreset.cxx
@@ -150,7 +150,7 @@ CustomAnimationPreset::CustomAnimationPreset( CustomAnimationEffectPtr pEffect )
}
-void CustomAnimationPreset::add( CustomAnimationEffectPtr pEffect )
+void CustomAnimationPreset::add( const CustomAnimationEffectPtr& pEffect )
{
maSubTypes[ pEffect->getPresetSubType() ] = pEffect;
}
@@ -526,7 +526,7 @@ const OUString& CustomAnimationPresets::translateName( const OUString& rId, cons
return rId;
}
}
-void CustomAnimationPresets::changePresetSubType( CustomAnimationEffectPtr pEffect, const OUString& rPresetSubType ) const
+void CustomAnimationPresets::changePresetSubType( const CustomAnimationEffectPtr& pEffect, const OUString& rPresetSubType ) const
{
if( pEffect.get() && pEffect->getPresetSubType() != rPresetSubType )
{
diff --git a/sd/source/filter/eppt/eppt.cxx b/sd/source/filter/eppt/eppt.cxx
index 5d7da71..5605ba3 100644
--- a/sd/source/filter/eppt/eppt.cxx
+++ b/sd/source/filter/eppt/eppt.cxx
@@ -168,7 +168,7 @@ void PPTWriter::exportPPTPost( )
mbStatus = true;
};
-void ImplExportComments( uno::Reference< drawing::XDrawPage > xPage, SvMemoryStream& rBinaryTagData10Atom );
+void ImplExportComments( const uno::Reference< drawing::XDrawPage >& xPage, SvMemoryStream& rBinaryTagData10Atom );
void PPTWriter::ImplWriteSlide( sal_uInt32 nPageNum, sal_uInt32 nMasterNum, sal_uInt16 nMode,
bool bHasBackground, Reference< XPropertySet > aXBackgroundPropSet )
@@ -1074,7 +1074,7 @@ static OUString getInitials( const OUString& rName )
return sInitials;
}
-void ImplExportComments( uno::Reference< drawing::XDrawPage > xPage, SvMemoryStream& rBinaryTagData10Atom )
+void ImplExportComments( const uno::Reference< drawing::XDrawPage >& xPage, SvMemoryStream& rBinaryTagData10Atom )
{
try
{
diff --git a/sd/source/filter/eppt/epptooxml.hxx b/sd/source/filter/eppt/epptooxml.hxx
index db07494..d84cd66 100644
--- a/sd/source/filter/eppt/epptooxml.hxx
+++ b/sd/source/filter/eppt/epptooxml.hxx
@@ -99,28 +99,28 @@ protected:
virtual ::oox::ole::VbaProject* implCreateVbaProject() const override;
bool WriteNotesMaster();
- static void WriteAnimateTo( ::sax_fastparser::FSHelperPtr pFS, const css::uno::Any& rValue, const OUString& rAttributeName );
- static void WriteAnimateValues( ::sax_fastparser::FSHelperPtr pFS, const css::uno::Reference< css::animations::XAnimate >& rXAnimate );
- static void WriteAnimationCondition( ::sax_fastparser::FSHelperPtr pFS, css::uno::Any& rAny, bool bWriteEvent, bool bMainSeqChild );
- static void WriteAnimationCondition( ::sax_fastparser::FSHelperPtr pFS, const char* pDelay, const char* pEvent, double fDelay, bool bHasFDelay );
- void WriteAnimations( ::sax_fastparser::FSHelperPtr pFS );
- static void WriteAnimationAttributeName( ::sax_fastparser::FSHelperPtr pFS, const OUString& rAttributeName );
- void WriteAnimationNode( ::sax_fastparser::FSHelperPtr pFS, const css::uno::Reference< css::animations::XAnimationNode >& rXNode, bool bMainSeqChild );
- void WriteAnimationNodeAnimate( ::sax_fastparser::FSHelperPtr pFS, const css::uno::Reference< css::animations::XAnimationNode >& rXNode, sal_Int32 nXmlNodeType, bool bMainSeqChild );
- void WriteAnimationNodeAnimateInside( ::sax_fastparser::FSHelperPtr pFS, const css::uno::Reference< css::animations::XAnimationNode >& rXNode, bool bMainSeqChild, bool bSimple );
- void WriteAnimationNodeSeq( ::sax_fastparser::FSHelperPtr pFS, const css::uno::Reference< css::animations::XAnimationNode >& rXNode, sal_Int32 nXmlNodeType, bool bMainSeqChild );
- void WriteAnimationNodeEffect( ::sax_fastparser::FSHelperPtr pFS, const css::uno::Reference< css::animations::XAnimationNode >& rXNode, sal_Int32 nXmlNodeType, bool bMainSeqChild );
- void WriteAnimationNodeCommonPropsStart( ::sax_fastparser::FSHelperPtr pFS, const css::uno::Reference< css::animations::XAnimationNode >& rXNode, bool bSingle, bool bMainSeqChild );
- static void WriteAnimationProperty( ::sax_fastparser::FSHelperPtr pFS, const css::uno::Any& rAny );
- void WriteAnimationTarget( ::sax_fastparser::FSHelperPtr pFS, const css::uno::Any& rTarget );
+ static void WriteAnimateTo( const ::sax_fastparser::FSHelperPtr& pFS, const css::uno::Any& rValue, const OUString& rAttributeName );
+ static void WriteAnimateValues( const ::sax_fastparser::FSHelperPtr& pFS, const css::uno::Reference< css::animations::XAnimate >& rXAnimate );
+ static void WriteAnimationCondition( const ::sax_fastparser::FSHelperPtr& pFS, css::uno::Any& rAny, bool bWriteEvent, bool bMainSeqChild );
+ static void WriteAnimationCondition( const ::sax_fastparser::FSHelperPtr& pFS, const char* pDelay, const char* pEvent, double fDelay, bool bHasFDelay );
+ void WriteAnimations( const ::sax_fastparser::FSHelperPtr& pFS );
+ static void WriteAnimationAttributeName( const ::sax_fastparser::FSHelperPtr& pFS, const OUString& rAttributeName );
+ void WriteAnimationNode( const ::sax_fastparser::FSHelperPtr& pFS, const css::uno::Reference< css::animations::XAnimationNode >& rXNode, bool bMainSeqChild );
+ void WriteAnimationNodeAnimate( const ::sax_fastparser::FSHelperPtr& pFS, const css::uno::Reference< css::animations::XAnimationNode >& rXNode, sal_Int32 nXmlNodeType, bool bMainSeqChild );
+ void WriteAnimationNodeAnimateInside( const ::sax_fastparser::FSHelperPtr& pFS, const css::uno::Reference< css::animations::XAnimationNode >& rXNode, bool bMainSeqChild, bool bSimple );
+ void WriteAnimationNodeSeq( const ::sax_fastparser::FSHelperPtr& pFS, const css::uno::Reference< css::animations::XAnimationNode >& rXNode, sal_Int32 nXmlNodeType, bool bMainSeqChild );
+ void WriteAnimationNodeEffect( const ::sax_fastparser::FSHelperPtr& pFS, const css::uno::Reference< css::animations::XAnimationNode >& rXNode, sal_Int32 nXmlNodeType, bool bMainSeqChild );
+ void WriteAnimationNodeCommonPropsStart( const ::sax_fastparser::FSHelperPtr& pFS, const css::uno::Reference< css::animations::XAnimationNode >& rXNode, bool bSingle, bool bMainSeqChild );
+ static void WriteAnimationProperty( const ::sax_fastparser::FSHelperPtr& pFS, const css::uno::Any& rAny );
+ void WriteAnimationTarget( const ::sax_fastparser::FSHelperPtr& pFS, const css::uno::Any& rTarget );
bool WriteComments( sal_uInt32 nPageNum );
- void ImplWriteBackground( ::sax_fastparser::FSHelperPtr pFS, css::uno::Reference< css::beans::XPropertySet > aXBackgroundPropSet );
- void WriteTransition( ::sax_fastparser::FSHelperPtr pFS );
+ void ImplWriteBackground( const ::sax_fastparser::FSHelperPtr& pFS, const css::uno::Reference< css::beans::XPropertySet >& aXBackgroundPropSet );
+ void WriteTransition( const ::sax_fastparser::FSHelperPtr& pFS );
sal_Int32 GetLayoutFileId( sal_Int32 nOffset, sal_uInt32 nMasterNum );
// shapes
- void WriteShapeTree( ::sax_fastparser::FSHelperPtr pFS, PageType ePageType, bool bMaster );
+ void WriteShapeTree( const ::sax_fastparser::FSHelperPtr& pFS, PageType ePageType, bool bMaster );
sal_uInt32 GetNewSlideId() { return mnSlideIdMax ++; }
sal_uInt32 GetNewSlideMasterId() { return mnSlideMasterIdMax ++; }
@@ -130,7 +130,7 @@ private:
// Write docProps/core.xml and docprops/custom.xml and docprops/app.xml
void writeDocumentProperties();
- void AddLayoutIdAndRelation( ::sax_fastparser::FSHelperPtr pFS, sal_Int32 nLayoutFileId );
+ void AddLayoutIdAndRelation( const ::sax_fastparser::FSHelperPtr& pFS, sal_Int32 nLayoutFileId );
virtual OUString SAL_CALL getImplementationName() throw (css::uno::RuntimeException, std::exception) override;
diff --git a/sd/source/filter/eppt/pptx-epptooxml.cxx b/sd/source/filter/eppt/pptx-epptooxml.cxx
index fdd1d4e..0132e62 100644
--- a/sd/source/filter/eppt/pptx-epptooxml.cxx
+++ b/sd/source/filter/eppt/pptx-epptooxml.cxx
@@ -120,11 +120,11 @@ public:
ShapeExport& WriteNonVisualProperties( const Reference< XShape >& xShape ) override;
ShapeExport& WriteTextShape( const Reference< XShape >& xShape ) override;
ShapeExport& WriteUnknownShape( const Reference< XShape >& xShape ) override;
- ShapeExport& WritePlaceholderShape( Reference< XShape > xShape, PlaceholderType ePlaceholder );
- ShapeExport& WritePageShape( Reference< XShape > xShape, PageType ePageType, bool bPresObj );
+ ShapeExport& WritePlaceholderShape( const Reference< XShape >& xShape, PlaceholderType ePlaceholder );
+ ShapeExport& WritePageShape( const Reference< XShape >& xShape, PageType ePageType, bool bPresObj );
// helper parts
- bool WritePlaceholder( Reference< XShape > xShape, PlaceholderType ePlaceholder, bool bMaster );
+ bool WritePlaceholder( const Reference< XShape >& xShape, PlaceholderType ePlaceholder, bool bMaster );
};
enum PPTXLayout {
@@ -413,7 +413,7 @@ bool PowerPointExport::exportDocument() throw (css::uno::RuntimeException, std::
return new ::oox::ole::VbaProject( getComponentContext(), getModel(), "Impress" );
}
-void PowerPointExport::ImplWriteBackground( FSHelperPtr pFS, Reference< XPropertySet > rXPropSet )
+void PowerPointExport::ImplWriteBackground( const FSHelperPtr& pFS, const Reference< XPropertySet >& rXPropSet )
{
FillStyle aFillStyle( FillStyle_NONE );
if ( ImplGetPropertyValue( rXPropSet, "FillStyle" ) )
@@ -512,7 +512,7 @@ const char* PowerPointExport::Get8Direction( sal_uInt8 nDirection )
return pDirection;
}
-void PowerPointExport::WriteTransition( FSHelperPtr pFS )
+void PowerPointExport::WriteTransition( const FSHelperPtr& pFS )
{
FadeEffect eFadeEffect = FadeEffect_NONE;
GET( eFadeEffect, Effect );
@@ -801,7 +801,7 @@ void PowerPointExport::WriteTransition( FSHelperPtr pFS )
}
}
-void PowerPointExport::WriteAnimationProperty( FSHelperPtr pFS, const Any& rAny )
+void PowerPointExport::WriteAnimationProperty( const FSHelperPtr& pFS, const Any& rAny )
{
if( !rAny.hasValue() )
return;
@@ -817,7 +817,7 @@ void PowerPointExport::WriteAnimationProperty( FSHelperPtr pFS, const Any& rAny
}
}
-void PowerPointExport::WriteAnimateValues( FSHelperPtr pFS, const Reference< XAnimate >& rXAnimate )
+void PowerPointExport::WriteAnimateValues( const FSHelperPtr& pFS, const Reference< XAnimate >& rXAnimate )
{
const Sequence< double > aKeyTimes = rXAnimate->getKeyTimes();
if( aKeyTimes.getLength() <= 0 )
@@ -853,7 +853,7 @@ void PowerPointExport::WriteAnimateValues( FSHelperPtr pFS, const Reference< XAn
pFS->endElementNS( XML_p, XML_tavLst );
}
-void PowerPointExport::WriteAnimateTo( FSHelperPtr pFS, const Any& rValue, const OUString& rAttributeName )
+void PowerPointExport::WriteAnimateTo( const FSHelperPtr& pFS, const Any& rValue, const OUString& rAttributeName )
{
if( !rValue.hasValue() )
return;
@@ -867,7 +867,7 @@ void PowerPointExport::WriteAnimateTo( FSHelperPtr pFS, const Any& rValue, const
pFS->endElementNS( XML_p, XML_to );
}
-void PowerPointExport::WriteAnimationAttributeName( FSHelperPtr pFS, const OUString& rAttributeName )
+void PowerPointExport::WriteAnimationAttributeName( const FSHelperPtr& pFS, const OUString& rAttributeName )
{
if( rAttributeName.isEmpty() )
return;
@@ -892,7 +892,7 @@ void PowerPointExport::WriteAnimationAttributeName( FSHelperPtr pFS, const OUStr
pFS->endElementNS( XML_p, XML_attrNameLst );
}
-void PowerPointExport::WriteAnimationTarget( FSHelperPtr pFS, const Any& rTarget )
+void PowerPointExport::WriteAnimationTarget( const FSHelperPtr& pFS, const Any& rTarget )
{
sal_Int32 nBegin = -1, nEnd = -1;
bool bParagraphTarget;
@@ -916,7 +916,7 @@ void PowerPointExport::WriteAnimationTarget( FSHelperPtr pFS, const Any& rTarget
}
}
-void PowerPointExport::WriteAnimationNodeAnimate( FSHelperPtr pFS, const Reference< XAnimationNode >& rXNode, sal_Int32 nXmlNodeType, bool bMainSeqChild )
+void PowerPointExport::WriteAnimationNodeAnimate( const FSHelperPtr& pFS, const Reference< XAnimationNode >& rXNode, sal_Int32 nXmlNodeType, bool bMainSeqChild )
{
Reference< XAnimate > rXAnimate( rXNode, UNO_QUERY );
if( !rXAnimate.is() )
@@ -957,7 +957,7 @@ void PowerPointExport::WriteAnimationNodeAnimate( FSHelperPtr pFS, const Referen
pFS->endElementNS( XML_p, nXmlNodeType );
}
-void PowerPointExport::WriteAnimationNodeAnimateInside( FSHelperPtr pFS, const Reference< XAnimationNode >& rXNode, bool bMainSeqChild, bool bSimple )
+void PowerPointExport::WriteAnimationNodeAnimateInside( const FSHelperPtr& pFS, const Reference< XAnimationNode >& rXNode, bool bMainSeqChild, bool bSimple )
{
Reference< XAnimate > rXAnimate( rXNode, UNO_QUERY );
if( !rXAnimate.is() )
@@ -996,7 +996,7 @@ void PowerPointExport::WriteAnimationNodeAnimateInside( FSHelperPtr pFS, const R
WriteAnimateTo( pFS, rXAnimate->getTo(), rXAnimate->getAttributeName() );
}
-void PowerPointExport::WriteAnimationCondition( FSHelperPtr pFS, const char* pDelay, const char* pEvent, double fDelay, bool bHasFDelay )
+void PowerPointExport::WriteAnimationCondition( const FSHelperPtr& pFS, const char* pDelay, const char* pEvent, double fDelay, bool bHasFDelay )
{
if( bHasFDelay || pDelay || pEvent ) {
if( !pEvent )
@@ -1018,7 +1018,7 @@ void PowerPointExport::WriteAnimationCondition( FSHelperPtr pFS, const char* pDe
}
}
-void PowerPointExport::WriteAnimationCondition( FSHelperPtr pFS, Any& rAny, bool bWriteEvent, bool bMainSeqChild )
+void PowerPointExport::WriteAnimationCondition( const FSHelperPtr& pFS, Any& rAny, bool bWriteEvent, bool bMainSeqChild )
{
bool bHasFDelay = false;
double fDelay = 0;
@@ -1093,7 +1093,7 @@ void PowerPointExport::WriteAnimationCondition( FSHelperPtr pFS, Any& rAny, bool
WriteAnimationCondition( pFS, pDelay, pEvent, fDelay, bHasFDelay );
}
-void PowerPointExport::WriteAnimationNodeCommonPropsStart( FSHelperPtr pFS, const Reference< XAnimationNode >& rXNode, bool bSingle, bool bMainSeqChild )
+void PowerPointExport::WriteAnimationNodeCommonPropsStart( const FSHelperPtr& pFS, const Reference< XAnimationNode >& rXNode, bool bSingle, bool bMainSeqChild )
{
const char* pDuration = nullptr;
const char* pRestart = nullptr;
@@ -1283,7 +1283,7 @@ void PowerPointExport::WriteAnimationNodeCommonPropsStart( FSHelperPtr pFS, cons
pFS->endElementNS( XML_p, XML_cTn );
}
-void PowerPointExport::WriteAnimationNodeSeq( FSHelperPtr pFS, const Reference< XAnimationNode >& rXNode, sal_Int32, bool bMainSeqChild )
+void PowerPointExport::WriteAnimationNodeSeq( const FSHelperPtr& pFS, const Reference< XAnimationNode >& rXNode, sal_Int32, bool bMainSeqChild )
{
DBG(printf ("write animation node SEQ\n"));
@@ -1302,7 +1302,7 @@ void PowerPointExport::WriteAnimationNodeSeq( FSHelperPtr pFS, const Reference<
pFS->endElementNS( XML_p, XML_seq );
}
-void PowerPointExport::WriteAnimationNodeEffect( FSHelperPtr pFS, const Reference< XAnimationNode >& rXNode, sal_Int32, bool bMainSeqChild )
+void PowerPointExport::WriteAnimationNodeEffect( const FSHelperPtr& pFS, const Reference< XAnimationNode >& rXNode, sal_Int32, bool bMainSeqChild )
{
DBG(printf ("write animation node FILTER\n"));
@@ -1321,11 +1321,11 @@ void PowerPointExport::WriteAnimationNodeEffect( FSHelperPtr pFS, const Referenc
}
}
-void PowerPointExport::WriteAnimationNode( FSHelperPtr pFS, const Reference< XAnimationNode >& rXNode, bool bMainSeqChild )
+void PowerPointExport::WriteAnimationNode( const FSHelperPtr& pFS, const Reference< XAnimationNode >& rXNode, bool bMainSeqChild )
{
DBG(printf ("export node type: %d\n", rXNode->getType()));
sal_Int32 xmlNodeType = -1;
- typedef void (PowerPointExport::*AnimationNodeWriteMethod)( FSHelperPtr, const Reference< XAnimationNode >&, sal_Int32, bool );
+ typedef void (PowerPointExport::*AnimationNodeWriteMethod)( const FSHelperPtr&, const Reference< XAnimationNode >&, sal_Int32, bool );
AnimationNodeWriteMethod pMethod = nullptr;
switch( rXNode->getType() ) {
@@ -1364,7 +1364,7 @@ void PowerPointExport::WriteAnimationNode( FSHelperPtr pFS, const Reference< XAn
pFS->endElementNS( XML_p, xmlNodeType );
}
-void PowerPointExport::WriteAnimations( FSHelperPtr pFS )
+void PowerPointExport::WriteAnimations( const FSHelperPtr& pFS )
{
Reference< XAnimationNodeSupplier > xNodeSupplier( mXDrawPage, UNO_QUERY );
if( xNodeSupplier.is() ) {
@@ -1648,7 +1648,7 @@ void PowerPointExport::ImplWriteNotes( sal_uInt32 nPageNum )
DBG(printf("----------------\n"));
}
-void PowerPointExport::AddLayoutIdAndRelation( FSHelperPtr pFS, sal_Int32 nLayoutFileId )
+void PowerPointExport::AddLayoutIdAndRelation( const FSHelperPtr& pFS, sal_Int32 nLayoutFileId )
{
// add implicit relation of slide master to slide layout
OUString sRelId = addRelation( pFS->getOutputStream(),
@@ -1850,7 +1850,7 @@ void PowerPointExport::ImplWritePPTXLayout( sal_Int32 nOffset, sal_uInt32 nMaste
xDrawPages->remove( xSlide );
}
-void PowerPointExport::WriteShapeTree( FSHelperPtr pFS, PageType ePageType, bool bMaster )
+void PowerPointExport::WriteShapeTree( const FSHelperPtr& pFS, PageType ePageType, bool bMaster )
{
PowerPointShapeExport aDML( pFS, &maShapeMap, this );
aDML.SetMaster( bMaster );
@@ -1879,7 +1879,7 @@ void PowerPointExport::WriteShapeTree( FSHelperPtr pFS, PageType ePageType, bool
pFS->endElementNS( XML_p, XML_spTree );
}
-ShapeExport& PowerPointShapeExport::WritePageShape( Reference< XShape > xShape, PageType ePageType, bool bPresObj )
+ShapeExport& PowerPointShapeExport::WritePageShape( const Reference< XShape >& xShape, PageType ePageType, bool bPresObj )
{
if( ( ePageType == NOTICE && bPresObj ) || ePageType == LAYOUT )
return WritePlaceholderShape( xShape, SlideImage );
@@ -1887,7 +1887,7 @@ ShapeExport& PowerPointShapeExport::WritePageShape( Reference< XShape > xShape,
return WriteTextShape( xShape );
}
-bool PowerPointShapeExport::WritePlaceholder( Reference< XShape > xShape, PlaceholderType ePlaceholder, bool bMaster )
+bool PowerPointShapeExport::WritePlaceholder( const Reference< XShape >& xShape, PlaceholderType ePlaceholder, bool bMaster )
{
DBG(printf("WritePlaceholder %d %d\n", bMaster, ShapeExport::NonEmptyText( xShape )));
if( bMaster && ShapeExport::NonEmptyText( xShape ) ) {
@@ -1899,7 +1899,7 @@ bool PowerPointShapeExport::WritePlaceholder( Reference< XShape > xShape, Placeh
return false;
}
-ShapeExport& PowerPointShapeExport::WritePlaceholderShape( Reference< XShape > xShape, PlaceholderType ePlaceholder )
+ShapeExport& PowerPointShapeExport::WritePlaceholderShape( const Reference< XShape >& xShape, PlaceholderType ePlaceholder )
{
mpFS->startElementNS( XML_p, XML_sp, FSEND );
diff --git a/sd/source/filter/xml/sdxmlwrp.cxx b/sd/source/filter/xml/sdxmlwrp.cxx
index 7d9fbf7..c49b96c 100644
--- a/sd/source/filter/xml/sdxmlwrp.cxx
+++ b/sd/source/filter/xml/sdxmlwrp.cxx
@@ -170,8 +170,8 @@ namespace
{
sal_Int32 ReadThroughComponent(
- Reference<io::XInputStream> xInputStream,
- Reference<XComponent> xModelComponent,
+ const Reference<io::XInputStream>& xInputStream,
+ const Reference<XComponent>& xModelComponent,
const OUString& rStreamName,
Reference<uno::XComponentContext> & rxContext,
const sal_Char* pFilterName,
@@ -312,7 +312,7 @@ sal_Int32 ReadThroughComponent(
sal_Int32 ReadThroughComponent(
const uno::Reference < embed::XStorage >& xStorage,
- Reference<XComponent> xModelComponent,
+ const Reference<XComponent>& xModelComponent,
const sal_Char* pStreamName,
const sal_Char* pCompatibilityStreamName,
Reference<uno::XComponentContext> & rxContext,
diff --git a/sd/source/ui/animations/CustomAnimationList.cxx b/sd/source/ui/animations/CustomAnimationList.cxx
index 0c64fed..328478a 100644
--- a/sd/source/ui/animations/CustomAnimationList.cxx
+++ b/sd/source/ui/animations/CustomAnimationList.cxx
@@ -522,7 +522,7 @@ void CustomAnimationList::KeyInput( const KeyEvent& rKEvt )
/** selects or deselects the given effect.
Selections of other effects are not changed */
-void CustomAnimationList::select( CustomAnimationEffectPtr pEffect )
+void CustomAnimationList::select( const CustomAnimationEffectPtr& pEffect )
{
CustomAnimationListEntry* pEntry = static_cast< CustomAnimationListEntry* >(First());
while( pEntry )
@@ -551,7 +551,7 @@ void CustomAnimationList::clear()
mxLastTargetShape = nullptr;
}
-void CustomAnimationList::update( MainSequencePtr pMainSequence )
+void CustomAnimationList::update( const MainSequencePtr& pMainSequence )
{
if( mpMainSequence.get() )
mpMainSequence->removeListener( this );
@@ -566,11 +566,11 @@ void CustomAnimationList::update( MainSequencePtr pMainSequence )
struct stl_append_effect_func : public std::unary_function<CustomAnimationEffectPtr, void>
{
explicit stl_append_effect_func( CustomAnimationList& rList ) : mrList( rList ) {}
- void operator()(CustomAnimationEffectPtr pEffect);
+ void operator()(const CustomAnimationEffectPtr& pEffect);
CustomAnimationList& mrList;
};
-void stl_append_effect_func::operator()(CustomAnimationEffectPtr pEffect)
+void stl_append_effect_func::operator()(const CustomAnimationEffectPtr& pEffect)
{
mrList.append( pEffect );
}
@@ -790,7 +790,7 @@ void CustomAnimationList::append( CustomAnimationEffectPtr pEffect )
}
}
-void selectShape( SvTreeListBox* pTreeList, Reference< XShape > xShape )
+void selectShape( SvTreeListBox* pTreeList, const Reference< XShape >& xShape )
{
CustomAnimationListEntry* pEntry = static_cast< CustomAnimationListEntry* >(pTreeList->First());
while( pEntry )
diff --git a/sd/source/ui/animations/CustomAnimationList.hxx b/sd/source/ui/animations/CustomAnimationList.hxx
index 3769345..e72bf4b 100644
--- a/sd/source/ui/animations/CustomAnimationList.hxx
+++ b/sd/source/ui/animations/CustomAnimationList.hxx
@@ -58,10 +58,10 @@ public:
/** selects or deselects the given effect.
Selections of other effects are not changed */
- void select( CustomAnimationEffectPtr pEffect );
+ void select( const CustomAnimationEffectPtr& pEffect );
/** populates the list with all effects from the given MainSequence */
- void update( MainSequencePtr pMainSequence );
+ void update( const MainSequencePtr& pMainSequence );
void update();
diff --git a/sd/source/ui/animations/CustomAnimationPane.cxx b/sd/source/ui/animations/CustomAnimationPane.cxx
index 0d7b552..66f64e8 100644
--- a/sd/source/ui/animations/CustomAnimationPane.cxx
+++ b/sd/source/ui/animations/CustomAnimationPane.cxx
@@ -759,7 +759,7 @@ void CustomAnimationPane::updateControls()
updateMotionPathTags();
}
-static bool updateMotionPathImpl( CustomAnimationPane& rPane, ::sd::View& rView, EffectSequence::iterator aIter, EffectSequence::iterator aEnd, MotionPathTagVector& rOldTags, MotionPathTagVector& rNewTags )
+static bool updateMotionPathImpl( CustomAnimationPane& rPane, ::sd::View& rView, EffectSequence::iterator aIter, const EffectSequence::iterator& aEnd, MotionPathTagVector& rOldTags, MotionPathTagVector& rNewTags )
{
bool bChanges = false;
while( aIter != aEnd )
@@ -940,7 +940,7 @@ void addValue( STLPropertySet* pSet, sal_Int32 nHandle, const Any& rValue )
}
}
-static sal_Int32 calcMaxParaDepth( Reference< XShape > xTargetShape )
+static sal_Int32 calcMaxParaDepth( const Reference< XShape >& xTargetShape )
{
sal_Int32 nMaxParaDepth = -1;
@@ -970,7 +970,7 @@ static sal_Int32 calcMaxParaDepth( Reference< XShape > xTargetShape )
return nMaxParaDepth + 1;
}
-Any CustomAnimationPane::getProperty1Value( sal_Int32 nType, CustomAnimationEffectPtr pEffect )
+Any CustomAnimationPane::getProperty1Value( sal_Int32 nType, const CustomAnimationEffectPtr& pEffect )
{
switch( nType )
{
@@ -1025,7 +1025,7 @@ Any CustomAnimationPane::getProperty1Value( sal_Int32 nType, CustomAnimationEffe
return aAny;
}
-bool CustomAnimationPane::setProperty1Value( sal_Int32 nType, CustomAnimationEffectPtr pEffect, const Any& rValue )
+bool CustomAnimationPane::setProperty1Value( sal_Int32 nType, const CustomAnimationEffectPtr& pEffect, const Any& rValue )
{
bool bEffectChanged = false;
switch( nType )
diff --git a/sd/source/ui/animations/CustomAnimationPane.hxx b/sd/source/ui/animations/CustomAnimationPane.hxx
index c124c15..7729fd9 100644
--- a/sd/source/ui/animations/CustomAnimationPane.hxx
+++ b/sd/source/ui/animations/CustomAnimationPane.hxx
@@ -113,8 +113,8 @@ private:
STLPropertySet* createSelectionSet();
void changeSelection( STLPropertySet* pResultSet, STLPropertySet* pOldSet );
- static css::uno::Any getProperty1Value( sal_Int32 nType, CustomAnimationEffectPtr pEffect );
- bool setProperty1Value( sal_Int32 nType, CustomAnimationEffectPtr pEffect, const css::uno::Any& rValue );
+ static css::uno::Any getProperty1Value( sal_Int32 nType, const CustomAnimationEffectPtr& pEffect );
+ bool setProperty1Value( sal_Int32 nType, const CustomAnimationEffectPtr& pEffect, const css::uno::Any& rValue );
void UpdateLook();
sal_uInt32 fillAnimationLB();
diff --git a/sd/source/ui/annotations/annotationmanager.cxx b/sd/source/ui/annotations/annotationmanager.cxx
index f4ae8aa..20e5656 100644
--- a/sd/source/ui/annotations/annotationmanager.cxx
+++ b/sd/source/ui/annotations/annotationmanager.cxx
@@ -478,7 +478,7 @@ void AnnotationManagerImpl::ExecuteReplyToAnnotation( SfxRequest& rReq )
}
}
-void AnnotationManagerImpl::DeleteAnnotation( Reference< XAnnotation > xAnnotation )
+void AnnotationManagerImpl::DeleteAnnotation( const Reference< XAnnotation >& xAnnotation )
{
SdPage* pPage = GetCurrentPage();
@@ -719,7 +719,7 @@ void AnnotationManagerImpl::onTagDeselected( AnnotationTag& rTag )
}
}
-void AnnotationManagerImpl::SelectAnnotation( css::uno::Reference< css::office::XAnnotation > xAnnotation, bool bEdit /* = sal_False */ )
+void AnnotationManagerImpl::SelectAnnotation( const css::uno::Reference< css::office::XAnnotation >& xAnnotation, bool bEdit /* = sal_False */ )
{
mxSelectedAnnotation = xAnnotation;
@@ -901,7 +901,7 @@ IMPL_LINK_TYPED(AnnotationManagerImpl,EventMultiplexerListener,
}
}
-void AnnotationManagerImpl::ExecuteAnnotationContextMenu( Reference< XAnnotation > xAnnotation, vcl::Window* pParent, const Rectangle& rContextRect, bool bButtonMenu /* = false */ )
+void AnnotationManagerImpl::ExecuteAnnotationContextMenu( const Reference< XAnnotation >& xAnnotation, vcl::Window* pParent, const Rectangle& rContextRect, bool bButtonMenu /* = false */ )
{
SfxDispatcher* pDispatcher( getDispatcher( mrBase ) );
if( !pDispatcher )
diff --git a/sd/source/ui/annotations/annotationmanagerimpl.hxx b/sd/source/ui/annotations/annotationmanagerimpl.hxx
index 643d3a0..5f6a6d4 100644
--- a/sd/source/ui/annotations/annotationmanagerimpl.hxx
+++ b/sd/source/ui/annotations/annotationmanagerimpl.hxx
@@ -70,15 +70,15 @@ public:
void SelectNextAnnotation(bool bForeward);
- void SelectAnnotation( css::uno::Reference< css::office::XAnnotation > xAnnotation, bool bEdit = false );
+ void SelectAnnotation( const css::uno::Reference< css::office::XAnnotation >& xAnnotation, bool bEdit = false );
void GetSelectedAnnotation( css::uno::Reference< css::office::XAnnotation >& xAnnotation );
void InsertAnnotation();
- void DeleteAnnotation( css::uno::Reference< css::office::XAnnotation > xAnnotation );
+ void DeleteAnnotation( const css::uno::Reference< css::office::XAnnotation >& xAnnotation );
void DeleteAnnotationsByAuthor( const OUString& sAuthor );
void DeleteAllAnnotations();
- void ExecuteAnnotationContextMenu( css::uno::Reference< css::office::XAnnotation > xAnnotation, vcl::Window* pParent, const Rectangle& rContextRect, bool bButtonMenu = false );
+ void ExecuteAnnotationContextMenu( const css::uno::Reference< css::office::XAnnotation >& xAnnotation, vcl::Window* pParent, const Rectangle& rContextRect, bool bButtonMenu = false );
static Color GetColorDark(sal_uInt16 aAuthorIndex);
static Color GetColorLight(sal_uInt16 aAuthorIndex);
diff --git a/sd/source/ui/dlg/PhotoAlbumDialog.cxx b/sd/source/ui/dlg/PhotoAlbumDialog.cxx
index 962b05a..e92c939 100644
--- a/sd/source/ui/dlg/PhotoAlbumDialog.cxx
+++ b/sd/source/ui/dlg/PhotoAlbumDialog.cxx
@@ -636,7 +636,7 @@ IMPL_LINK_NOARG_TYPED(SdPhotoAlbumDialog, SelectHdl, ListBox&, void)
}
Reference< drawing::XDrawPage > SdPhotoAlbumDialog::appendNewSlide(AutoLayout aLayout,
- Reference< drawing::XDrawPages > xDrawPages
+ const Reference< drawing::XDrawPages >& xDrawPages
)
{
Reference< drawing::XDrawPage > xSlide; // Create the slide
@@ -690,7 +690,7 @@ void SdPhotoAlbumDialog::createCaption(const awt::Size& aPageSize )
}
Reference< graphic::XGraphic> SdPhotoAlbumDialog::createXGraphicFromUrl(const OUString& sUrl,
- Reference< graphic::XGraphicProvider> xProvider
+ const Reference< graphic::XGraphicProvider>& xProvider
)
{
// The same as above, except this returns an XGraphic from the image URL
diff --git a/sd/source/ui/dlg/PhotoAlbumDialog.hxx b/sd/source/ui/dlg/PhotoAlbumDialog.hxx
index cdcbf44..8c35d55 100644
--- a/sd/source/ui/dlg/PhotoAlbumDialog.hxx
+++ b/sd/source/ui/dlg/PhotoAlbumDialog.hxx
@@ -81,12 +81,12 @@ private:
DECL_LINK_TYPED(SelectHdl, ListBox&, void);
Reference< drawing::XDrawPage > appendNewSlide(AutoLayout aLayout,
- Reference< drawing::XDrawPages > xDrawPages);
+ const Reference< drawing::XDrawPages >& xDrawPages);
static awt::Size createASRSize(const awt::Size& aPicSize, const awt::Size& aMaxSize);
void createCaption(const awt::Size& aPageSize);
static Reference< graphic::XGraphic> createXGraphicFromUrl(const OUString& sUrl,
- Reference< graphic::XGraphicProvider> xProvider);
+ const Reference< graphic::XGraphicProvider>& xProvider);
void EnableDisableButtons();
diff --git a/sd/source/ui/dlg/RemoteDialogClientBox.cxx b/sd/source/ui/dlg/RemoteDialogClientBox.cxx
index 0d7e632..b18c70e 100644
--- a/sd/source/ui/dlg/RemoteDialogClientBox.cxx
+++ b/sd/source/ui/dlg/RemoteDialogClientBox.cxx
@@ -631,7 +631,7 @@ bool ClientBox::Notify( NotifyEvent& rNEvt )
return true;
}
-long ClientBox::addEntry( std::shared_ptr<ClientInfo> pClientInfo )
+long ClientBox::addEntry( const std::shared_ptr<ClientInfo>& pClientInfo )
{
long nPos = 0;
diff --git a/sd/source/ui/dlg/RemoteDialogClientBox.hxx b/sd/source/ui/dlg/RemoteDialogClientBox.hxx
index 5751e05..c125efe 100644
--- a/sd/source/ui/dlg/RemoteDialogClientBox.hxx
+++ b/sd/source/ui/dlg/RemoteDialogClientBox.hxx
@@ -147,7 +147,7 @@ public:
void RecalcAll();
void selectEntry( const long nPos );
- long addEntry(std::shared_ptr<ClientInfo> pClientInfo);
+ long addEntry(const std::shared_ptr<ClientInfo>& pClientInfo);
void clearEntries();
OUString getPin();
diff --git a/sd/source/ui/dlg/dlgass.cxx b/sd/source/ui/dlg/dlgass.cxx
index 11268d1..75d8f7e 100644
--- a/sd/source/ui/dlg/dlgass.cxx
+++ b/sd/source/ui/dlg/dlgass.cxx
@@ -161,7 +161,7 @@ public:
VclPtr<vcl::Window> mpWindow;
- void SavePassword( SfxObjectShellLock xDoc, const OUString& rPath );
+ void SavePassword( const SfxObjectShellLock& xDoc, const OUString& rPath );
void RestorePassword( SfxItemSet* pSet, const OUString& rPath );
uno::Sequence < beans::NamedValue > GetPassword( const OUString& rPath );
void DeletePasswords();
@@ -1555,7 +1555,7 @@ void AssistentDlgImpl::UpdatePreview( bool bDocPreview )
mbPreviewUpdating = false;
}
-void AssistentDlgImpl::SavePassword( SfxObjectShellLock xDoc, const OUString& rPath )
+void AssistentDlgImpl::SavePassword( const SfxObjectShellLock& xDoc, const OUString& rPath )
{
if(xDoc.Is())
{
diff --git a/sd/source/ui/func/fuinsfil.cxx b/sd/source/ui/func/fuinsfil.cxx
index 04aba71..113c46e 100644
--- a/sd/source/ui/func/fuinsfil.cxx
+++ b/sd/source/ui/func/fuinsfil.cxx
@@ -97,7 +97,7 @@ OUString lcl_GetExtensionsList ( ::std::vector< FilterDesc > const& rFilterDescL
}
void lcl_AddFilter ( ::std::vector< FilterDesc >& rFilterDescList,
- std::shared_ptr<const SfxFilter> pFilter )
+ const std::shared_ptr<const SfxFilter>& pFilter )
{
if (pFilter)
rFilterDescList.push_back( ::std::make_pair( pFilter->GetUIName(), pFilter->GetDefaultExtension() ) );
diff --git a/sd/source/ui/inc/RemoteServer.hxx b/sd/source/ui/inc/RemoteServer.hxx
index e6bc07a..97fb55c 100644
--- a/sd/source/ui/inc/RemoteServer.hxx
+++ b/sd/source/ui/inc/RemoteServer.hxx
@@ -70,9 +70,9 @@ namespace sd
// For the control dialog
SD_DLLPUBLIC static std::vector< std::shared_ptr< ClientInfo > > getClients();
- SD_DLLPUBLIC static bool connectClient( std::shared_ptr< ClientInfo > pClient,
- const OUString& aPin );
- SD_DLLPUBLIC static void deauthoriseClient( std::shared_ptr< ClientInfo > pClient );
+ SD_DLLPUBLIC static bool connectClient( const std::shared_ptr< ClientInfo >& pClient,
+ const OUString& aPin );
+ SD_DLLPUBLIC static void deauthoriseClient( const std::shared_ptr< ClientInfo >& pClient );
/// ensure that discoverability (eg. for Bluetooth) is enabled
SD_DLLPUBLIC static void ensureDiscoverable();
diff --git a/sd/source/ui/inc/SlideSorterViewShell.hxx b/sd/source/ui/inc/SlideSorterViewShell.hxx
index 8338211..4a9f544 100644
--- a/sd/source/ui/inc/SlideSorterViewShell.hxx
+++ b/sd/source/ui/inc/SlideSorterViewShell.hxx
@@ -185,7 +185,7 @@ public:
virtual css::uno::Reference<css::accessibility::XAccessible>
CreateAccessibleDocumentView (::sd::Window* pWindow) override;
// handle SlideSorterView specially because AccessibleSlideSorterView doesn't inherit from AccessibleDocumentViewBase
- virtual void SwitchViewFireFocus( css::uno::Reference< css::accessibility::XAccessible > xAcc ) override;
+ virtual void SwitchViewFireFocus( const css::uno::Reference< css::accessibility::XAccessible >& xAcc ) override;
// Exported for unit test
SD_DLLPUBLIC SlideSorter& GetSlideSorter() const;
diff --git a/sd/source/ui/inc/View.hxx b/sd/source/ui/inc/View.hxx
index 17e6fe6..c1b97b3 100644
--- a/sd/source/ui/inc/View.hxx
+++ b/sd/source/ui/inc/View.hxx
@@ -153,7 +153,7 @@ public:
SdrMediaObj* InsertMediaObj( const OUString& rURL, const OUString& rMimeType, sal_Int8& rAction,
const Point& rPos, const Size& rSize );
- bool PasteRTFTable( ::tools::SvRef<SotStorageStream> xStm, SdrPage* pPage, SdrInsertFlags nPasteOptions );
+ bool PasteRTFTable( const ::tools::SvRef<SotStorageStream>& xStm, SdrPage* pPage, SdrInsertFlags nPasteOptions );
bool IsPresObjSelected(bool bOnPage = true, bool bOnMasterPage = true, bool bCheckPresObjListOnly = false, bool bCheckLayoutOnly = false) const;
diff --git a/sd/source/ui/inc/ViewShell.hxx b/sd/source/ui/inc/ViewShell.hxx
index ff51ab5..9b50fcd 100644
--- a/sd/source/ui/inc/ViewShell.hxx
+++ b/sd/source/ui/inc/ViewShell.hxx
@@ -292,7 +292,7 @@ public:
virtual css::uno::Reference<css::accessibility::XAccessible>
CreateAccessibleDocumentView (::sd::Window* pWindow);
- virtual void SwitchViewFireFocus( css::uno::Reference< css::accessibility::XAccessible > xAcc );
+ virtual void SwitchViewFireFocus( const css::uno::Reference< css::accessibility::XAccessible >& xAcc );
void SwitchActiveViewFireFocus( );
// Move these two methods from DrawViewShell to enable slide show view
void NotifyAccUpdate();
diff --git a/sd/source/ui/inc/tools/SdGlobalResourceContainer.hxx b/sd/source/ui/inc/tools/SdGlobalResourceContainer.hxx
index 3f33bf9..e1c483e 100644
--- a/sd/source/ui/inc/tools/SdGlobalResourceContainer.hxx
+++ b/sd/source/ui/inc/tools/SdGlobalResourceContainer.hxx
@@ -73,7 +73,7 @@ public:
time of the destruction of SgGlobalResourceContainer no other
references exist the resource is destroyed as well.
*/
- void AddResource (std::shared_ptr<SdGlobalResource> pResource);
+ void AddResource (const std::shared_ptr<SdGlobalResource>& pResource);
/** Add a resource that is implemented as UNO object. Destruction
(when the sd modules is unloaded) is done by a) calling dispose()
diff --git a/sd/source/ui/inc/unosrch.hxx b/sd/source/ui/inc/unosrch.hxx
index 016d3b6..650912b 100644
--- a/sd/source/ui/inc/unosrch.hxx
+++ b/sd/source/ui/inc/unosrch.hxx
@@ -45,11 +45,11 @@ protected:
css::drawing::XShape* mpShape;
css::drawing::XDrawPage* mpPage;
- css::uno::Reference< css::text::XTextRange > Search( css::uno::Reference< css::text::XTextRange > xText, SdUnoSearchReplaceDescriptor* pDescr ) throw();
+ css::uno::Reference< css::text::XTextRange > Search( const css::uno::Reference< css::text::XTextRange >& xText, SdUnoSearchReplaceDescriptor* pDescr ) throw();
bool Search( const OUString& rText, sal_Int32& nStartPos, sal_Int32& nEndPos, SdUnoSearchReplaceDescriptor* pDescr ) throw();
- static ESelection GetSelection( css::uno::Reference< css::text::XTextRange > xTextRange ) throw();
- static css::uno::Reference< css::drawing::XShape > GetShape( css::uno::Reference< css::text::XTextRange > xTextRange ) throw();
- css::uno::Reference< css::drawing::XShape > GetNextShape( css::uno::Reference< css::container::XIndexAccess > xShapes, css::uno::Reference< css::drawing::XShape > xCurrentShape ) throw();
+ static ESelection GetSelection( const css::uno::Reference< css::text::XTextRange >& xTextRange ) throw();
+ static css::uno::Reference< css::drawing::XShape > GetShape( const css::uno::Reference< css::text::XTextRange >& xTextRange ) throw();
+ css::uno::Reference< css::drawing::XShape > GetNextShape( const css::uno::Reference< css::container::XIndexAccess >& xShapes, const css::uno::Reference< css::drawing::XShape >& xCurrentShape ) throw();
css::uno::Reference< css::drawing::XShape > GetCurrentShape() const throw();
public:
diff --git a/sd/source/ui/remotecontrol/Server.cxx b/sd/source/ui/remotecontrol/Server.cxx
index f0ebbff..f58d69f 100644
--- a/sd/source/ui/remotecontrol/Server.cxx
+++ b/sd/source/ui/remotecontrol/Server.cxx
@@ -270,7 +270,7 @@ std::vector< std::shared_ptr< ClientInfo > > RemoteServer::getClients()
return aClients;
}
-bool RemoteServer::connectClient( std::shared_ptr< ClientInfo > pClient, const OUString& aPin )
+bool RemoteServer::connectClient( const std::shared_ptr< ClientInfo >& pClient, const OUString& aPin )
{
SAL_INFO( "sdremote", "RemoteServer::connectClient called" );
if ( !spServer )
@@ -337,7 +337,7 @@ bool RemoteServer::connectClient( std::shared_ptr< ClientInfo > pClient, const O
}
}
-void RemoteServer::deauthoriseClient( std::shared_ptr< ClientInfo > pClient )
+void RemoteServer::deauthoriseClient( const std::shared_ptr< ClientInfo >& pClient )
{
// TODO: we probably want to forcefully disconnect at this point too?
// But possibly via a separate function to allow just disconnecting from
diff --git a/sd/source/ui/slidesorter/cache/SlsPageCacheManager.cxx b/sd/source/ui/slidesorter/cache/SlsPageCacheManager.cxx
index 52048b7..3919dad 100644
--- a/sd/source/ui/slidesorter/cache/SlsPageCacheManager.cxx
+++ b/sd/source/ui/slidesorter/cache/SlsPageCacheManager.cxx
@@ -190,7 +190,7 @@ PageCacheManager::~PageCacheManager()
}
std::shared_ptr<PageCacheManager::Cache> PageCacheManager::GetCache (
- DocumentKey pDocument,
+ const DocumentKey& pDocument,
const Size& rPreviewSize)
{
std::shared_ptr<Cache> pResult;
@@ -223,7 +223,7 @@ std::shared_ptr<PageCacheManager::Cache> PageCacheManager::GetCache (
void PageCacheManager::Recycle (
const std::shared_ptr<Cache>& rpCache,
- DocumentKey pDocument,
+ const DocumentKey& pDocument,
const Size& rPreviewSize)
{
BestFittingPageCaches aCaches;
@@ -315,7 +315,7 @@ std::shared_ptr<PageCacheManager::Cache> PageCacheManager::ChangeSize (
}
bool PageCacheManager::InvalidatePreviewBitmap (
- DocumentKey pDocument,
+ const DocumentKey& pDocument,
const SdrPage* pKey)
{
bool bHasChanged (false);
@@ -343,7 +343,7 @@ bool PageCacheManager::InvalidatePreviewBitmap (
return bHasChanged;
}
-void PageCacheManager::InvalidateAllPreviewBitmaps (DocumentKey pDocument)
+void PageCacheManager::InvalidateAllPreviewBitmaps (const DocumentKey& pDocument)
{
if (pDocument == nullptr)
return;
@@ -387,7 +387,7 @@ void PageCacheManager::ReleasePreviewBitmap (const SdrPage* pPage)
}
std::shared_ptr<PageCacheManager::Cache> PageCacheManager::GetRecentlyUsedCache (
- DocumentKey pDocument,
+ const DocumentKey& pDocument,
const Size& rPreviewSize)
{
std::shared_ptr<Cache> pCache;
diff --git a/sd/source/ui/slidesorter/inc/cache/SlsPageCacheManager.hxx b/sd/source/ui/slidesorter/inc/cache/SlsPageCacheManager.hxx
index 47ce0de..97e6d42 100644
--- a/sd/source/ui/slidesorter/inc/cache/SlsPageCacheManager.hxx
+++ b/sd/source/ui/slidesorter/inc/cache/SlsPageCacheManager.hxx
@@ -58,7 +58,7 @@ public:
pointer and the ReleaseCache() method has not been called.
*/
std::shared_ptr<Cache> GetCache (
- DocumentKey pDocument,
+ const DocumentKey& pDocument,
const Size& rPreviewSize);
/** Tell the cache manager to release its own reference to the specified
@@ -82,14 +82,14 @@ public:
the next time.
*/
bool InvalidatePreviewBitmap (
- DocumentKey pDocument,
+ const DocumentKey& pDocument,
const SdrPage* pPage);
/** Invalidate the preview bitmaps for all slides that belong to the
specified document. This is necessary after model changes that
affect e.g. page number fields.
*/
- void InvalidateAllPreviewBitmaps (DocumentKey pDocument);
+ void InvalidateAllPreviewBitmaps (const DocumentKey& pDocument);
/** Invalidate all the caches that are currently in use and destroy
those that are not. This is used for example when the high contrast
@@ -131,7 +131,7 @@ private:
friend class Deleter;
std::shared_ptr<Cache> GetRecentlyUsedCache(
- DocumentKey pDocument,
+ const DocumentKey& pDocument,
const Size& rSize);
/** Add the given cache to the list of recently used caches for the
@@ -148,7 +148,7 @@ private:
*/
void Recycle (
const std::shared_ptr<Cache>& rpCache,
- DocumentKey pDocument,
+ const DocumentKey& pDocument,
const Size& rPreviewSize);
};
diff --git a/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx b/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx
index 9fc0c14..3393c5a 100644
--- a/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx
+++ b/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx
@@ -268,7 +268,7 @@ css::uno::Reference<css::accessibility::XAccessible>
return xRet;
}
-void SlideSorterViewShell::SwitchViewFireFocus(css::uno::Reference< css::accessibility::XAccessible > xAcc )
+void SlideSorterViewShell::SwitchViewFireFocus(const css::uno::Reference< css::accessibility::XAccessible >& xAcc )
{
if (xAcc.get())
{
diff --git a/sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx b/sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx
index 67dfc70..46d1c24 100644
--- a/sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx
+++ b/sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx
@@ -74,7 +74,7 @@ void DeviceCopy (
rSourceDevice);
}
-void ForAllRectangles (const vcl::Region& rRegion, ::std::function<void (const Rectangle&)> aFunction)
+void ForAllRectangles (const vcl::Region& rRegion, const std::function<void (const Rectangle&)>& aFunction)
{
OSL_ASSERT(aFunction);
RectangleVector aRectangles;
diff --git a/sd/source/ui/tools/SdGlobalResourceContainer.cxx b/sd/source/ui/tools/SdGlobalResourceContainer.cxx
index 4eb35b2..358266c 100644
--- a/sd/source/ui/tools/SdGlobalResourceContainer.cxx
+++ b/sd/source/ui/tools/SdGlobalResourceContainer.cxx
@@ -89,7 +89,7 @@ void SdGlobalResourceContainer::AddResource (
}
void SdGlobalResourceContainer::AddResource (
- std::shared_ptr<SdGlobalResource> pResource)
+ const std::shared_ptr<SdGlobalResource>& pResource)
{
::osl::MutexGuard aGuard (mpImpl->maMutex);
diff --git a/sd/source/ui/unoidl/unolayer.cxx b/sd/source/ui/unoidl/unolayer.cxx
index d088e46..b556ae3 100644
--- a/sd/source/ui/unoidl/unolayer.cxx
+++ b/sd/source/ui/unoidl/unolayer.cxx
@@ -734,7 +734,7 @@ namespace
@return
Return </True> if both pointers point to the same object.
*/
-bool compare_layers (uno::WeakReference<uno::XInterface> xRef, void* pSearchData)
+bool compare_layers (const uno::WeakReference<uno::XInterface>& xRef, void* pSearchData)
{
uno::Reference<uno::XInterface> xLayer (xRef);
if (xLayer.is())
diff --git a/sd/source/ui/unoidl/unomodel.cxx b/sd/source/ui/unoidl/unomodel.cxx
index bb58cd2..9380a18 100644
--- a/sd/source/ui/unoidl/unomodel.cxx
+++ b/sd/source/ui/unoidl/unomodel.cxx
@@ -1601,7 +1601,7 @@ sal_Int32 ImplPDFGetBookmarkPage( const OUString& rBookmark, SdDrawDocument& rDo
return nPage;
}
-void ImplPDFExportComments( uno::Reference< drawing::XDrawPage > xPage, vcl::PDFExtOutDevData& rPDFExtOutDevData )
+void ImplPDFExportComments( const uno::Reference< drawing::XDrawPage >& xPage, vcl::PDFExtOutDevData& rPDFExtOutDevData )
{
try
{
@@ -1636,7 +1636,7 @@ void ImplPDFExportComments( uno::Reference< drawing::XDrawPage > xPage, vcl::PDF
}
}
-void ImplPDFExportShapeInteraction( uno::Reference< drawing::XShape > xShape, SdDrawDocument& rDoc, vcl::PDFExtOutDevData& rPDFExtOutDevData )
+void ImplPDFExportShapeInteraction( const uno::Reference< drawing::XShape >& xShape, SdDrawDocument& rDoc, vcl::PDFExtOutDevData& rPDFExtOutDevData )
{
if ( xShape->getShapeType() == "com.sun.star.drawing.GroupShape" )
{
diff --git a/sd/source/ui/unoidl/unosrch.cxx b/sd/source/ui/unoidl/unosrch.cxx
index dffab99..a435300 100644
--- a/sd/source/ui/unoidl/unosrch.cxx
+++ b/sd/source/ui/unoidl/unosrch.cxx
@@ -400,7 +400,7 @@ uno::Reference< css::uno::XInterface > SAL_CALL SdUnoSearchReplaceShape::findNex
/** this method returns the shape that follows xCurrentShape in the shape collection xShapes.
It steps recursive into groupshapes and returns the xCurrentShape if it is the last
shape in this collection */
-uno::Reference< drawing::XShape > SdUnoSearchReplaceShape::GetNextShape( uno::Reference< container::XIndexAccess > xShapes, uno::Reference< drawing::XShape > xCurrentShape ) throw()
+uno::Reference< drawing::XShape > SdUnoSearchReplaceShape::GetNextShape( const uno::Reference< container::XIndexAccess >& xShapes, const uno::Reference< drawing::XShape >& xCurrentShape ) throw()
{
uno::Reference< drawing::XShape > xFound;
@@ -457,7 +457,7 @@ uno::Reference< drawing::XShape > SdUnoSearchReplaceShape::GetNextShape( uno::R
return xFound;
}
-uno::Reference< text::XTextRange > SdUnoSearchReplaceShape::Search( uno::Reference< text::XTextRange > xText, SdUnoSearchReplaceDescriptor* pDescr ) throw()
... etc. - the rest is truncated
More information about the Libreoffice-commits
mailing list