diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-04-08 17:45:08 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-04-08 17:45:08 +0200 |
commit | 9222f5d065bb2aafcfef93e77c58a82672a9ad22 (patch) | |
tree | 0dfad9f13099a73ecf3893e9cbdd5020b55cd7b3 /vbahelper/source/msforms | |
parent | c4dca26eafd60dc4c4f19e0be0b8e086108b3048 (diff) |
A UNO Any can't contain an Any
...and css::uno::makeAny<css::uno::Any>() was never meant to be used. Introduce
css::uno::toAny for the (template-code) cases that shall return an Any for both
Any and non-Any inputs.
Change-Id: Ifa977d73f1da71b2fedde7e8140b19497c4a0257
Diffstat (limited to 'vbahelper/source/msforms')
-rw-r--r-- | vbahelper/source/msforms/vbamultipage.cxx | 2 | ||||
-rw-r--r-- | vbahelper/source/msforms/vbauserform.cxx | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/vbahelper/source/msforms/vbamultipage.cxx b/vbahelper/source/msforms/vbamultipage.cxx index 4fa287efbc3d..2fb7016ac02e 100644 --- a/vbahelper/source/msforms/vbamultipage.cxx +++ b/vbahelper/source/msforms/vbamultipage.cxx @@ -102,7 +102,7 @@ ScVbaMultiPage::Pages( const uno::Any& index ) throw (uno::RuntimeException, std uno::Reference< XCollection > xColl( new ScVbaPages( this, mxContext, getPages( xContainer->getElementNames().getLength() ) ) ); if ( !index.hasValue() ) return uno::makeAny( xColl ); - return xColl->Item( uno::makeAny( index ), uno::Any() ); + return xColl->Item( index, uno::Any() ); } uno::Sequence< OUString > diff --git a/vbahelper/source/msforms/vbauserform.cxx b/vbahelper/source/msforms/vbauserform.cxx index 23bbd23f80be..8b6fe02e666f 100644 --- a/vbahelper/source/msforms/vbauserform.cxx +++ b/vbahelper/source/msforms/vbauserform.cxx @@ -285,7 +285,7 @@ ScVbaUserForm::Controls( const uno::Any& index ) throw (uno::RuntimeException, s uno::Reference< awt::XControl > xDialogControl( m_xDialog, uno::UNO_QUERY ); uno::Reference< XCollection > xControls( new ScVbaControls( this, mxContext, xDialogControl, m_xModel, mpGeometryHelper->getOffsetX(), mpGeometryHelper->getOffsetY() ) ); if ( index.hasValue() ) - return uno::makeAny( xControls->Item( index, uno::Any() ) ); + return xControls->Item( index, uno::Any() ); return uno::makeAny( xControls ); } |