[Libreoffice-commits] core.git: comphelper/source extensions/source helpcompiler/inc helpcompiler/source hwpfilter/source include/comphelper include/ucbhelper include/unotools package/source sdext/source shell/inc shell/source sot/source ucbhelper/source unoidl/source unotools/source
Caolán McNamara
caolanm at redhat.com
Mon Mar 9 15:05:08 PDT 2015
comphelper/source/eventattachermgr/eventattachermgr.cxx | 14 ++---
comphelper/source/misc/instancelocker.cxx | 4 -
comphelper/source/misc/instancelocker.hxx | 2
comphelper/source/xml/ofopxmlhelper.cxx | 27 ++++------
extensions/source/update/feed/updatefeed.cxx | 2
helpcompiler/inc/HelpCompiler.hxx | 2
helpcompiler/source/HelpCompiler.cxx | 2
hwpfilter/source/hwpreader.hxx | 6 +-
include/comphelper/ofopxmlhelper.hxx | 10 +--
include/ucbhelper/simplecertificatevalidationrequest.hxx | 2
include/unotools/fontcfg.hxx | 8 +-
package/source/xstor/owriteablestream.cxx | 12 ++--
package/source/xstor/owriteablestream.hxx | 2
sdext/source/minimizer/informationdialog.cxx | 6 +-
sdext/source/minimizer/optimizerdialogcontrols.cxx | 20 +++----
shell/inc/internal/contentreader.hxx | 2
shell/source/win32/ooofilereader/contentreader.cxx | 2
sot/source/sdstor/stgcache.cxx | 12 ++--
sot/source/sdstor/stgcache.hxx | 12 ++--
ucbhelper/source/provider/simplecertificatevalidationrequest.cxx | 6 +-
unoidl/source/unoidlprovider.cxx | 2
unotools/source/config/fontcfg.cxx | 16 ++---
22 files changed, 83 insertions(+), 88 deletions(-)
New commits:
commit d22519f62bcd1325f1e7cc920a115b68fccd1922
Author: Caolán McNamara <caolanm at redhat.com>
Date: Mon Mar 9 21:10:04 2015 +0000
V801: Decreased performance
Change-Id: Id8cd45d2844c121f63684734ab3546c24a1aab32
diff --git a/comphelper/source/eventattachermgr/eventattachermgr.cxx b/comphelper/source/eventattachermgr/eventattachermgr.cxx
index 1b5c228..212af0c 100644
--- a/comphelper/source/eventattachermgr/eventattachermgr.cxx
+++ b/comphelper/source/eventattachermgr/eventattachermgr.cxx
@@ -92,7 +92,7 @@ class ImplEventAttacherManager
sal_Int16 nVersion;
public:
ImplEventAttacherManager( const Reference< XIntrospection > & rIntrospection,
- const Reference< XComponentContext > xContext );
+ const Reference< XComponentContext >& rContext );
virtual ~ImplEventAttacherManager();
// Methods of XEventAttacherManager
@@ -358,21 +358,21 @@ Reference< XEventAttacherManager > createEventAttacherManager( const Reference<
ImplEventAttacherManager::ImplEventAttacherManager( const Reference< XIntrospection > & rIntrospection,
- const Reference< XComponentContext > xContext )
+ const Reference< XComponentContext >& rContext )
: aScriptListeners( aLock )
- , mxContext( xContext )
+ , mxContext( rContext )
, mxIntrospection( rIntrospection )
, nVersion(0)
{
- if ( xContext.is() )
+ if ( rContext.is() )
{
- Reference< XInterface > xIFace( xContext->getServiceManager()->createInstanceWithContext(
- OUString( "com.sun.star.script.EventAttacher" ), xContext) );
+ Reference< XInterface > xIFace( rContext->getServiceManager()->createInstanceWithContext(
+ OUString( "com.sun.star.script.EventAttacher" ), rContext) );
if ( xIFace.is() )
{
xAttacher = Reference< XEventAttacher2 >::query( xIFace );
}
- xConverter = Converter::create(xContext);
+ xConverter = Converter::create(rContext);
}
Reference< XInitialization > xInit( xAttacher, UNO_QUERY );
diff --git a/comphelper/source/misc/instancelocker.cxx b/comphelper/source/misc/instancelocker.cxx
index 9fe7b5c..204d1a9 100644
--- a/comphelper/source/misc/instancelocker.cxx
+++ b/comphelper/source/misc/instancelocker.cxx
@@ -239,9 +239,9 @@ uno::Reference< uno::XInterface > SAL_CALL OInstanceLocker::Create(
OLockListener::OLockListener( const uno::WeakReference< lang::XComponent >& xWrapper,
const uno::Reference< uno::XInterface >& xInstance,
sal_Int32 nMode,
- const uno::Reference< embed::XActionsApproval > xApproval )
+ const uno::Reference< embed::XActionsApproval >& rApproval )
: m_xInstance( xInstance )
-, m_xApproval( xApproval )
+, m_xApproval( rApproval )
, m_xWrapper( xWrapper )
, m_bDisposed( false )
, m_bInitialized( false )
diff --git a/comphelper/source/misc/instancelocker.hxx b/comphelper/source/misc/instancelocker.hxx
index ad777eb..0581908 100644
--- a/comphelper/source/misc/instancelocker.hxx
+++ b/comphelper/source/misc/instancelocker.hxx
@@ -101,7 +101,7 @@ public:
OLockListener( const ::com::sun::star::uno::WeakReference< ::com::sun::star::lang::XComponent >& xWrapper,
const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >& xInstance,
sal_Int32 nMode,
- const ::com::sun::star::uno::Reference< ::com::sun::star::embed::XActionsApproval > xApproval );
+ const ::com::sun::star::uno::Reference< ::com::sun::star::embed::XActionsApproval >& rApproval );
virtual ~OLockListener();
diff --git a/comphelper/source/xml/ofopxmlhelper.cxx b/comphelper/source/xml/ofopxmlhelper.cxx
index 8a78fcb..d110a48 100644
--- a/comphelper/source/xml/ofopxmlhelper.cxx
+++ b/comphelper/source/xml/ofopxmlhelper.cxx
@@ -37,31 +37,30 @@ using namespace ::com::sun::star;
namespace comphelper {
-
-uno::Sequence< uno::Sequence< beans::StringPair > > SAL_CALL OFOPXMLHelper::ReadRelationsInfoSequence( const uno::Reference< io::XInputStream >& xInStream, const OUString & aStreamName, const uno::Reference< uno::XComponentContext > xContext )
+uno::Sequence< uno::Sequence< beans::StringPair > > SAL_CALL OFOPXMLHelper::ReadRelationsInfoSequence( const uno::Reference< io::XInputStream >& xInStream, const OUString & aStreamName, const uno::Reference< uno::XComponentContext >& rContext )
throw( uno::Exception )
{
OUString aStringID = "_rels/";
aStringID += aStreamName;
- return ReadSequence_Impl( xInStream, aStringID, RELATIONINFO_FORMAT, xContext );
+ return ReadSequence_Impl( xInStream, aStringID, RELATIONINFO_FORMAT, rContext );
}
-uno::Sequence< uno::Sequence< beans::StringPair > > SAL_CALL OFOPXMLHelper::ReadContentTypeSequence( const uno::Reference< io::XInputStream >& xInStream, const uno::Reference< uno::XComponentContext > xContext )
+uno::Sequence< uno::Sequence< beans::StringPair > > SAL_CALL OFOPXMLHelper::ReadContentTypeSequence( const uno::Reference< io::XInputStream >& xInStream, const uno::Reference< uno::XComponentContext >& rContext )
throw( uno::Exception )
{
OUString aStringID = "[Content_Types].xml";
- return ReadSequence_Impl( xInStream, aStringID, CONTENTTYPE_FORMAT, xContext );
+ return ReadSequence_Impl( xInStream, aStringID, CONTENTTYPE_FORMAT, rContext );
}
-void SAL_CALL OFOPXMLHelper::WriteRelationsInfoSequence( const uno::Reference< io::XOutputStream >& xOutStream, const uno::Sequence< uno::Sequence< beans::StringPair > >& aSequence, const uno::Reference< uno::XComponentContext > xContext )
+void SAL_CALL OFOPXMLHelper::WriteRelationsInfoSequence( const uno::Reference< io::XOutputStream >& xOutStream, const uno::Sequence< uno::Sequence< beans::StringPair > >& aSequence, const uno::Reference< uno::XComponentContext >& rContext )
throw( uno::Exception )
{
if ( !xOutStream.is() )
throw uno::RuntimeException();
- uno::Reference< xml::sax::XWriter > xWriter = xml::sax::Writer::create(xContext);
+ uno::Reference< xml::sax::XWriter > xWriter = xml::sax::Writer::create(rContext);
xWriter->setOutputStream( xOutStream );
@@ -116,13 +115,13 @@ void SAL_CALL OFOPXMLHelper::WriteRelationsInfoSequence( const uno::Reference< i
}
-void SAL_CALL OFOPXMLHelper::WriteContentSequence( const uno::Reference< io::XOutputStream >& xOutStream, const uno::Sequence< beans::StringPair >& aDefaultsSequence, const uno::Sequence< beans::StringPair >& aOverridesSequence, const uno::Reference< uno::XComponentContext > xContext )
+void SAL_CALL OFOPXMLHelper::WriteContentSequence( const uno::Reference< io::XOutputStream >& xOutStream, const uno::Sequence< beans::StringPair >& aDefaultsSequence, const uno::Sequence< beans::StringPair >& aOverridesSequence, const uno::Reference< uno::XComponentContext >& rContext )
throw( uno::Exception )
{
if ( !xOutStream.is() )
throw uno::RuntimeException();
- uno::Reference< xml::sax::XWriter > xWriter = xml::sax::Writer::create(xContext);
+ uno::Reference< xml::sax::XWriter > xWriter = xml::sax::Writer::create(rContext);
xWriter->setOutputStream( xOutStream );
@@ -176,16 +175,13 @@ void SAL_CALL OFOPXMLHelper::WriteContentSequence( const uno::Reference< io::XOu
}
-
-
-
-uno::Sequence< uno::Sequence< beans::StringPair > > SAL_CALL OFOPXMLHelper::ReadSequence_Impl( const uno::Reference< io::XInputStream >& xInStream, const OUString& aStringID, sal_uInt16 nFormat, const uno::Reference< uno::XComponentContext > xContext )
+uno::Sequence< uno::Sequence< beans::StringPair > > SAL_CALL OFOPXMLHelper::ReadSequence_Impl( const uno::Reference< io::XInputStream >& xInStream, const OUString& aStringID, sal_uInt16 nFormat, const uno::Reference< uno::XComponentContext >& rContext )
throw( uno::Exception )
{
- if ( !xContext.is() || !xInStream.is() || nFormat > FORMAT_MAX_ID )
+ if ( !rContext.is() || !xInStream.is() || nFormat > FORMAT_MAX_ID )
throw uno::RuntimeException();
- uno::Reference< xml::sax::XParser > xParser = xml::sax::Parser::create( xContext );
+ uno::Reference< xml::sax::XParser > xParser = xml::sax::Parser::create( rContext );
OFOPXMLHelper* pHelper = new OFOPXMLHelper( nFormat );
uno::Reference< xml::sax::XDocumentHandler > xHelper( static_cast< xml::sax::XDocumentHandler* >( pHelper ) );
@@ -199,7 +195,6 @@ uno::Sequence< uno::Sequence< beans::StringPair > > SAL_CALL OFOPXMLHelper::Read
return pHelper->GetParsingResult();
}
-
OFOPXMLHelper::OFOPXMLHelper( sal_uInt16 nFormat )
: m_nFormat( nFormat )
, m_aRelListElement( "Relationships" )
diff --git a/extensions/source/update/feed/updatefeed.cxx b/extensions/source/update/feed/updatefeed.cxx
index 5428544..61f0761 100644
--- a/extensions/source/update/feed/updatefeed.cxx
+++ b/extensions/source/update/feed/updatefeed.cxx
@@ -226,7 +226,7 @@ class UpdateInformationEnumeration : public ::cppu::WeakImplHelper1< container::
{
public:
UpdateInformationEnumeration(const uno::Reference< xml::dom::XNodeList >& xNodeList,
- const uno::Reference< UpdateInformationProvider > xUpdateInformationProvider) :
+ const uno::Reference< UpdateInformationProvider >& xUpdateInformationProvider) :
m_xUpdateInformationProvider(xUpdateInformationProvider),
m_xNodeList(xNodeList),
m_nNodes(xNodeList.is() ? xNodeList->getLength() : 0),
diff --git a/helpcompiler/inc/HelpCompiler.hxx b/helpcompiler/inc/HelpCompiler.hxx
index e686c74..1fbcaef 100644
--- a/helpcompiler/inc/HelpCompiler.hxx
+++ b/helpcompiler/inc/HelpCompiler.hxx
@@ -126,7 +126,7 @@ namespace fs
void append(const std::string &in) { append(in.c_str()); }
};
- void create_directory(const fs::path indexDirName);
+ void create_directory(const fs::path& indexDirName);
void copy(const fs::path &src, const fs::path &dest);
}
diff --git a/helpcompiler/source/HelpCompiler.cxx b/helpcompiler/source/HelpCompiler.cxx
index ccc324f..f85aae1 100644
--- a/helpcompiler/source/HelpCompiler.cxx
+++ b/helpcompiler/source/HelpCompiler.cxx
@@ -519,7 +519,7 @@ namespace fs
return nThreadTextEncoding;
}
- void create_directory(const fs::path indexDirName)
+ void create_directory(const fs::path& indexDirName)
{
HCDBG(
std::cerr << "creating " <<
diff --git a/hwpfilter/source/hwpreader.hxx b/hwpfilter/source/hwpreader.hxx
index e10c028..e2564e2 100644
--- a/hwpfilter/source/hwpreader.hxx
+++ b/hwpfilter/source/hwpreader.hxx
@@ -156,7 +156,7 @@ private:
class HwpImportFilter : public WeakImplHelper4< XFilter, XImporter, XServiceInfo, XExtendedFilterDetection >
{
public:
- HwpImportFilter( const Reference< XMultiServiceFactory > xFact );
+ HwpImportFilter(const Reference< XMultiServiceFactory >& rFact);
virtual ~HwpImportFilter();
public:
@@ -201,12 +201,12 @@ Sequence< OUString > HwpImportFilter::getSupportedServiceNames_Static() throw ()
return aRet;
}
-HwpImportFilter::HwpImportFilter( const Reference< XMultiServiceFactory > xFact )
+HwpImportFilter::HwpImportFilter(const Reference< XMultiServiceFactory >& rFact)
{
OUString sService( WRITER_IMPORTER_NAME );
try {
Reference< XDocumentHandler >
- xHandler( xFact->createInstance( sService ), UNO_QUERY );
+ xHandler( rFact->createInstance( sService ), UNO_QUERY );
HwpReader *p = new HwpReader;
p->setDocumentHandler( xHandler );
diff --git a/include/comphelper/ofopxmlhelper.hxx b/include/comphelper/ofopxmlhelper.hxx
index 0c759bb..d7fa44a 100644
--- a/include/comphelper/ofopxmlhelper.hxx
+++ b/include/comphelper/ofopxmlhelper.hxx
@@ -58,7 +58,7 @@ class COMPHELPER_DLLPUBLIC OFOPXMLHelper : public cppu::WeakImplHelper1 < com::s
OFOPXMLHelper( sal_uInt16 nFormat ); // must not be created directly
::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair > > GetParsingResult();
- static COMPHELPER_DLLPRIVATE ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair > > SAL_CALL ReadSequence_Impl( const ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream >& xInStream, const OUString& aStringID, sal_uInt16 nFormat, const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > xContext )
+ static COMPHELPER_DLLPRIVATE ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair > > SAL_CALL ReadSequence_Impl( const ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream >& xInStream, const OUString& aStringID, sal_uInt16 nFormat, const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rContext )
throw( ::com::sun::star::uno::Exception );
public:
@@ -73,7 +73,7 @@ public:
ReadRelationsInfoSequence(
const ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream >& xInStream,
const OUString & aStreamName,
- const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > xContext )
+ const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rContext )
throw( ::com::sun::star::uno::Exception );
// returns sequence containing two entries of type sequence<StringPair>
@@ -86,7 +86,7 @@ public:
SAL_CALL
ReadContentTypeSequence(
const ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream >& xInStream,
- const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > xContext )
+ const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rContext )
throw( ::com::sun::star::uno::Exception );
// writes sequence of elements, where each element is described by sequence of tags,
@@ -96,7 +96,7 @@ public:
void SAL_CALL WriteRelationsInfoSequence(
const ::com::sun::star::uno::Reference< ::com::sun::star::io::XOutputStream >& xOutStream,
const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair > >& aSequence,
- const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > xContext )
+ const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rContext )
throw( ::com::sun::star::uno::Exception );
// writes two entries of type sequence<StringPair>
@@ -109,7 +109,7 @@ public:
const ::com::sun::star::uno::Reference< ::com::sun::star::io::XOutputStream >& xOutStream,
const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair >& aDefaultsSequence,
const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair >& aOverridesSequence,
- const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > xContext )
+ const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rContext )
throw( ::com::sun::star::uno::Exception );
// XDocumentHandler
diff --git a/include/ucbhelper/simplecertificatevalidationrequest.hxx b/include/ucbhelper/simplecertificatevalidationrequest.hxx
index 934fb01..f52d627 100644
--- a/include/ucbhelper/simplecertificatevalidationrequest.hxx
+++ b/include/ucbhelper/simplecertificatevalidationrequest.hxx
@@ -52,7 +52,7 @@ public:
* @param pCertificate contaisn the server certificate.
*/
SimpleCertificateValidationRequest( const sal_Int32 & lCertificateValidity,
- const com::sun::star::uno::Reference<com::sun::star::security::XCertificate> pCertificate,
+ const com::sun::star::uno::Reference<com::sun::star::security::XCertificate>& certificate,
const OUString & hostname );
};
diff --git a/include/unotools/fontcfg.hxx b/include/unotools/fontcfg.hxx
index 37bf896..d8c7b96 100644
--- a/include/unotools/fontcfg.hxx
+++ b/include/unotools/fontcfg.hxx
@@ -157,14 +157,14 @@ private:
typedef std::unordered_set< OUString, OUStringHash > UniqueSubstHash;
mutable UniqueSubstHash maSubstHash;
- void fillSubstVector( const com::sun::star::uno::Reference< com::sun::star::container::XNameAccess > xFont,
+ void fillSubstVector( const com::sun::star::uno::Reference< com::sun::star::container::XNameAccess >& rFont,
const OUString& rType,
std::vector< OUString >& rSubstVector ) const;
- FontWeight getSubstWeight( const com::sun::star::uno::Reference< com::sun::star::container::XNameAccess > xFont,
+ FontWeight getSubstWeight( const com::sun::star::uno::Reference< com::sun::star::container::XNameAccess >& rFont,
const OUString& rType ) const;
- FontWidth getSubstWidth( const com::sun::star::uno::Reference< com::sun::star::container::XNameAccess > xFont,
+ FontWidth getSubstWidth( const com::sun::star::uno::Reference< com::sun::star::container::XNameAccess >& rFont,
const OUString& rType ) const;
- unsigned long getSubstType( const com::sun::star::uno::Reference< com::sun::star::container::XNameAccess > xFont,
+ unsigned long getSubstType( const com::sun::star::uno::Reference< com::sun::star::container::XNameAccess >& rFont,
const OUString& rType ) const;
void readLocaleSubst( const OUString& rBcp47 ) const;
public:
diff --git a/package/source/xstor/owriteablestream.cxx b/package/source/xstor/owriteablestream.cxx
index 9a2ac17..00b8d58 100644
--- a/package/source/xstor/owriteablestream.cxx
+++ b/package/source/xstor/owriteablestream.cxx
@@ -205,12 +205,12 @@ bool KillFile( const OUString& aURL, const uno::Reference< uno::XComponentContex
return bRet;
}
-OUString GetNewTempFileURL( const uno::Reference< uno::XComponentContext > xContext )
+OUString GetNewTempFileURL( const uno::Reference< uno::XComponentContext >& rContext )
{
OUString aTempURL;
uno::Reference < beans::XPropertySet > xTempFile(
- io::TempFile::create(xContext),
+ io::TempFile::create(rContext),
uno::UNO_QUERY_THROW );
try {
@@ -230,10 +230,10 @@ OUString GetNewTempFileURL( const uno::Reference< uno::XComponentContext > xCont
return aTempURL;
}
-uno::Reference< io::XStream > CreateMemoryStream( const uno::Reference< uno::XComponentContext >& xContext )
+uno::Reference< io::XStream > CreateMemoryStream( const uno::Reference< uno::XComponentContext >& rContext )
{
return uno::Reference< io::XStream >(
- xContext->getServiceManager()->createInstanceWithContext("com.sun.star.comp.MemoryStream", xContext),
+ rContext->getServiceManager()->createInstanceWithContext("com.sun.star.comp.MemoryStream", rContext),
uno::UNO_QUERY_THROW);
}
@@ -242,7 +242,7 @@ uno::Reference< io::XStream > CreateMemoryStream( const uno::Reference< uno::XCo
OWriteStream_Impl::OWriteStream_Impl( OStorage_Impl* pParent,
const uno::Reference< packages::XDataSinkEncrSupport >& xPackageStream,
const uno::Reference< lang::XSingleServiceFactory >& xPackage,
- const uno::Reference< uno::XComponentContext >& xContext,
+ const uno::Reference< uno::XComponentContext >& rContext,
bool bForceEncrypted,
sal_Int32 nStorageType,
bool bDefaultCompress,
@@ -251,7 +251,7 @@ OWriteStream_Impl::OWriteStream_Impl( OStorage_Impl* pParent,
, m_bHasDataToFlush( false )
, m_bFlushed( false )
, m_xPackageStream( xPackageStream )
-, m_xContext( xContext )
+, m_xContext( rContext )
, m_pParent( pParent )
, m_bForceEncrypted( bForceEncrypted )
, m_bUseCommonEncryption( !bForceEncrypted && nStorageType == embed::StorageFormats::PACKAGE )
diff --git a/package/source/xstor/owriteablestream.hxx b/package/source/xstor/owriteablestream.hxx
index 2599753..69b4f91 100644
--- a/package/source/xstor/owriteablestream.hxx
+++ b/package/source/xstor/owriteablestream.hxx
@@ -81,7 +81,7 @@ struct WSInternalData_Impl
sal_Int32 m_nStorageType;
// the mutex reference MUST NOT be empty
- WSInternalData_Impl( const SotMutexHolderRef rMutexRef, sal_Int32 nStorageType )
+ WSInternalData_Impl( const SotMutexHolderRef& rMutexRef, sal_Int32 nStorageType )
: m_rSharedMutexRef( rMutexRef )
, m_pTypeCollection( NULL )
, m_aListenersContainer( rMutexRef->GetMutex() )
diff --git a/sdext/source/minimizer/informationdialog.cxx b/sdext/source/minimizer/informationdialog.cxx
index 2aebca0..8a125de 100644
--- a/sdext/source/minimizer/informationdialog.cxx
+++ b/sdext/source/minimizer/informationdialog.cxx
@@ -126,7 +126,7 @@ OUString InsertImage(
}
OUString InsertCheckBox( InformationDialog& rInformationDialog, const OUString& rControlName,
- const Reference< XItemListener > xItemListener, const OUString& rLabel,
+ const Reference< XItemListener >& rItemListener, const OUString& rLabel,
sal_Int32 nXPos, sal_Int32 nYPos, sal_Int32 nWidth, sal_Int32 nHeight, sal_Int16 nTabIndex )
{
OUString pNames[] = {
@@ -155,8 +155,8 @@ OUString InsertCheckBox( InformationDialog& rInformationDialog, const OUString&
Sequence< Any > aValues( pValues, nCount );
Reference< XCheckBox > xCheckBox( rInformationDialog.insertCheckBox( rControlName, aNames, aValues ) );
- if ( xItemListener.is() )
- xCheckBox->addItemListener( xItemListener );
+ if ( rItemListener.is() )
+ xCheckBox->addItemListener( rItemListener );
return rControlName;
}
diff --git a/sdext/source/minimizer/optimizerdialogcontrols.cxx b/sdext/source/minimizer/optimizerdialogcontrols.cxx
index c86fcc4..df12933 100644
--- a/sdext/source/minimizer/optimizerdialogcontrols.cxx
+++ b/sdext/source/minimizer/optimizerdialogcontrols.cxx
@@ -164,7 +164,7 @@ OUString InsertFixedText( OptimizerDialog& rOptimizerDialog, const OUString& rCo
OUString InsertCheckBox( OptimizerDialog& rOptimizerDialog, const OUString& rControlName,
- const Reference< XItemListener > xItemListener, const OUString& rLabel,
+ const Reference< XItemListener >& xItemListener, const OUString& rLabel,
sal_Int32 nXPos, sal_Int32 nYPos, sal_Int32 nWidth, sal_Int32 nHeight, sal_Int16 nTabIndex )
{
OUString pNames[] = {
@@ -201,7 +201,7 @@ OUString InsertCheckBox( OptimizerDialog& rOptimizerDialog, const OUString& rCon
OUString InsertFormattedField( OptimizerDialog& rOptimizerDialog, const OUString& rControlName,
- const Reference< XTextListener > xTextListener, const Reference< XSpinListener > xSpinListener, sal_Int32 nXPos, sal_Int32 nYPos, sal_Int32 nWidth,
+ const Reference< XTextListener >& xTextListener, const Reference< XSpinListener >& xSpinListener, sal_Int32 nXPos, sal_Int32 nYPos, sal_Int32 nWidth,
double fEffectiveMin, double fEffectiveMax, sal_Int16 nTabIndex )
{
OUString pNames[] = {
@@ -249,7 +249,7 @@ OUString InsertFormattedField( OptimizerDialog& rOptimizerDialog, const OUString
OUString InsertComboBox( OptimizerDialog& rOptimizerDialog, const OUString& rControlName,
- const Reference< XTextListener > xTextListener, const bool bEnabled, const Sequence< OUString >& rItemList,
+ const Reference< XTextListener >& rTextListener, const bool bEnabled, const Sequence< OUString >& rItemList,
sal_Int32 nXPos, sal_Int32 nYPos, sal_Int32 nWidth, sal_Int32 nHeight, sal_Int16 nTabIndex )
{
OUString pNames[] = {
@@ -282,14 +282,14 @@ OUString InsertComboBox( OptimizerDialog& rOptimizerDialog, const OUString& rCon
Sequence< Any > aValues( pValues, nCount );
Reference< XTextComponent > xTextComponent( rOptimizerDialog.insertComboBox( rControlName, aNames, aValues ), UNO_QUERY_THROW );
- if ( xTextListener.is() )
- xTextComponent->addTextListener( xTextListener );
+ if ( rTextListener.is() )
+ xTextComponent->addTextListener( rTextListener );
return rControlName;
}
-OUString InsertRadioButton( OptimizerDialog& rOptimizerDialog, const OUString& rControlName, const Reference< XItemListener > xItemListener,
+OUString InsertRadioButton( OptimizerDialog& rOptimizerDialog, const OUString& rControlName, const Reference< XItemListener >& rItemListener,
const OUString& rLabel, sal_Int32 nXPos, sal_Int32 nYPos, sal_Int32 nWidth, sal_Int32 nHeight, bool bMultiLine, sal_Int16 nTabIndex )
{
OUString pNames[] = {
@@ -318,15 +318,15 @@ OUString InsertRadioButton( OptimizerDialog& rOptimizerDialog, const OUString& r
Sequence< Any > aValues( pValues, nCount );
Reference< XRadioButton > xRadioButton( rOptimizerDialog.insertRadioButton( rControlName, aNames, aValues ) );
- if ( xItemListener.is() )
- xRadioButton->addItemListener( xItemListener );
+ if ( rItemListener.is() )
+ xRadioButton->addItemListener( rItemListener );
return rControlName;
}
OUString InsertListBox( OptimizerDialog& rOptimizerDialog, const OUString& rControlName,
- const Reference< XActionListener > xActionListener, const bool bEnabled, const Sequence< OUString >& rItemList,
+ const Reference< XActionListener >& rActionListener, const bool bEnabled, const Sequence< OUString >& rItemList,
sal_Int32 nXPos, sal_Int32 nYPos, sal_Int32 nWidth, sal_Int32 nHeight, sal_Int16 nTabIndex )
{
OUString pNames[] = {
@@ -362,7 +362,7 @@ OUString InsertListBox( OptimizerDialog& rOptimizerDialog, const OUString& rCont
Reference< XListBox > xListBox( rOptimizerDialog.insertListBox( rControlName, aNames, aValues ) );
if ( xListBox.is() )
- xListBox->addActionListener( xActionListener );
+ xListBox->addActionListener( rActionListener );
return rControlName;
}
diff --git a/shell/inc/internal/contentreader.hxx b/shell/inc/internal/contentreader.hxx
index 279aea9..a6a4e2e 100644
--- a/shell/inc/internal/contentreader.hxx
+++ b/shell/inc/internal/contentreader.hxx
@@ -106,7 +106,7 @@ protected:
/** get a style's locale field.
*/
- LocaleSet_t const & getLocale( const StyleName_t Style );
+ LocaleSet_t const & getLocale( const StyleName_t& Style );
private:
std::stack<ITag*> m_TagBuilderStack;
diff --git a/shell/source/win32/ooofilereader/contentreader.cxx b/shell/source/win32/ooofilereader/contentreader.cxx
index 7f4ecd7..3c22a1a 100644
--- a/shell/source/win32/ooofilereader/contentreader.cxx
+++ b/shell/source/win32/ooofilereader/contentreader.cxx
@@ -151,7 +151,7 @@ void CContentReader::addChunk( LocaleSet_t const & Locale, Content_t const & Con
/** get a style's locale field.
*/
-LocaleSet_t const & CContentReader::getLocale( const StyleName_t Style )
+LocaleSet_t const & CContentReader::getLocale( const StyleName_t& Style )
{
if ( m_StyleMap.empty() )
return m_DefaultLocale;
diff --git a/sot/source/sdstor/stgcache.cxx b/sot/source/sdstor/stgcache.cxx
index 7b96e4f..1d09b7b 100644
--- a/sot/source/sdstor/stgcache.cxx
+++ b/sot/source/sdstor/stgcache.cxx
@@ -57,15 +57,15 @@ rtl::Reference< StgPage > StgPage::Create( short nData, sal_Int32 nPage )
return rtl::Reference< StgPage >( new StgPage( nData, nPage ) );
}
-void StgCache::SetToPage ( const rtl::Reference< StgPage > xPage, short nOff, sal_Int32 nVal )
+void StgCache::SetToPage ( const rtl::Reference< StgPage >& rPage, short nOff, sal_Int32 nVal )
{
- if( ( nOff < (short) ( xPage->GetSize() / sizeof( sal_Int32 ) ) ) && nOff >= 0 )
+ if( ( nOff < (short) ( rPage->GetSize() / sizeof( sal_Int32 ) ) ) && nOff >= 0 )
{
#ifdef OSL_BIGENDIAN
nVal = OSL_SWAPDWORD(nVal);
#endif
- ((sal_Int32*) xPage->GetData() )[ nOff ] = nVal;
- SetDirty( xPage );
+ ((sal_Int32*) rPage->GetData() )[ nOff ] = nVal;
+ SetDirty( rPage );
}
}
@@ -272,10 +272,10 @@ void StgCache::SetStrm( UCBStorageStream* pStgStream )
bMyStream = false;
}
-void StgCache::SetDirty( const rtl::Reference< StgPage > &xPage )
+void StgCache::SetDirty( const rtl::Reference< StgPage > &rPage )
{
assert( IsWritable() );
- maDirtyPages[ xPage->GetPage() ] = xPage;
+ maDirtyPages[ rPage->GetPage() ] = rPage;
}
// Open/close the disk file
diff --git a/sot/source/sdstor/stgcache.hxx b/sot/source/sdstor/stgcache.hxx
index bee74e3..b531f51 100644
--- a/sot/source/sdstor/stgcache.hxx
+++ b/sot/source/sdstor/stgcache.hxx
@@ -86,9 +86,9 @@ public:
// two routines for accessing FAT pages
// Assume that the data is a FAT page and get/put FAT data.
- void SetToPage ( const rtl::Reference< StgPage > xPage, short nOff, sal_Int32 nVal );
- inline sal_Int32 GetFromPage ( const rtl::Reference< StgPage > xPage, short nOff );
- void SetDirty ( const rtl::Reference< StgPage > &xPage );
+ void SetToPage ( const rtl::Reference< StgPage >& rPage, short nOff, sal_Int32 nVal );
+ inline sal_Int32 GetFromPage ( const rtl::Reference< StgPage >& rPage, short nOff );
+ void SetDirty ( const rtl::Reference< StgPage > &rPage );
bool SetSize( sal_Int32 nPages );
rtl::Reference< StgPage > Find( sal_Int32 ); // find a cached page
rtl::Reference< StgPage > Get( sal_Int32, bool ); // get a cached page
@@ -115,11 +115,11 @@ public:
static bool IsPageGreater( const StgPage *pA, const StgPage *pB );
};
-inline sal_Int32 StgCache::GetFromPage ( const rtl::Reference< StgPage > xPage, short nOff )
+inline sal_Int32 StgCache::GetFromPage ( const rtl::Reference< StgPage >& rPage, short nOff )
{
- if( ( nOff >= (short) ( xPage->GetSize() / sizeof( sal_Int32 ) ) ) || nOff < 0 )
+ if( ( nOff >= (short) ( rPage->GetSize() / sizeof( sal_Int32 ) ) ) || nOff < 0 )
return -1;
- sal_Int32 n = ((sal_Int32*) xPage->GetData() )[ nOff ];
+ sal_Int32 n = ((sal_Int32*) rPage->GetData() )[ nOff ];
#ifdef OSL_BIGENDIAN
return OSL_SWAPDWORD(n);
#else
diff --git a/ucbhelper/source/provider/simplecertificatevalidationrequest.cxx b/ucbhelper/source/provider/simplecertificatevalidationrequest.cxx
index 2e9d21e..4ee851d 100644
--- a/ucbhelper/source/provider/simplecertificatevalidationrequest.cxx
+++ b/ucbhelper/source/provider/simplecertificatevalidationrequest.cxx
@@ -25,13 +25,13 @@ using namespace ucbhelper;
SimpleCertificateValidationRequest::SimpleCertificateValidationRequest( const sal_Int32 & lCertificateValidity,
- const com::sun::star::uno::Reference<com::sun::star::security::XCertificate> pCertificate,
+ const com::sun::star::uno::Reference<com::sun::star::security::XCertificate>& certificate,
const OUString & hostname)
{
// Fill request...
ucb::CertificateValidationRequest aRequest;
aRequest.CertificateValidity = lCertificateValidity;
- aRequest.Certificate = pCertificate;
+ aRequest.Certificate = certificate;
aRequest.HostName = hostname;
setRequest( uno::makeAny( aRequest ) );
@@ -41,7 +41,7 @@ SimpleCertificateValidationRequest::SimpleCertificateValidationRequest( const sa
aContinuations[ 1 ] = new InteractionApprove( this );
setContinuations( aContinuations );
- pCertificate.get();
+ certificate.get();
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/unoidl/source/unoidlprovider.cxx b/unoidl/source/unoidlprovider.cxx
index 23de040..90f3b81 100644
--- a/unoidl/source/unoidlprovider.cxx
+++ b/unoidl/source/unoidlprovider.cxx
@@ -456,7 +456,7 @@ struct MapEntry {
Memory32 data;
};
-bool operator <(Map const map1, Map const map2) {
+bool operator <(const Map& map1, const Map& map2) {
return map1.begin < map2.begin
|| (map1.begin == map2.begin && map1.size < map2.size);
}
diff --git a/unotools/source/config/fontcfg.cxx b/unotools/source/config/fontcfg.cxx
index 77d57a1..e4a9661 100644
--- a/unotools/source/config/fontcfg.cxx
+++ b/unotools/source/config/fontcfg.cxx
@@ -870,13 +870,13 @@ static const enum_convert pWidthNames[] =
{ "ultraexpanded", WIDTH_ULTRA_EXPANDED }
};
-void FontSubstConfiguration::fillSubstVector( const com::sun::star::uno::Reference< XNameAccess > xFont,
+void FontSubstConfiguration::fillSubstVector( const com::sun::star::uno::Reference< XNameAccess >& rFont,
const OUString& rType,
std::vector< OUString >& rSubstVector ) const
{
try
{
- Any aAny = xFont->getByName( rType );
+ Any aAny = rFont->getByName( rType );
if( aAny.getValueTypeClass() == TypeClass_STRING )
{
const OUString* pLine = (const OUString*)aAny.getValue();
@@ -919,13 +919,13 @@ void FontSubstConfiguration::fillSubstVector( const com::sun::star::uno::Referen
}
}
-FontWeight FontSubstConfiguration::getSubstWeight( const com::sun::star::uno::Reference< XNameAccess > xFont,
+FontWeight FontSubstConfiguration::getSubstWeight( const com::sun::star::uno::Reference< XNameAccess >& rFont,
const OUString& rType ) const
{
int weight = -1;
try
{
- Any aAny = xFont->getByName( rType );
+ Any aAny = rFont->getByName( rType );
if( aAny.getValueTypeClass() == TypeClass_STRING )
{
const OUString* pLine = (const OUString*)aAny.getValue();
@@ -951,13 +951,13 @@ FontWeight FontSubstConfiguration::getSubstWeight( const com::sun::star::uno::Re
return (FontWeight)( weight >= 0 ? pWeightNames[weight].nEnum : WEIGHT_DONTKNOW );
}
-FontWidth FontSubstConfiguration::getSubstWidth( const com::sun::star::uno::Reference< XNameAccess > xFont,
+FontWidth FontSubstConfiguration::getSubstWidth( const com::sun::star::uno::Reference< XNameAccess >& rFont,
const OUString& rType ) const
{
int width = -1;
try
{
- Any aAny = xFont->getByName( rType );
+ Any aAny = rFont->getByName( rType );
if( aAny.getValueTypeClass() == TypeClass_STRING )
{
const OUString* pLine = (const OUString*)aAny.getValue();
@@ -983,13 +983,13 @@ FontWidth FontSubstConfiguration::getSubstWidth( const com::sun::star::uno::Refe
return (FontWidth)( width >= 0 ? pWidthNames[width].nEnum : WIDTH_DONTKNOW );
}
-unsigned long FontSubstConfiguration::getSubstType( const com::sun::star::uno::Reference< XNameAccess > xFont,
+unsigned long FontSubstConfiguration::getSubstType( const com::sun::star::uno::Reference< XNameAccess >& rFont,
const OUString& rType ) const
{
unsigned long type = 0;
try
{
- Any aAny = xFont->getByName( rType );
+ Any aAny = rFont->getByName( rType );
if( aAny.getValueTypeClass() == TypeClass_STRING )
{
const OUString* pLine = (const OUString*)aAny.getValue();
More information about the Libreoffice-commits
mailing list