summaryrefslogtreecommitdiff
path: root/sw/source/ui/vba/vbarows.cxx
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2017-01-26 12:28:58 +0100
committerStephan Bergmann <sbergman@redhat.com>2017-01-26 12:54:43 +0000
commite57ca02849c3d87142ff5ff9099a212e72b8139c (patch)
treebcce66b27261553c308779f3e8663a269ed3a671 /sw/source/ui/vba/vbarows.cxx
parent8802ebd5172ec4bc412a59d136c82b77ab452281 (diff)
Remove dynamic exception specifications
...(for now, from LIBO_INTERNAL_CODE only). See the mail thread starting at <https://lists.freedesktop.org/archives/libreoffice/2017-January/076665.html> "Dynamic Exception Specifications" for details. Most changes have been done automatically by the rewriting loplugin:dynexcspec (after enabling the rewriting mode, to be committed shortly). The way it only removes exception specs from declarations if it also sees a definition, it identified some dead declarations-w/o-definitions (that have been removed manually) and some cases where a definition appeared in multiple include files (which have also been cleaned up manually). There's also been cases of macro paramters (that were used to abstract over exception specs) that have become unused now (and been removed). Furthermore, some code needed to be cleaned up manually (avmedia/source/quicktime/ and connectivity/source/drivers/kab/), as I had no configurations available that would actually build that code. Missing @throws documentation has not been applied in such manual clean-up. Change-Id: I3408691256c9b0c12bc5332de976743626e13960 Reviewed-on: https://gerrit.libreoffice.org/33574 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'sw/source/ui/vba/vbarows.cxx')
-rw-r--r--sw/source/ui/vba/vbarows.cxx42
1 files changed, 21 insertions, 21 deletions
diff --git a/sw/source/ui/vba/vbarows.cxx b/sw/source/ui/vba/vbarows.cxx
index 182ef99f65a9..9807c5e78c7d 100644
--- a/sw/source/ui/vba/vbarows.cxx
+++ b/sw/source/ui/vba/vbarows.cxx
@@ -44,12 +44,12 @@ public:
{
mxIndexAccess.set( mxTextTable->getRows(), uno::UNO_QUERY );
}
- virtual sal_Bool SAL_CALL hasMoreElements( ) throw (uno::RuntimeException, std::exception) override
+ virtual sal_Bool SAL_CALL hasMoreElements( ) override
{
return ( nIndex < mxIndexAccess->getCount() );
}
- virtual uno::Any SAL_CALL nextElement( ) throw (container::NoSuchElementException, lang::WrappedTargetException, uno::RuntimeException, std::exception) override
+ virtual uno::Any SAL_CALL nextElement( ) override
{
if( nIndex < mxIndexAccess->getCount() )
{
@@ -59,13 +59,13 @@ public:
}
};
-SwVbaRows::SwVbaRows( const uno::Reference< XHelperInterface >& xParent, const uno::Reference< uno::XComponentContext > & xContext, const uno::Reference< text::XTextTable >& xTextTable, const uno::Reference< table::XTableRows >& xTableRows ) throw (uno::RuntimeException) : SwVbaRows_BASE( xParent, xContext, uno::Reference< container::XIndexAccess >( xTableRows, uno::UNO_QUERY_THROW ) ), mxTextTable( xTextTable ), mxTableRows( xTableRows )
+SwVbaRows::SwVbaRows( const uno::Reference< XHelperInterface >& xParent, const uno::Reference< uno::XComponentContext > & xContext, const uno::Reference< text::XTextTable >& xTextTable, const uno::Reference< table::XTableRows >& xTableRows ) : SwVbaRows_BASE( xParent, xContext, uno::Reference< container::XIndexAccess >( xTableRows, uno::UNO_QUERY_THROW ) ), mxTextTable( xTextTable ), mxTableRows( xTableRows )
{
mnStartRowIndex = 0;
mnEndRowIndex = m_xIndexAccess->getCount() - 1;
}
-SwVbaRows::SwVbaRows( const uno::Reference< XHelperInterface >& xParent, const uno::Reference< uno::XComponentContext > & xContext, const uno::Reference< text::XTextTable >& xTextTable, const uno::Reference< table::XTableRows >& xTableRows, sal_Int32 nStarIndex, sal_Int32 nEndIndex ) throw (uno::RuntimeException) : SwVbaRows_BASE( xParent, xContext, uno::Reference< container::XIndexAccess >( xTableRows, uno::UNO_QUERY_THROW ) ), mxTextTable( xTextTable ), mxTableRows( xTableRows ), mnStartRowIndex( nStarIndex ), mnEndRowIndex( nEndIndex )
+SwVbaRows::SwVbaRows( const uno::Reference< XHelperInterface >& xParent, const uno::Reference< uno::XComponentContext > & xContext, const uno::Reference< text::XTextTable >& xTextTable, const uno::Reference< table::XTableRows >& xTableRows, sal_Int32 nStarIndex, sal_Int32 nEndIndex ) : SwVbaRows_BASE( xParent, xContext, uno::Reference< container::XIndexAccess >( xTableRows, uno::UNO_QUERY_THROW ) ), mxTextTable( xTextTable ), mxTableRows( xTableRows ), mnStartRowIndex( nStarIndex ), mnEndRowIndex( nEndIndex )
{
if( mnEndRowIndex < mnStartRowIndex )
throw uno::RuntimeException();
@@ -76,7 +76,7 @@ SwVbaRows::SwVbaRows( const uno::Reference< XHelperInterface >& xParent, const u
* is mapped to WdRowAlignment in Word
* @return the alignment
*/
-::sal_Int32 SAL_CALL SwVbaRows::getAlignment() throw (uno::RuntimeException, std::exception)
+::sal_Int32 SAL_CALL SwVbaRows::getAlignment()
{
sal_Int16 nAlignment = text::HoriOrientation::LEFT;
uno::Reference< beans::XPropertySet > xTableProps( mxTextTable, uno::UNO_QUERY_THROW );
@@ -102,7 +102,7 @@ SwVbaRows::SwVbaRows( const uno::Reference< XHelperInterface >& xParent, const u
return nRet;
}
-void SAL_CALL SwVbaRows::setAlignment( ::sal_Int32 _alignment ) throw (uno::RuntimeException, std::exception)
+void SAL_CALL SwVbaRows::setAlignment( ::sal_Int32 _alignment )
{
sal_Int16 nAlignment = text::HoriOrientation::LEFT;
switch( _alignment )
@@ -126,7 +126,7 @@ void SAL_CALL SwVbaRows::setAlignment( ::sal_Int32 _alignment ) throw (uno::Runt
xTableProps->setPropertyValue("HoriOrient", uno::makeAny( nAlignment ) );
}
-uno::Any SAL_CALL SwVbaRows::getAllowBreakAcrossPages() throw (uno::RuntimeException, std::exception)
+uno::Any SAL_CALL SwVbaRows::getAllowBreakAcrossPages()
{
bool bAllowBreak = false;
uno::Reference< container::XIndexAccess > xRowsAccess( mxTableRows, uno::UNO_QUERY_THROW );
@@ -148,7 +148,7 @@ uno::Any SAL_CALL SwVbaRows::getAllowBreakAcrossPages() throw (uno::RuntimeExcep
return uno::makeAny( bAllowBreak );
}
-void SAL_CALL SwVbaRows::setAllowBreakAcrossPages( const uno::Any& _allowbreakacrosspages ) throw (uno::RuntimeException, std::exception)
+void SAL_CALL SwVbaRows::setAllowBreakAcrossPages( const uno::Any& _allowbreakacrosspages )
{
bool bAllowBreak = false;
_allowbreakacrosspages >>= bAllowBreak;
@@ -160,7 +160,7 @@ void SAL_CALL SwVbaRows::setAllowBreakAcrossPages( const uno::Any& _allowbreakac
}
}
-float SAL_CALL SwVbaRows::getSpaceBetweenColumns() throw (uno::RuntimeException, std::exception)
+float SAL_CALL SwVbaRows::getSpaceBetweenColumns()
{
// just get the first spacing of the first cell
uno::Reference< table::XCellRange > xCellRange( mxTextTable, uno::UNO_QUERY_THROW );
@@ -172,7 +172,7 @@ float SAL_CALL SwVbaRows::getSpaceBetweenColumns() throw (uno::RuntimeException,
return static_cast< float >( Millimeter::getInPoints( nLeftBorderDistance + nRightBorderDistance ) );
}
-void SAL_CALL SwVbaRows::setSpaceBetweenColumns( float _spacebetweencolumns ) throw (uno::RuntimeException, std::exception)
+void SAL_CALL SwVbaRows::setSpaceBetweenColumns( float _spacebetweencolumns )
{
sal_Int32 nSpace = Millimeter::getInHundredthsOfOneMillimeter( _spacebetweencolumns ) / 2;
uno::Reference< container::XIndexAccess > xColumnAccess( mxTextTable->getColumns(), uno::UNO_QUERY_THROW );
@@ -190,12 +190,12 @@ void SAL_CALL SwVbaRows::setSpaceBetweenColumns( float _spacebetweencolumns ) th
}
}
-void SAL_CALL SwVbaRows::Delete( ) throw (uno::RuntimeException, std::exception)
+void SAL_CALL SwVbaRows::Delete( )
{
mxTableRows->removeByIndex( mnStartRowIndex, getCount() );
}
-void SAL_CALL SwVbaRows::SetLeftIndent( float LeftIndent, ::sal_Int32 RulerStyle ) throw (uno::RuntimeException, std::exception)
+void SAL_CALL SwVbaRows::SetLeftIndent( float LeftIndent, ::sal_Int32 RulerStyle )
{
uno::Reference< word::XColumns > xColumns( new SwVbaColumns( getParent(), mxContext, mxTextTable, mxTextTable->getColumns() ) );
sal_Int32 nIndent = (sal_Int32)( LeftIndent );
@@ -228,7 +228,7 @@ void SAL_CALL SwVbaRows::SetLeftIndent( float LeftIndent, ::sal_Int32 RulerStyle
}
}
-void SwVbaRows::setIndentWithAdjustNone( sal_Int32 indent ) throw (uno::RuntimeException)
+void SwVbaRows::setIndentWithAdjustNone( sal_Int32 indent )
{
uno::Reference< beans::XPropertySet > xTableProps( mxTextTable, uno::UNO_QUERY_THROW );
sal_Int32 nMargin = 0;
@@ -237,7 +237,7 @@ void SwVbaRows::setIndentWithAdjustNone( sal_Int32 indent ) throw (uno::RuntimeE
xTableProps->setPropertyValue("LeftMargin", uno::makeAny( nMargin ) );
}
- void SwVbaRows::setIndentWithAdjustFirstColumn( const uno::Reference< word::XColumns >& xColumns, sal_Int32 indent ) throw (uno::RuntimeException)
+ void SwVbaRows::setIndentWithAdjustFirstColumn( const uno::Reference< word::XColumns >& xColumns, sal_Int32 indent )
{
sal_Int32 nIndex = 1;
uno::Reference< XCollection > xCol( xColumns, uno::UNO_QUERY_THROW );
@@ -251,7 +251,7 @@ void SwVbaRows::setIndentWithAdjustNone( sal_Int32 indent ) throw (uno::RuntimeE
void SwVbaRows::setIndentWithAdjustProportional(
const uno::Reference< word::XColumns >& xColumns,
sal_Int32 indent
-) throw (uno::RuntimeException)
+)
{
// calculate the new width and get the proportion between old and new
uno::Reference< beans::XPropertySet > xTableProps( mxTextTable, uno::UNO_QUERY_THROW );
@@ -283,7 +283,7 @@ void SwVbaRows::setIndentWithAdjustNone( sal_Int32 indent ) throw (uno::RuntimeE
xTableProps->setPropertyValue("Width", uno::makeAny( nNewWidth ) );
}
- void SwVbaRows::setIndentWithAdjustSameWidth( const uno::Reference< word::XColumns >& xColumns, sal_Int32 indent ) throw (uno::RuntimeException)
+ void SwVbaRows::setIndentWithAdjustSameWidth( const uno::Reference< word::XColumns >& xColumns, sal_Int32 indent )
{
// calculate the new width and get the width of all columns
uno::Reference< beans::XPropertySet > xTableProps( mxTextTable, uno::UNO_QUERY_THROW );
@@ -306,17 +306,17 @@ void SwVbaRows::setIndentWithAdjustNone( sal_Int32 indent ) throw (uno::RuntimeE
xTableProps->setPropertyValue("Width", uno::makeAny( nNewWidth ) );
}
-void SAL_CALL SwVbaRows::Select( ) throw (uno::RuntimeException, std::exception)
+void SAL_CALL SwVbaRows::Select( )
{
SwVbaRow::SelectRow( getCurrentWordDoc(mxContext), mxTextTable, mnStartRowIndex, mnEndRowIndex );
}
-::sal_Int32 SAL_CALL SwVbaRows::getCount() throw (uno::RuntimeException)
+::sal_Int32 SAL_CALL SwVbaRows::getCount()
{
return ( mnEndRowIndex - mnStartRowIndex + 1 );
}
-uno::Any SAL_CALL SwVbaRows::Item( const uno::Any& Index1, const uno::Any& /*not processed in this base class*/ ) throw (lang::IndexOutOfBoundsException, uno::RuntimeException)
+uno::Any SAL_CALL SwVbaRows::Item( const uno::Any& Index1, const uno::Any& /*not processed in this base class*/ )
{
sal_Int32 nIndex = 0;
if( ( Index1 >>= nIndex ) )
@@ -332,12 +332,12 @@ uno::Any SAL_CALL SwVbaRows::Item( const uno::Any& Index1, const uno::Any& /*not
// XEnumerationAccess
uno::Type
-SwVbaRows::getElementType() throw (uno::RuntimeException)
+SwVbaRows::getElementType()
{
return cppu::UnoType<word::XRow>::get();
}
uno::Reference< container::XEnumeration >
-SwVbaRows::createEnumeration() throw (uno::RuntimeException)
+SwVbaRows::createEnumeration()
{
return new RowsEnumWrapper( this, mxContext, mxTextTable );
}