diff options
Diffstat (limited to 'sw/source/core/txtnode/atrflyin.cxx')
-rw-r--r-- | sw/source/core/txtnode/atrflyin.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sw/source/core/txtnode/atrflyin.cxx b/sw/source/core/txtnode/atrflyin.cxx index eca7534bcbba..b4ca1e96e704 100644 --- a/sw/source/core/txtnode/atrflyin.cxx +++ b/sw/source/core/txtnode/atrflyin.cxx @@ -124,7 +124,7 @@ void SwTextFlyCnt::CopyFlyFormat( SwDoc* pDoc ) } SwFrameFormat* pNew = pDoc->getIDocumentLayoutAccess().CopyLayoutFormat( *pFormat, aAnchor, false, false ); - ((SwFormatFlyCnt&)GetFlyCnt()).SetFlyFormat( pNew ); + const_cast<SwFormatFlyCnt&>(GetFlyCnt()).SetFlyFormat( pNew ); } /** SetAnchor() is called by SwTextNode::InsertHint() and sets the anchor @@ -176,7 +176,7 @@ void SwTextFlyCnt::SetAnchor( const SwTextNode *pNode ) ::sw::UndoGuard const undoGuardFormat( pFormat->GetDoc()->GetIDocumentUndoRedo()); pFormat->GetDoc()->getIDocumentLayoutAccess().DelLayoutFormat( pFormat ); - ((SwFormatFlyCnt&)GetFlyCnt()).SetFlyFormat( pNew ); + const_cast<SwFormatFlyCnt&>(GetFlyCnt()).SetFlyFormat( pNew ); } else if( pNode->GetpSwpHints() && pNode->GetpSwpHints()->IsInSplitNode() && |