diff options
author | Jochen Nitschke <j.nitschke+logerrit@ok.de> | 2017-07-02 17:10:53 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-07-07 08:31:48 +0200 |
commit | db4741043d09437af871fa8ea9849ec37e946f9b (patch) | |
tree | 3ed043060e283bc6b3b386bacc4a6ff84e42f3ab /chart2/source | |
parent | 307e528275cb91776e8f5560b3137c3c1649b39c (diff) |
C++11 remove std::binary_function bases from functors
std::binary_function is deprecated since C++11 and removed in C++17
90% done with regexp magic.
removed obsolete <functional> includes.
The std::binary_function base class was used by deprecated
std::bind2nd, this was solved in individual commits.
The members first_argument_type and second_argument_type were used
in chart2/source/controller/dialogs/DataBrowserModel.cxx:
DataBrowserModel::implColumnLess and are inlined in this commit.
Change-Id: I60ded60a8d4afd59e15ac15a58e18d2498c9be5a
Reviewed-on: https://gerrit.libreoffice.org/39659
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'chart2/source')
-rw-r--r-- | chart2/source/controller/dialogs/DataBrowserModel.cxx | 5 | ||||
-rw-r--r-- | chart2/source/controller/dialogs/DialogModel.cxx | 4 | ||||
-rw-r--r-- | chart2/source/inc/RegressionCalculationHelper.hxx | 13 | ||||
-rw-r--r-- | chart2/source/tools/InternalDataProvider.cxx | 4 | ||||
-rw-r--r-- | chart2/source/view/axes/VCartesianAxis.cxx | 4 |
5 files changed, 13 insertions, 17 deletions
diff --git a/chart2/source/controller/dialogs/DataBrowserModel.cxx b/chart2/source/controller/dialogs/DataBrowserModel.cxx index 9dc2478f76f9..bedd47a98b2d 100644 --- a/chart2/source/controller/dialogs/DataBrowserModel.cxx +++ b/chart2/source/controller/dialogs/DataBrowserModel.cxx @@ -234,10 +234,9 @@ struct DataBrowserModel::tDataColumn {} }; -struct DataBrowserModel::implColumnLess : public std::binary_function< - DataBrowserModel::tDataColumn, DataBrowserModel::tDataColumn, bool > +struct DataBrowserModel::implColumnLess { - bool operator() ( const first_argument_type & rLeft, const second_argument_type & rRight ) + bool operator() ( const DataBrowserModel::tDataColumn & rLeft, const DataBrowserModel::tDataColumn & rRight ) { if( rLeft.m_xLabeledDataSequence.is() && rRight.m_xLabeledDataSequence.is()) { diff --git a/chart2/source/controller/dialogs/DialogModel.cxx b/chart2/source/controller/dialogs/DialogModel.cxx index f39c49ac78e1..a9445be5d90d 100644 --- a/chart2/source/controller/dialogs/DialogModel.cxx +++ b/chart2/source/controller/dialogs/DialogModel.cxx @@ -46,7 +46,6 @@ #include <utility> #include <algorithm> #include <iterator> -#include <functional> #include <numeric> using namespace ::com::sun::star; @@ -349,8 +348,7 @@ Reference< XDataSeries > lcl_CreateNewSeries( return xResult; } -struct lcl_addSeriesNumber : public std::binary_function< - sal_Int32, Reference< XDataSeriesContainer >, sal_Int32 > +struct lcl_addSeriesNumber { sal_Int32 operator() ( sal_Int32 nCurrentNumber, const Reference< XDataSeriesContainer > & xCnt ) const { diff --git a/chart2/source/inc/RegressionCalculationHelper.hxx b/chart2/source/inc/RegressionCalculationHelper.hxx index 60ab60ddf621..084f49623c42 100644 --- a/chart2/source/inc/RegressionCalculationHelper.hxx +++ b/chart2/source/inc/RegressionCalculationHelper.hxx @@ -23,7 +23,6 @@ #include <utility> #include <algorithm> -#include <functional> #include <vector> namespace chart @@ -60,7 +59,7 @@ tDoubleVectorPair return aResult; } -class isValid : public std::binary_function< double, double, bool > +class isValid { public: bool operator()( double x, double y ) @@ -71,7 +70,7 @@ public: } }; -class isValidAndXPositive : public std::binary_function< double, double, bool > +class isValidAndXPositive { public: bool operator()( double x, double y ) @@ -83,7 +82,7 @@ public: } }; -class isValidAndYPositive : public std::binary_function< double, double, bool > +class isValidAndYPositive { public: bool operator()( double x, double y ) @@ -95,7 +94,7 @@ public: } }; -class isValidAndYNegative : public std::binary_function< double, double, bool > +class isValidAndYNegative { public: bool operator()( double x, double y ) @@ -107,7 +106,7 @@ public: } }; -class isValidAndBothPositive : public std::binary_function< double, double, bool > +class isValidAndBothPositive { public: bool operator()( double x, double y ) @@ -120,7 +119,7 @@ public: } }; -class isValidAndXPositiveAndYNegative : public std::binary_function< double, double, bool > +class isValidAndXPositiveAndYNegative { public: bool operator()( double x, double y ) diff --git a/chart2/source/tools/InternalDataProvider.cxx b/chart2/source/tools/InternalDataProvider.cxx index dfa434f41ea6..c313475c0ed4 100644 --- a/chart2/source/tools/InternalDataProvider.cxx +++ b/chart2/source/tools/InternalDataProvider.cxx @@ -219,7 +219,7 @@ private: sal_Int32 m_nLevel; }; -struct lcl_setAnyAtLevel : public std::binary_function< vector< uno::Any >, uno::Any, vector< uno::Any > > +struct lcl_setAnyAtLevel { public: @@ -239,7 +239,7 @@ private: sal_Int32 m_nLevel; }; -struct lcl_setAnyAtLevelFromStringSequence : public std::binary_function< vector< uno::Any >, OUString, vector< uno::Any > > +struct lcl_setAnyAtLevelFromStringSequence { public: diff --git a/chart2/source/view/axes/VCartesianAxis.cxx b/chart2/source/view/axes/VCartesianAxis.cxx index c95c558cb921..6b355b3734b4 100644 --- a/chart2/source/view/axes/VCartesianAxis.cxx +++ b/chart2/source/view/axes/VCartesianAxis.cxx @@ -1093,7 +1093,7 @@ VCartesianAxis::ScreenPosAndLogicPos VCartesianAxis::getScreenPosAndLogicPos( do } typedef std::vector< VCartesianAxis::ScreenPosAndLogicPos > tScreenPosAndLogicPosList; -struct lcl_LessXPos : std::binary_function< VCartesianAxis::ScreenPosAndLogicPos, VCartesianAxis::ScreenPosAndLogicPos, bool > +struct lcl_LessXPos { bool operator() ( const VCartesianAxis::ScreenPosAndLogicPos& rPos1, const VCartesianAxis::ScreenPosAndLogicPos& rPos2 ) { @@ -1101,7 +1101,7 @@ struct lcl_LessXPos : std::binary_function< VCartesianAxis::ScreenPosAndLogicPos } }; -struct lcl_GreaterYPos : std::binary_function< VCartesianAxis::ScreenPosAndLogicPos, VCartesianAxis::ScreenPosAndLogicPos, bool > +struct lcl_GreaterYPos { bool operator() ( const VCartesianAxis::ScreenPosAndLogicPos& rPos1, const VCartesianAxis::ScreenPosAndLogicPos& rPos2 ) { |