diff options
Diffstat (limited to 'sc/source/ui/vba/vbastyles.cxx')
-rw-r--r-- | sc/source/ui/vba/vbastyles.cxx | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/sc/source/ui/vba/vbastyles.cxx b/sc/source/ui/vba/vbastyles.cxx index a4a1457882b7..2b8da076c2ba 100644 --- a/sc/source/ui/vba/vbastyles.cxx +++ b/sc/source/ui/vba/vbastyles.cxx @@ -33,7 +33,7 @@ lcl_createAPIStyleToVBAObject( const css::uno::Any& aObject, const uno::Referenc return uno::makeAny( xStyle ); } -ScVbaStyles::ScVbaStyles( const uno::Reference< XHelperInterface >& xParent, const uno::Reference< css::uno::XComponentContext > & xContext, const uno::Reference< frame::XModel >& xModel ) throw ( script::BasicErrorException ) : ScVbaStyles_BASE( xParent, xContext, uno::Reference< container::XIndexAccess >( ScVbaStyle::getStylesNameContainer( xModel ), uno::UNO_QUERY_THROW ) ), mxModel( xModel ), mxParent( xParent ) +ScVbaStyles::ScVbaStyles( const uno::Reference< XHelperInterface >& xParent, const uno::Reference< css::uno::XComponentContext > & xContext, const uno::Reference< frame::XModel >& xModel ) : ScVbaStyles_BASE( xParent, xContext, uno::Reference< container::XIndexAccess >( ScVbaStyle::getStylesNameContainer( xModel ), uno::UNO_QUERY_THROW ) ), mxModel( xModel ), mxParent( xParent ) { try { @@ -47,7 +47,7 @@ ScVbaStyles::ScVbaStyles( const uno::Reference< XHelperInterface >& xParent, con } uno::Sequence< OUString > -ScVbaStyles::getStyleNames() throw ( uno::RuntimeException ) +ScVbaStyles::getStyleNames() { return mxNameContainerCellStyles->getElementNames(); } @@ -59,7 +59,7 @@ ScVbaStyles::createCollectionObject(const uno::Any& aObject) } uno::Type SAL_CALL -ScVbaStyles::getElementType() throw (uno::RuntimeException) +ScVbaStyles::getElementType() { return cppu::UnoType<excel::XStyle>::get(); } @@ -76,11 +76,11 @@ class EnumWrapper : public EnumerationHelper_BASE sal_Int32 nIndex; public: EnumWrapper( const uno::Reference< container::XIndexAccess >& xIndexAccess, const uno::Reference<XHelperInterface >& xParent, const uno::Reference<uno::XComponentContext >& xContext, const uno::Reference<frame::XModel >& xModel ) : m_xIndexAccess( xIndexAccess ), m_xParent( xParent ), m_xContext( xContext ), m_xModel( xModel ), nIndex( 0 ) {} - virtual sal_Bool SAL_CALL hasMoreElements( ) throw (uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL hasMoreElements( ) override { return ( nIndex < m_xIndexAccess->getCount() ); } - virtual uno::Any SAL_CALL nextElement( ) throw (container::NoSuchElementException, lang::WrappedTargetException, uno::RuntimeException, std::exception) override + virtual uno::Any SAL_CALL nextElement( ) override { try { @@ -113,13 +113,13 @@ public: } uno::Reference< container::XEnumeration > SAL_CALL -ScVbaStyles::createEnumeration() throw (uno::RuntimeException) +ScVbaStyles::createEnumeration() { return new EnumWrapper( m_xIndexAccess, mxParent, mxContext, mxModel ); } uno::Reference< excel::XStyle > SAL_CALL -ScVbaStyles::Add( const OUString& _sName, const uno::Any& _aBasedOn ) throw (script::BasicErrorException, uno::RuntimeException, std::exception) +ScVbaStyles::Add( const OUString& _sName, const uno::Any& _aBasedOn ) { uno::Reference< excel::XStyle > aRet; try @@ -166,7 +166,7 @@ ScVbaStyles::Add( const OUString& _sName, const uno::Any& _aBasedOn ) throw (scr } void -ScVbaStyles::Delete(const OUString& _sStyleName) throw ( script::BasicErrorException ) +ScVbaStyles::Delete(const OUString& _sStyleName) { try { |