diff options
author | Takeshi Abe <tabe@fixedpoint.jp> | 2012-01-06 00:21:36 +0900 |
---|---|---|
committer | Takeshi Abe <tabe@fixedpoint.jp> | 2012-01-06 00:22:52 +0900 |
commit | fd189805e3e42f11bc8ad726c8e4f170337e8267 (patch) | |
tree | be1bb1ab93b463776af7f9b17cf95a09cdd80fb2 | |
parent | 5493951893ea90b330d5280bc171a60ff46fa396 (diff) |
removed dead code
-rw-r--r-- | svx/source/table/tablelayouter.cxx | 100 | ||||
-rw-r--r-- | svx/source/table/tablelayouter.hxx | 11 | ||||
-rw-r--r-- | svx/source/unodraw/unopage.cxx | 46 |
3 files changed, 0 insertions, 157 deletions
diff --git a/svx/source/table/tablelayouter.cxx b/svx/source/table/tablelayouter.cxx index 06c6d42f4c9d..18e833201de2 100644 --- a/svx/source/table/tablelayouter.cxx +++ b/svx/source/table/tablelayouter.cxx @@ -1076,40 +1076,6 @@ void TableLayouter::UpdateBorderLayout() } // ----------------------------------------------------------------------------- -/* -void TableLayouter::SetLayoutToModel() -{ - const sal_Int32 nRowCount = getRowCount(); - const sal_Int32 nColCount = getColumnCount(); - - try - { - sal_Int32 nOldSize = 0; - - Reference< XIndexAccess > xRows( mxTable->getRows(), UNO_QUERY_THROW ); - for( sal_Int32 nRow = 0; nRow < nRowCount; nRow++ ) - { - Reference< XPropertySet > xRowSet( xRows->getByIndex( nRow ), UNO_QUERY_THROW ); - xRowSet->getPropertyValue( msSize ) >>= nOldSize; - if( maRows[nRow].mnSize != nOldSize ) - xRowSet->setPropertyValue( msSize, Any( maRows[nRow].mnSize ) ); - } - - for( sal_Int32 nCol = 0; nCol < nColCount; nCol++ ) - { - Reference< XPropertySet > xColSet( getColumnByIndex( nCol ), UNO_QUERY_THROW ); - xColSet->getPropertyValue( msSize ) >>= nOldSize; - if( maColumns[nCol].mnSize != nOldSize ) - xColSet->setPropertyValue( msSize, Any( maColumns[nCol].mnSize ) ); - } - } - catch( Exception& ) - { - OSL_FAIL("sdr::table::TableLayouter::SetLayoutToModel(), exception caught!"); - } -} -*/ -// ----------------------------------------------------------------------------- void TableLayouter::DistributeColumns( ::Rectangle& rArea, sal_Int32 nFirstCol, sal_Int32 nLastCol ) { @@ -1228,72 +1194,6 @@ sal_Int32 TableLayouter::getRowStart( sal_Int32 nRow ) const // ----------------------------------------------------------------------------- -/* -sal_Int32 TableLayouter::detectInsertedOrRemovedRows() -{ - sal_Int32 nHeightChange = 0; - - try - { - Reference< XIndexAccess > xRows( mxTable->getRows(), UNO_QUERY_THROW ); - std::vector< ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > >::iterator oldIter( mxRows.begin() ); - sal_Int32 nCount = xRows->getCount(); - for( sal_Int32 nRow = 0; nRow < nCount; nRow++ ) - { - Reference< XInterface > xRow( xRows->getByIndex(nRow), UNO_QUERY ); - - std::vector< ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > >::iterator searchIter = mxRows.end(); - if( oldIter != mxRows.end() ) - searchIter = std::find( oldIter,mxRows.end(), xRow ); - - if( searchIter == mxRows.end() ) - { - // new row - Reference< XPropertySet > xSet( xRow, UNO_QUERY_THROW ); - sal_Int32 nSize = 0; - xSet->getPropertyValue( msSize ) >>= nSize; - nHeightChange += nSize; - } - else if( searchIter == oldIter ) - { - // no change - oldIter++; - } - else - { - // rows removed - do - { - Reference< XPropertySet > xSet( (*oldIter), UNO_QUERY_THROW ); - sal_Int32 nSize = 0; - xSet->getPropertyValue( msSize ) >>= nSize; - nHeightChange -= nSize; - } - while( oldIter++ != searchIter ); - } - } - - while( oldIter != mxRows.end() ) - { - // rows removed - Reference< XPropertySet > xSet( (*oldIter++), UNO_QUERY_THROW ); - sal_Int32 nSize = 0; - xSet->getPropertyValue( msSize ) >>= nSize; - nHeightChange -= nSize; - } - } - catch( Exception& e ) - { - (void)e; - OSL_FAIL("svx::TableLayouter::detectInsertedOrRemovedRows(), exception caught!"); - } - - return nHeightChange; -} -*/ - -// ----------------------------------------------------------------------------- - } } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/svx/source/table/tablelayouter.hxx b/svx/source/table/tablelayouter.hxx index edbacb83651c..e95159075b46 100644 --- a/svx/source/table/tablelayouter.hxx +++ b/svx/source/table/tablelayouter.hxx @@ -67,13 +67,6 @@ public: TableLayouter( const TableModelRef& xTableModel ); virtual ~TableLayouter(); - /** this checks if new rows are inserted or old rows where removed. - This can be used to grow or shrink the table shape in this case. - @returns - the height difference - sal_Int32 detectInsertedOrRemovedRows(); - */ - /** try to fit the table into the given rectangle. If the rectangle is to small, it will be grown to fit the table. @@ -85,10 +78,6 @@ public: */ void LayoutTable( ::Rectangle& rRectangle, bool bFitWidth, bool bFitHeight ); - /** after a call to LayoutTable, this method can be used to set the new - column and row sizes back to the model. */ -// void SetLayoutToModel(); - void UpdateBorderLayout(); basegfx::B2ITuple getCellSize( const CellPos& rPos ) const; diff --git a/svx/source/unodraw/unopage.cxx b/svx/source/unodraw/unopage.cxx index 6366a49b712f..1f0b91d2a489 100644 --- a/svx/source/unodraw/unopage.cxx +++ b/svx/source/unodraw/unopage.cxx @@ -123,35 +123,6 @@ SvxDrawPage::~SvxDrawPage() throw() // XInterface void SvxDrawPage::release() throw() { -/* - uno::Reference< uno::XInterface > x( xDelegator ); - if (! x.is()) - { - if (osl_decrementInterlockedCount( &m_refCount ) == 0) - { - if (! mrBHelper.bDisposed) - { - uno::Reference< uno::XInterface > xHoldAlive( (uno::XWeak*)this ); - // First dispose - try - { - dispose(); - } - catch(::com::sun::star::uno::Exception&) - { - // release should not throw exceptions - } - - // only the alive ref holds the object - OSL_ASSERT( m_refCount == 1 ); - // destroy the object if xHoldAlive decrement the refcount to 0 - return; - } - } - // restore the reference count - osl_incrementInterlockedCount( &m_refCount ); - } -*/ OWeakAggObject::release(); } @@ -269,23 +240,6 @@ void SAL_CALL SvxDrawPage::removeEventListener( const ::com::sun::star::uno::Ref void SvxDrawPage::Notify( SfxBroadcaster&, const SfxHint& /*rHint*/ ) { -/* - if( mpModel ) - { - const SdrHint* pSdrHint = PTR_CAST( SdrHint, &rHint ); - if( pSdrHint ) - { - switch( pSdrHint->GetKind() ) - { - case HINT_MODELCLEARED: - dispose(); - break; - default: - break; - } - } - } -*/ } //---------------------------------------------------------------------- |