summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2016-07-18 09:22:27 +0200
committerNoel Grandin <noelgrandin@gmail.com>2016-07-27 06:48:25 +0000
commit508c95f1b655d9cfa6be37a5a9de9aff6fd383bf (patch)
treed1c8626818cbf26a699875ae2d82f751a1657e92 /sfx2
parent9f4af777a832d8a0b9a21d793d421fa6228131e0 (diff)
improve passstuffbyref return analysis
Change-Id: I4258bcc97273d8bb7a8c4879fac02a427f76e18c Reviewed-on: https://gerrit.libreoffice.org/27317 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/inc/guisaveas.hxx6
-rw-r--r--sfx2/source/appl/newhelp.cxx2
-rw-r--r--sfx2/source/appl/newhelp.hxx2
-rw-r--r--sfx2/source/appl/sfxhelp.cxx2
-rw-r--r--sfx2/source/control/thumbnailviewitem.cxx2
-rw-r--r--sfx2/source/doc/DocumentMetadataAccess.cxx2
-rw-r--r--sfx2/source/doc/docfile.cxx2
-rw-r--r--sfx2/source/doc/doctemplateslocal.cxx2
-rw-r--r--sfx2/source/doc/doctemplateslocal.hxx2
-rw-r--r--sfx2/source/doc/guisaveas.cxx22
-rw-r--r--sfx2/source/doc/sfxbasemodel.cxx2
11 files changed, 23 insertions, 23 deletions
diff --git a/sfx2/inc/guisaveas.hxx b/sfx2/inc/guisaveas.hxx
index 1e516c48d187..5ca7743397d2 100644
--- a/sfx2/inc/guisaveas.hxx
+++ b/sfx2/inc/guisaveas.hxx
@@ -50,9 +50,9 @@ private:
css::uno::Reference< css::container::XContainerQuery > m_xFilterQuery;
css::uno::Reference< css::frame::XModuleManager2 > m_xModuleManager;
- css::uno::Reference< css::container::XNameAccess > GetFilterConfiguration();
- css::uno::Reference< css::container::XContainerQuery > GetFilterQuery();
- css::uno::Reference< css::frame::XModuleManager2 > GetModuleManager();
+ css::uno::Reference< css::container::XNameAccess > const & GetFilterConfiguration();
+ css::uno::Reference< css::container::XContainerQuery > const & GetFilterQuery();
+ css::uno::Reference< css::frame::XModuleManager2 > const & GetModuleManager();
public:
SfxStoringHelper();
diff --git a/sfx2/source/appl/newhelp.cxx b/sfx2/source/appl/newhelp.cxx
index 69d360bb369a..9ff07b002498 100644
--- a/sfx2/source/appl/newhelp.cxx
+++ b/sfx2/source/appl/newhelp.cxx
@@ -2094,7 +2094,7 @@ void SfxHelpTextWindow_Impl::SetOnStartupBoxPosition()
}
-Reference< XBreakIterator > SfxHelpTextWindow_Impl::GetBreakIterator()
+Reference< XBreakIterator > const & SfxHelpTextWindow_Impl::GetBreakIterator()
{
if ( !xBreakIterator.is() )
xBreakIterator = vcl::unohelper::CreateBreakIterator();
diff --git a/sfx2/source/appl/newhelp.hxx b/sfx2/source/appl/newhelp.hxx
index d340a8417e82..c23fcb7c58c2 100644
--- a/sfx2/source/appl/newhelp.hxx
+++ b/sfx2/source/appl/newhelp.hxx
@@ -447,7 +447,7 @@ private:
void InitOnStartupBox();
void SetOnStartupBoxPosition();
- css::uno::Reference< css::i18n::XBreakIterator >
+ css::uno::Reference< css::i18n::XBreakIterator > const &
GetBreakIterator();
css::uno::Reference< css::text::XTextRange >
getCursor() const;
diff --git a/sfx2/source/appl/sfxhelp.cxx b/sfx2/source/appl/sfxhelp.cxx
index 33121b8fb224..8e10bb7dd8c1 100644
--- a/sfx2/source/appl/sfxhelp.cxx
+++ b/sfx2/source/appl/sfxhelp.cxx
@@ -98,7 +98,7 @@ void NoHelpErrorBox::RequestHelp( const HelpEvent& )
static bool impl_hasHelpInstalled( const OUString &rLang );
/// Return the locale we prefer for displaying help
-static OUString HelpLocaleString()
+static OUString const & HelpLocaleString()
{
static OUString aLocaleStr;
if (aLocaleStr.isEmpty())
diff --git a/sfx2/source/control/thumbnailviewitem.cxx b/sfx2/source/control/thumbnailviewitem.cxx
index 3690ae020cab..33a5b2d922f1 100644
--- a/sfx2/source/control/thumbnailviewitem.cxx
+++ b/sfx2/source/control/thumbnailviewitem.cxx
@@ -106,7 +106,7 @@ void ThumbnailViewItem::setTitle (const OUString& rTitle)
maTitle = rTitle;
}
-uno::Reference< accessibility::XAccessible > ThumbnailViewItem::GetAccessible( bool bIsTransientChildrenDisabled )
+uno::Reference< accessibility::XAccessible > const & ThumbnailViewItem::GetAccessible( bool bIsTransientChildrenDisabled )
{
if( !mxAcc.is() )
mxAcc = new ThumbnailViewItemAcc( this, bIsTransientChildrenDisabled );
diff --git a/sfx2/source/doc/DocumentMetadataAccess.cxx b/sfx2/source/doc/DocumentMetadataAccess.cxx
index 6c1813f160ea..23fea7939cec 100644
--- a/sfx2/source/doc/DocumentMetadataAccess.cxx
+++ b/sfx2/source/doc/DocumentMetadataAccess.cxx
@@ -208,7 +208,7 @@ struct DocumentMetadataAccess_Impl
// this is... a hack.
template<sal_Int16 Constant>
-/*static*/ uno::Reference<rdf::XURI>
+/*static*/ uno::Reference<rdf::XURI> const &
getURI(uno::Reference< uno::XComponentContext > const & i_xContext)
{
static uno::Reference< rdf::XURI > xURI(
diff --git a/sfx2/source/doc/docfile.cxx b/sfx2/source/doc/docfile.cxx
index c4ce8719238c..7e8283b08552 100644
--- a/sfx2/source/doc/docfile.cxx
+++ b/sfx2/source/doc/docfile.cxx
@@ -2645,7 +2645,7 @@ const std::shared_ptr<const SfxFilter>& SfxMedium::GetFilter() const
}
-std::shared_ptr<const SfxFilter> SfxMedium::GetOrigFilter() const
+std::shared_ptr<const SfxFilter> const & SfxMedium::GetOrigFilter() const
{
return pImpl->pOrigFilter ? pImpl->pOrigFilter : pImpl->m_pFilter;
}
diff --git a/sfx2/source/doc/doctemplateslocal.cxx b/sfx2/source/doc/doctemplateslocal.cxx
index 1cffac39ee97..cb82f0d24e16 100644
--- a/sfx2/source/doc/doctemplateslocal.cxx
+++ b/sfx2/source/doc/doctemplateslocal.cxx
@@ -123,7 +123,7 @@ DocTemplLocaleHelper::~DocTemplLocaleHelper()
}
-std::vector< beans::StringPair > DocTemplLocaleHelper::GetParsingResult()
+std::vector< beans::StringPair > const & DocTemplLocaleHelper::GetParsingResult()
{
if ( !m_aElementsSeq.empty() )
throw uno::RuntimeException(); // the parsing has still not finished!
diff --git a/sfx2/source/doc/doctemplateslocal.hxx b/sfx2/source/doc/doctemplateslocal.hxx
index a98ae0377d7c..3b41fc87a5b4 100644
--- a/sfx2/source/doc/doctemplateslocal.hxx
+++ b/sfx2/source/doc/doctemplateslocal.hxx
@@ -40,7 +40,7 @@ class DocTemplLocaleHelper : public cppu::WeakImplHelper < css::xml::sax::XDocum
std::vector< OUString > m_aElementsSeq; // stack of elements being parsed
DocTemplLocaleHelper();
- std::vector< css::beans::StringPair > GetParsingResult();
+ std::vector< css::beans::StringPair > const & GetParsingResult();
static std::vector< css::beans::StringPair > SAL_CALL ReadLocalizationSequence_Impl( const css::uno::Reference< css::io::XInputStream >& xInStream, const OUString& aStringID, const css::uno::Reference< css::uno::XComponentContext >& xContext )
throw( css::uno::Exception );
diff --git a/sfx2/source/doc/guisaveas.cxx b/sfx2/source/doc/guisaveas.cxx
index 440185028461..9f99eab33a98 100644
--- a/sfx2/source/doc/guisaveas.cxx
+++ b/sfx2/source/doc/guisaveas.cxx
@@ -275,9 +275,9 @@ public:
void FreeDocumentProps();
- uno::Reference< frame::XModel > GetModel();
- uno::Reference< frame::XStorable > GetStorable();
- uno::Reference< frame::XStorable2 > GetStorable2();
+ uno::Reference< frame::XModel > const & GetModel();
+ uno::Reference< frame::XStorable > const & GetStorable();
+ uno::Reference< frame::XStorable2 > const & GetStorable2();
::comphelper::SequenceAsHashMap& GetMediaDescr() { return m_aMediaDescrHM; }
@@ -285,7 +285,7 @@ public:
const ::comphelper::SequenceAsHashMap& GetDocProps();
- OUString GetModuleName();
+ OUString const & GetModuleName();
const ::comphelper::SequenceAsHashMap& GetModuleProps();
void CheckInteractionHandler();
@@ -382,7 +382,7 @@ void ModelData_Impl::FreeDocumentProps()
}
-uno::Reference< frame::XModel > ModelData_Impl::GetModel()
+uno::Reference< frame::XModel > const & ModelData_Impl::GetModel()
{
if ( !m_xModel.is() )
throw uno::RuntimeException();
@@ -391,7 +391,7 @@ uno::Reference< frame::XModel > ModelData_Impl::GetModel()
}
-uno::Reference< frame::XStorable > ModelData_Impl::GetStorable()
+uno::Reference< frame::XStorable > const & ModelData_Impl::GetStorable()
{
if ( !m_xStorable.is() )
{
@@ -404,7 +404,7 @@ uno::Reference< frame::XStorable > ModelData_Impl::GetStorable()
}
-uno::Reference< frame::XStorable2 > ModelData_Impl::GetStorable2()
+uno::Reference< frame::XStorable2 > const & ModelData_Impl::GetStorable2()
{
if ( !m_xStorable2.is() )
{
@@ -426,7 +426,7 @@ const ::comphelper::SequenceAsHashMap& ModelData_Impl::GetDocProps()
}
-OUString ModelData_Impl::GetModuleName()
+OUString const & ModelData_Impl::GetModuleName()
{
if ( m_aModuleName.isEmpty() )
{
@@ -1265,7 +1265,7 @@ SfxStoringHelper::SfxStoringHelper()
}
-uno::Reference< container::XNameAccess > SfxStoringHelper::GetFilterConfiguration()
+uno::Reference< container::XNameAccess > const & SfxStoringHelper::GetFilterConfiguration()
{
if ( !m_xFilterCFG.is() )
{
@@ -1280,7 +1280,7 @@ uno::Reference< container::XNameAccess > SfxStoringHelper::GetFilterConfiguratio
}
-uno::Reference< container::XContainerQuery > SfxStoringHelper::GetFilterQuery()
+uno::Reference< container::XContainerQuery > const & SfxStoringHelper::GetFilterQuery()
{
if ( !m_xFilterQuery.is() )
{
@@ -1293,7 +1293,7 @@ uno::Reference< container::XContainerQuery > SfxStoringHelper::GetFilterQuery()
}
-uno::Reference< css::frame::XModuleManager2 > SfxStoringHelper::GetModuleManager()
+uno::Reference< css::frame::XModuleManager2 > const & SfxStoringHelper::GetModuleManager()
{
if ( !m_xModuleManager.is() )
{
diff --git a/sfx2/source/doc/sfxbasemodel.cxx b/sfx2/source/doc/sfxbasemodel.cxx
index ab6d33354131..17c8411d462a 100644
--- a/sfx2/source/doc/sfxbasemodel.cxx
+++ b/sfx2/source/doc/sfxbasemodel.cxx
@@ -3410,7 +3410,7 @@ Reference< script::provider::XScriptProvider > SAL_CALL SfxBaseModel::getScriptP
// XUIConfigurationManagerSupplier
-OUString SfxBaseModel::getRuntimeUID() const
+OUString const & SfxBaseModel::getRuntimeUID() const
{
OSL_ENSURE( !m_pData->m_sRuntimeUID.isEmpty(),
"SfxBaseModel::getRuntimeUID - ID is empty!" );