summaryrefslogtreecommitdiff
path: root/sc/source/ui/Accessibility
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2016-05-03 08:39:03 +0200
committerAshod Nakashian <ashod.nakashian@collabora.co.uk>2016-07-20 01:26:04 -0400
commita0e8e05008e143ee5e3bbc281d1c253c7e5ed136 (patch)
treeeaf5f70a067fd48704addd9f2b582624a2fb44ae /sc/source/ui/Accessibility
parent9c7cae1561cfe16226b1f16dce59f08a38da3ce0 (diff)
use Any constructor instead of temporaries
(cherry picked from commit 58a32075ca4f457f570af75aef368dd6c389aca7) Change-Id: Iffb82a2cee1a28d89eeea2b905aaa14086ee475a
Diffstat (limited to 'sc/source/ui/Accessibility')
-rw-r--r--sc/source/ui/Accessibility/AccessibleCellBase.cxx10
-rw-r--r--sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx12
2 files changed, 5 insertions, 17 deletions
diff --git a/sc/source/ui/Accessibility/AccessibleCellBase.cxx b/sc/source/ui/Accessibility/AccessibleCellBase.cxx
index 65e9a547e366..749400d6f6d2 100644
--- a/sc/source/ui/Accessibility/AccessibleCellBase.cxx
+++ b/sc/source/ui/Accessibility/AccessibleCellBase.cxx
@@ -267,20 +267,14 @@ uno::Any SAL_CALL
ScAccessibleCellBase::getMaximumValue( )
throw (uno::RuntimeException, std::exception)
{
- uno::Any aAny;
- aAny <<= DBL_MAX;
-
- return aAny;
+ return uno::Any(DBL_MAX);
}
uno::Any SAL_CALL
ScAccessibleCellBase::getMinimumValue( )
throw (uno::RuntimeException, std::exception)
{
- uno::Any aAny;
- aAny <<= -DBL_MAX;
-
- return aAny;
+ return uno::Any(-DBL_MAX);
}
//===== XServiceInfo ====================================================
diff --git a/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx b/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx
index 34c1ca250dd6..a1112b5dbeef 100644
--- a/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx
+++ b/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx
@@ -173,9 +173,7 @@ uno::Any SAL_CALL ScAccessiblePreviewHeaderCell::getCurrentValue() throw (uno::R
else
fValue = maCellPos.Row();
- uno::Any aAny;
- aAny <<= fValue;
- return aAny;
+ return uno::Any(fValue);
}
sal_Bool SAL_CALL ScAccessiblePreviewHeaderCell::setCurrentValue( const uno::Any& /* aNumber */ )
@@ -195,17 +193,13 @@ uno::Any SAL_CALL ScAccessiblePreviewHeaderCell::getMaximumValue() throw (uno::R
fValue = MAXCOL;
else
fValue = MAXROW;
- uno::Any aAny;
- aAny <<= fValue;
- return aAny;
+ return uno::Any(fValue);
}
uno::Any SAL_CALL ScAccessiblePreviewHeaderCell::getMinimumValue() throw (uno::RuntimeException, std::exception)
{
double fValue(0.0);
- uno::Any aAny;
- aAny <<= fValue;
- return aAny;
+ return uno::Any(fValue);
}
//===== XAccessibleComponent ============================================