summaryrefslogtreecommitdiffstats
path: root/chart2
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 /chart2
parentDon't Update() and Flush() status bar draws (diff)
downloadcore-508c95f1b655d9cfa6be37a5a9de9aff6fd383bf.tar.gz
core-508c95f1b655d9cfa6be37a5a9de9aff6fd383bf.zip
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 'chart2')
-rw-r--r--chart2/inc/ChartModel.hxx2
-rw-r--r--chart2/qa/extras/chart2export.cxx2
-rw-r--r--chart2/source/controller/chartapiwrapper/Chart2ModelContact.cxx2
-rw-r--r--chart2/source/controller/chartapiwrapper/Chart2ModelContact.hxx2
-rw-r--r--chart2/source/controller/dialogs/DialogModel.cxx2
-rw-r--r--chart2/source/controller/dialogs/DialogModel.hxx2
-rw-r--r--chart2/source/controller/dialogs/RangeSelectionHelper.cxx2
-rw-r--r--chart2/source/controller/inc/RangeSelectionHelper.hxx2
-rw-r--r--chart2/source/inc/ExplicitCategoriesProvider.hxx2
-rw-r--r--chart2/source/inc/chartview/DrawModelWrapper.hxx4
-rw-r--r--chart2/source/model/main/ChartModel.cxx2
-rw-r--r--chart2/source/tools/ExplicitCategoriesProvider.cxx2
-rw-r--r--chart2/source/view/inc/VDataSeries.hxx4
-rw-r--r--chart2/source/view/main/DrawModelWrapper.cxx4
-rw-r--r--chart2/source/view/main/DummyXShape.cxx2
-rw-r--r--chart2/source/view/main/VDataSeries.cxx4
16 files changed, 20 insertions, 20 deletions
diff --git a/chart2/inc/ChartModel.hxx b/chart2/inc/ChartModel.hxx
index b3caaad412c4..92c6c05d5c5f 100644
--- a/chart2/inc/ChartModel.hxx
+++ b/chart2/inc/ChartModel.hxx
@@ -568,7 +568,7 @@ public:
throw (css::uno::RuntimeException, std::exception) override;
// normal methods
- css::uno::Reference< css::util::XNumberFormatsSupplier >
+ css::uno::Reference< css::util::XNumberFormatsSupplier > const &
getNumberFormatsSupplier();
const css::uno::Reference< css::uno::XInterface >& getChartView() { return xChartView;}
diff --git a/chart2/qa/extras/chart2export.cxx b/chart2/qa/extras/chart2export.cxx
index 846daa78b34d..6f8004dbfbc4 100644
--- a/chart2/qa/extras/chart2export.cxx
+++ b/chart2/qa/extras/chart2export.cxx
@@ -200,7 +200,7 @@ public:
}
};
-OUString findChartFile(const OUString& rDir, uno::Reference< container::XNameAccess > const & xNames )
+OUString const & findChartFile(const OUString& rDir, uno::Reference< container::XNameAccess > const & xNames )
{
uno::Sequence<OUString> rNames = xNames->getElementNames();
OUString* pElement = std::find_if(rNames.begin(), rNames.end(), CheckForChartName(rDir));
diff --git a/chart2/source/controller/chartapiwrapper/Chart2ModelContact.cxx b/chart2/source/controller/chartapiwrapper/Chart2ModelContact.cxx
index 68c57a5aa11e..904ec57ce11c 100644
--- a/chart2/source/controller/chartapiwrapper/Chart2ModelContact.cxx
+++ b/chart2/source/controller/chartapiwrapper/Chart2ModelContact.cxx
@@ -98,7 +98,7 @@ Reference< chart2::XDiagram > Chart2ModelContact::getChart2Diagram() const
return ChartModelHelper::findDiagram( this->getChartModel() );
}
-uno::Reference< lang::XUnoTunnel > Chart2ModelContact::getChartView() const
+uno::Reference< lang::XUnoTunnel > const & Chart2ModelContact::getChartView() const
{
if(!m_xChartView.is())
{
diff --git a/chart2/source/controller/chartapiwrapper/Chart2ModelContact.hxx b/chart2/source/controller/chartapiwrapper/Chart2ModelContact.hxx
index 8b64b5f0fb96..a0e9305676b2 100644
--- a/chart2/source/controller/chartapiwrapper/Chart2ModelContact.hxx
+++ b/chart2/source/controller/chartapiwrapper/Chart2ModelContact.hxx
@@ -126,7 +126,7 @@ public:
private: //methods
ExplicitValueProvider* getExplicitValueProvider() const;
- css::uno::Reference< css::lang::XUnoTunnel > getChartView() const;
+ css::uno::Reference< css::lang::XUnoTunnel > const & getChartView() const;
public: //member
css::uno::Reference< css::uno::XComponentContext > m_xContext;
diff --git a/chart2/source/controller/dialogs/DialogModel.cxx b/chart2/source/controller/dialogs/DialogModel.cxx
index 2503d858315a..08f391de5035 100644
--- a/chart2/source/controller/dialogs/DialogModel.cxx
+++ b/chart2/source/controller/dialogs/DialogModel.cxx
@@ -396,7 +396,7 @@ void DialogModel::setTemplate(
m_xTemplate = xTemplate;
}
-::std::shared_ptr< RangeSelectionHelper >
+::std::shared_ptr< RangeSelectionHelper > const &
DialogModel::getRangeSelectionHelper() const
{
if( ! m_spRangeSelectionHelper.get())
diff --git a/chart2/source/controller/dialogs/DialogModel.hxx b/chart2/source/controller/dialogs/DialogModel.hxx
index a863b614779d..73fe00a44efb 100644
--- a/chart2/source/controller/dialogs/DialogModel.hxx
+++ b/chart2/source/controller/dialogs/DialogModel.hxx
@@ -76,7 +76,7 @@ public:
void setTemplate(
const css::uno::Reference< css::chart2::XChartTypeTemplate > & xTemplate );
- std::shared_ptr< RangeSelectionHelper >
+ std::shared_ptr< RangeSelectionHelper > const &
getRangeSelectionHelper() const;
css::uno::Reference< css::frame::XModel >
diff --git a/chart2/source/controller/dialogs/RangeSelectionHelper.cxx b/chart2/source/controller/dialogs/RangeSelectionHelper.cxx
index c092b32772d6..013c625fa028 100644
--- a/chart2/source/controller/dialogs/RangeSelectionHelper.cxx
+++ b/chart2/source/controller/dialogs/RangeSelectionHelper.cxx
@@ -54,7 +54,7 @@ bool RangeSelectionHelper::hasRangeSelection()
return getRangeSelection().is();
}
-Reference< sheet::XRangeSelection > RangeSelectionHelper::getRangeSelection()
+Reference< sheet::XRangeSelection > const & RangeSelectionHelper::getRangeSelection()
{
if( !m_xRangeSelection.is() &&
m_xChartDocument.is() )
diff --git a/chart2/source/controller/inc/RangeSelectionHelper.hxx b/chart2/source/controller/inc/RangeSelectionHelper.hxx
index 049c19eac9d3..0b2ab7153e52 100644
--- a/chart2/source/controller/inc/RangeSelectionHelper.hxx
+++ b/chart2/source/controller/inc/RangeSelectionHelper.hxx
@@ -43,7 +43,7 @@ public:
~RangeSelectionHelper();
bool hasRangeSelection();
- css::uno::Reference< css::sheet::XRangeSelection > getRangeSelection();
+ css::uno::Reference< css::sheet::XRangeSelection > const & getRangeSelection();
void raiseRangeSelectionDocument();
bool chooseRange(
const OUString & aCurrentRange,
diff --git a/chart2/source/inc/ExplicitCategoriesProvider.hxx b/chart2/source/inc/ExplicitCategoriesProvider.hxx
index 60de98f6a00a..54763be4e8a2 100644
--- a/chart2/source/inc/ExplicitCategoriesProvider.hxx
+++ b/chart2/source/inc/ExplicitCategoriesProvider.hxx
@@ -59,7 +59,7 @@ public:
css::uno::Reference< css::chart2::data::XDataSequence > getOriginalCategories();
- css::uno::Sequence< OUString > getSimpleCategories();
+ css::uno::Sequence< OUString > const & getSimpleCategories();
const std::vector<ComplexCategory>* getCategoriesByLevel( sal_Int32 nLevel );
static OUString getCategoryByIndex(
diff --git a/chart2/source/inc/chartview/DrawModelWrapper.hxx b/chart2/source/inc/chartview/DrawModelWrapper.hxx
index 20cbcae441c3..91ac42c19734 100644
--- a/chart2/source/inc/chartview/DrawModelWrapper.hxx
+++ b/chart2/source/inc/chartview/DrawModelWrapper.hxx
@@ -51,11 +51,11 @@ public:
css::uno::Reference< css::lang::XMultiServiceFactory > getShapeFactory();
// the main page will contain the normal view objects
- css::uno::Reference< css::drawing::XDrawPage > getMainDrawPage();
+ css::uno::Reference< css::drawing::XDrawPage > const & getMainDrawPage();
SAL_DLLPRIVATE void clearMainDrawPage();
// the extra page is not visible, but contains some extras like the symbols for data points
- css::uno::Reference< css::drawing::XDrawPage > getHiddenDrawPage();
+ css::uno::Reference< css::drawing::XDrawPage > const & getHiddenDrawPage();
static css::uno::Reference< css::drawing::XShapes >
getChartRootShape( const css::uno::Reference< css::drawing::XDrawPage>& xPage );
diff --git a/chart2/source/model/main/ChartModel.cxx b/chart2/source/model/main/ChartModel.cxx
index 48ec54304805..b9647eb16b67 100644
--- a/chart2/source/model/main/ChartModel.cxx
+++ b/chart2/source/model/main/ChartModel.cxx
@@ -1301,7 +1301,7 @@ Sequence< OUString > SAL_CALL ChartModel::getAvailableServiceNames()
return aResult;
}
-Reference< util::XNumberFormatsSupplier > ChartModel::getNumberFormatsSupplier()
+Reference< util::XNumberFormatsSupplier > const & ChartModel::getNumberFormatsSupplier()
{
if( !m_xNumberFormatsSupplier.is() )
{
diff --git a/chart2/source/tools/ExplicitCategoriesProvider.cxx b/chart2/source/tools/ExplicitCategoriesProvider.cxx
index fc45f1f6d387..d2f24524873b 100644
--- a/chart2/source/tools/ExplicitCategoriesProvider.cxx
+++ b/chart2/source/tools/ExplicitCategoriesProvider.cxx
@@ -504,7 +504,7 @@ void ExplicitCategoriesProvider::init()
}
}
-Sequence< OUString > ExplicitCategoriesProvider::getSimpleCategories()
+Sequence< OUString > const & ExplicitCategoriesProvider::getSimpleCategories()
{
if( !m_bIsExplicitCategoriesInited )
{
diff --git a/chart2/source/view/inc/VDataSeries.hxx b/chart2/source/view/inc/VDataSeries.hxx
index 7231f0515338..f547cb4013ce 100644
--- a/chart2/source/view/inc/VDataSeries.hxx
+++ b/chart2/source/view/inc/VDataSeries.hxx
@@ -94,8 +94,8 @@ public:
bool hasPropertyMapping( const OUString& rPropName ) const;
- css::uno::Sequence< double > getAllX() const;
- css::uno::Sequence< double > getAllY() const;
+ css::uno::Sequence< double > const & getAllX() const;
+ css::uno::Sequence< double > const & getAllY() const;
double getXMeanValue() const;
double getYMeanValue() const;
diff --git a/chart2/source/view/main/DrawModelWrapper.cxx b/chart2/source/view/main/DrawModelWrapper.cxx
index f787a4906084..d62886091cce 100644
--- a/chart2/source/view/main/DrawModelWrapper.cxx
+++ b/chart2/source/view/main/DrawModelWrapper.cxx
@@ -163,7 +163,7 @@ uno::Reference< lang::XMultiServiceFactory > DrawModelWrapper::getShapeFactory()
return xShapeFactory;
}
-uno::Reference< drawing::XDrawPage > DrawModelWrapper::getMainDrawPage()
+uno::Reference< drawing::XDrawPage > const & DrawModelWrapper::getMainDrawPage()
{
if (m_xMainDrawPage.is())
return m_xMainDrawPage;
@@ -192,7 +192,7 @@ uno::Reference< drawing::XDrawPage > DrawModelWrapper::getMainDrawPage()
// AbstractShapeFactory::getOrCreateShapeFactory(this->getShapeFactory())->getOrCreateChartRootShape( m_xMainDrawPage );
return m_xMainDrawPage;
}
-uno::Reference< drawing::XDrawPage > DrawModelWrapper::getHiddenDrawPage()
+uno::Reference< drawing::XDrawPage > const & DrawModelWrapper::getHiddenDrawPage()
{
if( !m_xHiddenDrawPage.is() )
{
diff --git a/chart2/source/view/main/DummyXShape.cxx b/chart2/source/view/main/DummyXShape.cxx
index 544b272ea267..579765ab18da 100644
--- a/chart2/source/view/main/DummyXShape.cxx
+++ b/chart2/source/view/main/DummyXShape.cxx
@@ -304,7 +304,7 @@ OUString SAL_CALL DummyXShape::getImplementationName()
namespace {
-uno::Sequence< OUString > listSupportedServices()
+uno::Sequence< OUString > const & listSupportedServices()
{
static const uno::Sequence< OUString > aSupportedServices{
"com.sun.star.drawing.Shape",
diff --git a/chart2/source/view/main/VDataSeries.cxx b/chart2/source/view/main/VDataSeries.cxx
index 6b98b7a6f1ab..81e7bd2a2ce1 100644
--- a/chart2/source/view/main/VDataSeries.cxx
+++ b/chart2/source/view/main/VDataSeries.cxx
@@ -725,7 +725,7 @@ double VDataSeries::getMaximumofAllDifferentYValues( sal_Int32 index ) const
return fMax;
}
-uno::Sequence< double > VDataSeries::getAllX() const
+uno::Sequence< double > const & VDataSeries::getAllX() const
{
if(!m_aValues_X.is() && !m_aValues_X.getLength() && m_nPointCount)
{
@@ -738,7 +738,7 @@ uno::Sequence< double > VDataSeries::getAllX() const
return m_aValues_X.Doubles;
}
-uno::Sequence< double > VDataSeries::getAllY() const
+uno::Sequence< double > const & VDataSeries::getAllY() const
{
if(!m_aValues_Y.is() && !m_aValues_Y.getLength() && m_nPointCount)
{