diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-11-21 19:21:48 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-11-23 17:53:55 +0100 |
commit | baf08f569fb629211e4f9679bbb30fd61272dd46 (patch) | |
tree | 693f391f6b84a77c3bcaf5ed8f320d985a47d88e /sc/source/core/tool/scmatrix.cxx | |
parent | b4f666f2e677b05cab8395fe7972b45b15f60c3f (diff) |
enum ScMatrix::Op is unnecessary
Change-Id: If4ae97b43f012f1770213d99407ffaadac05f9de
Reviewed-on: https://gerrit.libreoffice.org/63756
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc/source/core/tool/scmatrix.cxx')
-rw-r--r-- | sc/source/core/tool/scmatrix.cxx | 21 |
1 files changed, 6 insertions, 15 deletions
diff --git a/sc/source/core/tool/scmatrix.cxx b/sc/source/core/tool/scmatrix.cxx index 5a736dd005b8..6cd50a560050 100644 --- a/sc/source/core/tool/scmatrix.cxx +++ b/sc/source/core/tool/scmatrix.cxx @@ -319,7 +319,7 @@ public: ScMatrixRef CompareMatrix( sc::Compare& rComp, size_t nMatPos, sc::CompareOptions* pOptions ) const; void GetDoubleArray( std::vector<double>& rArray, bool bEmptyAsZero ) const; - void MergeDoubleArray( std::vector<double>& rArray, ScMatrix::Op eOp ) const; + void MergeDoubleArrayMultiply( std::vector<double>& rArray ) const; template<typename T> void ApplyOperation(T aOp, ScMatrixImpl& rMat); @@ -2181,24 +2181,15 @@ void ScMatrixImpl::GetDoubleArray( std::vector<double>& rArray, bool bEmptyAsZer aFunc.swap(rArray); } -void ScMatrixImpl::MergeDoubleArray( std::vector<double>& rArray, ScMatrix::Op eOp ) const +void ScMatrixImpl::MergeDoubleArrayMultiply( std::vector<double>& rArray ) const { MatrixImplType::size_pair_type aSize = maMat.size(); size_t nSize = aSize.row*aSize.column; if (nSize != rArray.size()) return; - switch (eOp) - { - case ScMatrix::Mul: - { - MergeDoubleArrayFunc<ArrayMul> aFunc(rArray); - maMat.walk(std::move(aFunc)); - } - break; - default: - ; - } + MergeDoubleArrayFunc<ArrayMul> aFunc(rArray); + maMat.walk(std::move(aFunc)); } namespace Op { @@ -3289,9 +3280,9 @@ void ScMatrix::GetDoubleArray( std::vector<double>& rArray, bool bEmptyAsZero ) pImpl->GetDoubleArray(rArray, bEmptyAsZero); } -void ScMatrix::MergeDoubleArray( std::vector<double>& rArray, Op eOp ) const +void ScMatrix::MergeDoubleArrayMultiply( std::vector<double>& rArray ) const { - pImpl->MergeDoubleArray(rArray, eOp); + pImpl->MergeDoubleArrayMultiply(rArray); } namespace matop { |