summaryrefslogtreecommitdiff
path: root/sw/source/core/objectpositioning
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/core/objectpositioning')
-rw-r--r--sw/source/core/objectpositioning/anchoredobjectposition.cxx20
-rw-r--r--sw/source/core/objectpositioning/ascharanchoredobjectposition.cxx8
-rw-r--r--sw/source/core/objectpositioning/environmentofanchoredobject.cxx8
-rw-r--r--sw/source/core/objectpositioning/tocntntanchoredobjectposition.cxx10
-rw-r--r--sw/source/core/objectpositioning/tolayoutanchoredobjectposition.cxx2
5 files changed, 24 insertions, 24 deletions
diff --git a/sw/source/core/objectpositioning/anchoredobjectposition.cxx b/sw/source/core/objectpositioning/anchoredobjectposition.cxx
index 84735025bd1e..f3df1223f718 100644
--- a/sw/source/core/objectpositioning/anchoredobjectposition.cxx
+++ b/sw/source/core/objectpositioning/anchoredobjectposition.cxx
@@ -75,7 +75,7 @@ SwAnchoredObjectPosition::SwAnchoredObjectPosition( SdrObject& _rDrawObj )
( !mrDrawObj.ISA(SdrVirtObj) && // 'master' drawing object
!mrDrawObj.ISA(SwFlyDrawObj) ); // - indirectly checked
(void) bObjOfExceptedType;
- ASSERT( bObjOfExceptedType,
+ OSL_ENSURE( bObjOfExceptedType,
"SwAnchoredObjectPosition(..) - object of unexcepted type!" );
#endif
@@ -100,7 +100,7 @@ void SwAnchoredObjectPosition::_GetInfoAboutObj()
// determine contact object
{
mpContact = static_cast<SwContact*>(GetUserCall( &mrDrawObj ));
- ASSERT( mpContact,
+ OSL_ENSURE( mpContact,
"SwAnchoredObjectPosition::_GetInfoAboutObj() - missing SwContact-object." );
}
@@ -108,7 +108,7 @@ void SwAnchoredObjectPosition::_GetInfoAboutObj()
{
// OD 2004-03-30 #i26791#
mpAnchoredObj = mpContact->GetAnchoredObj( &mrDrawObj );
- ASSERT( mpAnchoredObj,
+ OSL_ENSURE( mpAnchoredObj,
"SwAnchoredObjectPosition::_GetInfoAboutObj() - missing anchored object." );
}
@@ -116,7 +116,7 @@ void SwAnchoredObjectPosition::_GetInfoAboutObj()
{
// OD 2004-03-23 #i26791#
mpAnchorFrm = mpAnchoredObj->AnchorFrm();
- ASSERT( mpAnchorFrm,
+ OSL_ENSURE( mpAnchorFrm,
"SwAnchoredObjectPosition::_GetInfoAboutObj() - missing anchor frame." );
}
@@ -124,7 +124,7 @@ void SwAnchoredObjectPosition::_GetInfoAboutObj()
{
// --> OD 2004-07-01 #i28701#
mpFrmFmt = &mpAnchoredObj->GetFrmFmt();
- ASSERT( mpFrmFmt,
+ OSL_ENSURE( mpFrmFmt,
"<SwAnchoredObjectPosition::_GetInfoAboutObj() - missing frame format." );
}
@@ -305,7 +305,7 @@ void SwAnchoredObjectPosition::_GetVertAlignmentValues(
}
else
{
- ASSERT( false,
+ OSL_ENSURE( false,
"<SwAnchoredObjectPosition::_GetVertAlignmentValues(..)> - invalid relative alignment" );
}
}
@@ -320,7 +320,7 @@ void SwAnchoredObjectPosition::_GetVertAlignmentValues(
}
else
{
- ASSERT( false,
+ OSL_ENSURE( false,
"<SwAnchoredObjectPosition::_GetVertAlignmentValues(..)> - invalid relative alignment" );
}
}
@@ -332,7 +332,7 @@ void SwAnchoredObjectPosition::_GetVertAlignmentValues(
//case text::RelOrientation::FRAME_LEFT: not valid for vertical alignment
//case text::RelOrientation::FRAME_RIGHT: not valid for vertical alignment
{
- ASSERT( false,
+ OSL_ENSURE( false,
"<SwAnchoredObjectPosition::_GetVertAlignmentValues(..)> - invalid relative alignment" );
}
}
@@ -390,7 +390,7 @@ SwTwips SwAnchoredObjectPosition::_GetVertRelPos(
break;
default:
{
- ASSERT( false,
+ OSL_ENSURE( false,
"<SwAnchoredObjectPosition::_GetVertRelPos(..) - invalid vertical positioning" );
}
}
@@ -924,7 +924,7 @@ SwTwips SwAnchoredObjectPosition::_AdjustHoriRelPosForDrawAside(
if ( !GetAnchorFrm().ISA(SwTxtFrm) ||
!GetAnchoredObj().ISA(SwFlyAtCntFrm) )
{
- ASSERT( false,
+ OSL_ENSURE( false,
"<SwAnchoredObjectPosition::_AdjustHoriRelPosForDrawAside(..) - usage for wrong anchor type" );
return _nProposedRelPosX;
}
diff --git a/sw/source/core/objectpositioning/ascharanchoredobjectposition.cxx b/sw/source/core/objectpositioning/ascharanchoredobjectposition.cxx
index c7e7833ac0ea..a5facaf474b9 100644
--- a/sw/source/core/objectpositioning/ascharanchoredobjectposition.cxx
+++ b/sw/source/core/objectpositioning/ascharanchoredobjectposition.cxx
@@ -84,7 +84,7 @@ SwAsCharAnchoredObjectPosition::~SwAsCharAnchoredObjectPosition()
*/
const SwTxtFrm& SwAsCharAnchoredObjectPosition::GetAnchorTxtFrm() const
{
- ASSERT( GetAnchorFrm().ISA(SwTxtFrm),
+ OSL_ENSURE( GetAnchorFrm().ISA(SwTxtFrm),
"SwAsCharAnchoredObjectPosition::GetAnchorTxtFrm() - wrong anchor frame type" );
return static_cast<const SwTxtFrm&>(GetAnchorFrm());
@@ -289,7 +289,7 @@ void SwAsCharAnchoredObjectPosition::CalcPosition()
rAnchorFrm.SwitchHorizontalToVertical( aAnchorPos );
// --> OD 2005-03-09 #i44347# - keep last object rectangle at anchored object
- ASSERT ( GetAnchoredObj().ISA(SwAnchoredDrawObject),
+ OSL_ENSURE( GetAnchoredObj().ISA(SwAnchoredDrawObject),
"<SwAsCharAnchoredObjectPosition::CalcPosition()> - wrong type of anchored object." );
SwAnchoredDrawObject& rAnchoredDrawObj =
static_cast<SwAnchoredDrawObject&>( GetAnchoredObj() );
@@ -317,7 +317,7 @@ void SwAsCharAnchoredObjectPosition::CalcPosition()
aRelAttr = Point( 0, nRelPos );
// OD 2004-03-23 #i26791#
- ASSERT( GetAnchoredObj().ISA(SwFlyInCntFrm),
+ OSL_ENSURE( GetAnchoredObj().ISA(SwFlyInCntFrm),
"<SwAsCharAnchoredObjectPosition::CalcPosition()> - wrong anchored object." );
const SwFlyInCntFrm& rFlyInCntFrm =
static_cast<const SwFlyInCntFrm&>(GetAnchoredObj());
@@ -338,7 +338,7 @@ void SwAsCharAnchoredObjectPosition::CalcPosition()
aObjBoundRect.Height( aObjBoundRect.Height() + rULSpace.GetLower() );
}
}
- ASSERT( (rFlyInCntFrm.Frm().*fnRect->fnGetHeight)(),
+ OSL_ENSURE( (rFlyInCntFrm.Frm().*fnRect->fnGetHeight)(),
"SwAnchoredObjectPosition::CalcPosition(..) - fly frame has an invalid height" );
}
diff --git a/sw/source/core/objectpositioning/environmentofanchoredobject.cxx b/sw/source/core/objectpositioning/environmentofanchoredobject.cxx
index 065f6676897b..a6585414f92b 100644
--- a/sw/source/core/objectpositioning/environmentofanchoredobject.cxx
+++ b/sw/source/core/objectpositioning/environmentofanchoredobject.cxx
@@ -70,12 +70,12 @@ const SwLayoutFrm& SwEnvironmentOfAnchoredObject::GetHoriEnvironmentLayoutFrm(
!pHoriEnvironmentLayFrm->IsPageFrm() )
{
pHoriEnvironmentLayFrm = pHoriEnvironmentLayFrm->GetUpper();
- ASSERT( pHoriEnvironmentLayFrm,
+ OSL_ENSURE( pHoriEnvironmentLayFrm,
"SwEnvironmentOfAnchoredObject::GetHoriEnvironmentLayoutFrm(..) - no page|fly|cell frame found" );
}
}
- ASSERT( pHoriEnvironmentLayFrm->ISA(SwLayoutFrm),
+ OSL_ENSURE( pHoriEnvironmentLayFrm->ISA(SwLayoutFrm),
"SwEnvironmentOfAnchoredObject::GetHoriEnvironmentLayoutFrm(..) - found frame isn't a layout frame" );
return static_cast<const SwLayoutFrm&>(*pHoriEnvironmentLayFrm);
@@ -110,12 +110,12 @@ const SwLayoutFrm& SwEnvironmentOfAnchoredObject::GetVertEnvironmentLayoutFrm(
!pVertEnvironmentLayFrm->IsPageFrm() )
{
pVertEnvironmentLayFrm = pVertEnvironmentLayFrm->GetUpper();
- ASSERT( pVertEnvironmentLayFrm,
+ OSL_ENSURE( pVertEnvironmentLayFrm,
"SwEnvironmentOfAnchoredObject::GetVertEnvironmentLayoutFrm(..) - proposed frame not found" );
}
}
- ASSERT( pVertEnvironmentLayFrm->ISA(SwLayoutFrm),
+ OSL_ENSURE( pVertEnvironmentLayFrm->ISA(SwLayoutFrm),
"SwEnvironmentOfAnchoredObject::GetVertEnvironmentLayoutFrm(..) - found frame isn't a layout frame" );
return static_cast<const SwLayoutFrm&>(*pVertEnvironmentLayFrm);
diff --git a/sw/source/core/objectpositioning/tocntntanchoredobjectposition.cxx b/sw/source/core/objectpositioning/tocntntanchoredobjectposition.cxx
index c5dca18a1d25..63169790f317 100644
--- a/sw/source/core/objectpositioning/tocntntanchoredobjectposition.cxx
+++ b/sw/source/core/objectpositioning/tocntntanchoredobjectposition.cxx
@@ -94,7 +94,7 @@ SwTwips SwToCntntAnchoredObjectPosition::ToCharTopOfLine() const
SwTxtFrm& SwToCntntAnchoredObjectPosition::GetAnchorTxtFrm() const
{
- ASSERT( GetAnchorFrm().ISA(SwTxtFrm),
+ OSL_ENSURE( GetAnchorFrm().ISA(SwTxtFrm),
"SwToCntntAnchoredObjectPosition::GetAnchorTxtFrm() - wrong anchor frame type" );
return static_cast<SwTxtFrm&>(GetAnchorFrm());
@@ -311,7 +311,7 @@ void SwToCntntAnchoredObjectPosition::CalcPosition()
}
else
{
- ASSERT( false,
+ OSL_ENSURE( false,
"<SwToCntntAnchoredObjectPosition::CalcPosition()> - unknown combination of vertical position and vertical alignment." );
}
}
@@ -331,7 +331,7 @@ void SwToCntntAnchoredObjectPosition::CalcPosition()
}
else
{
- ASSERT( false,
+ OSL_ENSURE( false,
"<SwToCntntAnchoredObjectPosition::CalcPosition()> - unknown combination of vertical position and vertical alignment." );
}
}
@@ -372,7 +372,7 @@ void SwToCntntAnchoredObjectPosition::CalcPosition()
}
else
{
- ASSERT( false,
+ OSL_ENSURE( false,
"<SwToCntntAnchoredObjectPosition::CalcPosition()> - unknown combination of vertical position and vertical alignment." );
}
}
@@ -697,7 +697,7 @@ void SwToCntntAnchoredObjectPosition::CalcPosition()
else
{
#if OSL_DEBUG_LEVEL > 1
- ASSERT( false, "<SwToCntntAnchoredObjectPosition::CalcPosition()> - code under investigation by OD, please inform OD about this assertion!" );
+ OSL_ENSURE( false, "<SwToCntntAnchoredObjectPosition::CalcPosition()> - code under investigation by OD, please inform OD about this assertion!" );
#endif
nRelDiff = nRelPosY;
nRelPosY = 0;
diff --git a/sw/source/core/objectpositioning/tolayoutanchoredobjectposition.cxx b/sw/source/core/objectpositioning/tolayoutanchoredobjectposition.cxx
index c785525cdc95..69f457f3d44d 100644
--- a/sw/source/core/objectpositioning/tolayoutanchoredobjectposition.cxx
+++ b/sw/source/core/objectpositioning/tolayoutanchoredobjectposition.cxx
@@ -118,7 +118,7 @@ void SwToLayoutAnchoredObjectPosition::CalcPosition()
// anchor position, depending on layout-direction
if( bVert )
{
- ASSERT( !bRev, "<SwToLayoutAnchoredObjectPosition::CalcPosition()> - reverse layout set." );
+ OSL_ENSURE( !bRev, "<SwToLayoutAnchoredObjectPosition::CalcPosition()> - reverse layout set." );
aRelPos.X() = -nRelPosY - aObjBoundRect.Width();
maOffsetToFrmAnchorPos.X() = nVertOffsetToFrmAnchorPos;
}