diff options
author | Thomas Arnhold <thomas@arnhold.org> | 2011-03-01 19:07:44 +0100 |
---|---|---|
committer | Thomas Arnhold <thomas@arnhold.org> | 2011-03-02 15:04:37 +0100 |
commit | 65c053ca1a5a8c7318ab1e42cdde2d540a283673 (patch) | |
tree | 2e1a29f5d832ff0cb0d4c095f038392b472459d1 /editeng | |
parent | Remove DBG_UTILx (diff) | |
download | core-65c053ca1a5a8c7318ab1e42cdde2d540a283673.tar.gz core-65c053ca1a5a8c7318ab1e42cdde2d540a283673.zip |
Move DBG_ERROR to OSL_FAIL
Diffstat (limited to 'editeng')
34 files changed, 150 insertions, 150 deletions
diff --git a/editeng/source/accessibility/AccessibleEditableTextPara.cxx b/editeng/source/accessibility/AccessibleEditableTextPara.cxx index 66ef2bbefb13..e7289ffcabf1 100644 --- a/editeng/source/accessibility/AccessibleEditableTextPara.cxx +++ b/editeng/source/accessibility/AccessibleEditableTextPara.cxx @@ -1863,7 +1863,7 @@ namespace accessibility } catch( const uno::Exception& ) { - DBG_ERROR("AccessibleEditableTextPara::setAttributes exception in setPropertyValue"); + OSL_FAIL("AccessibleEditableTextPara::setAttributes exception in setPropertyValue"); } ++pPropArray; diff --git a/editeng/source/editeng/editdbg.cxx b/editeng/source/editeng/editdbg.cxx index 4257cefb2133..73c2ab29571b 100644 --- a/editeng/source/editeng/editdbg.cxx +++ b/editeng/source/editeng/editdbg.cxx @@ -329,7 +329,7 @@ void EditDbg::ShowEditEngineData( EditEngine* pEE, BOOL bInfoBox ) #endif if ( fp == 0 ) { - DBG_ERROR( "Log file could not be created!" ); + OSL_FAIL( "Log file could not be created!" ); return; } diff --git a/editeng/source/editeng/editdoc.cxx b/editeng/source/editeng/editdoc.cxx index 5be5931a7a3c..1782a264b8fb 100644 --- a/editeng/source/editeng/editdoc.cxx +++ b/editeng/source/editeng/editdoc.cxx @@ -402,7 +402,7 @@ EditCharAttrib* MakeCharAttrib( SfxItemPool& rPool, const SfxPoolItem& rAttr, US break; default: { - DBG_ERROR( "Invalid Attribute!" ); + OSL_FAIL( "Invalid Attribute!" ); } } return pNew; @@ -828,7 +828,7 @@ void ContentNode::ExpandAttribs( USHORT nIndex, USHORT nNew, SfxItemPool& rItemP DBG_ASSERT( ( pAttrib->GetEnd() <= Len() ), "Expand: Attribute larger than paragraph!" ); if ( pAttrib->IsEmpty() ) { - DBG_ERROR( "Empty Attribute after ExpandAttribs?" ); + OSL_FAIL( "Empty Attribute after ExpandAttribs?" ); bResort = TRUE; aCharAttribList.GetAttribs().Remove( nAttr ); rItemPool.Remove( *pAttrib->GetItem() ); @@ -1379,7 +1379,7 @@ XubString EditDoc::GetText( LineEnd eEnd ) const nLen += nNodes * nSepSize; if ( nLen > 0xFFFb / sizeof(xub_Unicode) ) { - DBG_ERROR( "Text to large for String" ); + OSL_FAIL( "Text to large for String" ); return XubString(); } xub_Unicode* pStr = new xub_Unicode[nLen+1]; @@ -1442,7 +1442,7 @@ XubString EditDoc::GetParaAsString( ContentNode* pNode, USHORT nStartPos, USHORT case EE_FEATURE_FIELD: if ( bResolveFields ) aStr += ((EditCharAttribField*)pNextFeature)->GetFieldValue(); break; - default: DBG_ERROR( "What feature?" ); + default: OSL_FAIL( "What feature?" ); } pNextFeature = pNode->GetCharAttribs().FindFeature( ++nEnd ); } @@ -2185,12 +2185,12 @@ BOOL CharAttribList::DbgCheckAttribs() if ( pAttr->GetStart() > pAttr->GetEnd() ) { bOK = FALSE; - DBG_ERROR( "Attribute is distorted" ); + OSL_FAIL( "Attribute is distorted" ); } else if ( pAttr->IsFeature() && ( pAttr->GetLen() != 1 ) ) { bOK = FALSE; - DBG_ERROR( "Feature, Len != 1" ); + OSL_FAIL( "Feature, Len != 1" ); } } return bOK; diff --git a/editeng/source/editeng/editdoc2.cxx b/editeng/source/editeng/editdoc2.cxx index 0cb7a8bf6662..c3e238d3b695 100644 --- a/editeng/source/editeng/editdoc2.cxx +++ b/editeng/source/editeng/editdoc2.cxx @@ -112,7 +112,7 @@ USHORT TextPortionList::FindPortion( USHORT nCharPos, USHORT& nPortionStart, BOO } } } - DBG_ERROR( "FindPortion: Not found!" ); + OSL_FAIL( "FindPortion: Not found!" ); return ( Count() - 1 ); } @@ -371,7 +371,7 @@ long ParaPortionList::GetYOffset( ParaPortion* pPPortion ) return nHeight; nHeight += pTmpPortion->GetHeight(); } - DBG_ERROR( "GetYOffset: Portion not found" ); + OSL_FAIL( "GetYOffset: Portion not found" ); return nHeight; } diff --git a/editeng/source/editeng/editobj.cxx b/editeng/source/editeng/editobj.cxx index 5365d9631e27..fc3e4ef7ed38 100644 --- a/editeng/source/editeng/editobj.cxx +++ b/editeng/source/editeng/editobj.cxx @@ -111,14 +111,14 @@ BOOL lcl_CreateBulletItem( const SvxNumBulletItem& rNumBullet, USHORT nLevel, Sv rBullet.SetStyle( BS_BULLET ); break; case SVX_NUM_PAGEDESC: - DBG_ERROR( "Unknown: SVX_NUM_PAGEDESC" ); + OSL_FAIL( "Unknown: SVX_NUM_PAGEDESC" ); rBullet.SetStyle( BS_BULLET ); break; case SVX_NUM_BITMAP: rBullet.SetStyle( BS_BMP ); break; default: - DBG_ERROR( "Unknown NumType" ); + OSL_FAIL( "Unknown NumType" ); } switch ( pFmt->GetNumAdjust() ) @@ -133,7 +133,7 @@ BOOL lcl_CreateBulletItem( const SvxNumBulletItem& rNumBullet, USHORT nLevel, Sv rBullet.SetJustification( BJ_VCENTER|BJ_HCENTER ); break; default: - DBG_ERROR( "Unknown or invalid NumAdjust" ); + OSL_FAIL( "Unknown or invalid NumAdjust" ); } } return pFmt ? TRUE : FALSE; @@ -287,172 +287,172 @@ EditTextObject::~EditTextObject() USHORT EditTextObject::GetParagraphCount() const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return 0; } XubString EditTextObject::GetText( USHORT /* nParagraph */ ) const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return XubString(); } void EditTextObject::Insert( const EditTextObject& /* rObj */, USHORT /* nPara */) { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); } EditTextObject* EditTextObject::CreateTextObject( USHORT /*nPara*/, USHORT /*nParas*/ ) const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return 0; } void EditTextObject::RemoveParagraph( USHORT /*nPara*/ ) { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); } BOOL EditTextObject::HasPortionInfo() const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return FALSE; } void EditTextObject::ClearPortionInfo() { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); } BOOL EditTextObject::HasOnlineSpellErrors() const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return FALSE; } BOOL EditTextObject::HasCharAttribs( USHORT ) const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return FALSE; } void EditTextObject::GetCharAttribs( USHORT /*nPara*/, EECharAttribArray& /*rLst*/ ) const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); } void EditTextObject::MergeParaAttribs( const SfxItemSet& /*rAttribs*/, USHORT /*nStart*/, USHORT /*nEnd*/ ) { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); } BOOL EditTextObject::IsFieldObject() const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return FALSE; } const SvxFieldItem* EditTextObject::GetField() const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return 0; } BOOL EditTextObject::HasField( TypeId /*aType*/ ) const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return FALSE; } SfxItemSet EditTextObject::GetParaAttribs( USHORT /*nPara*/ ) const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return SfxItemSet( *(SfxItemPool*)NULL ); } void EditTextObject::SetParaAttribs( USHORT /*nPara*/, const SfxItemSet& /*rAttribs*/ ) { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); } BOOL EditTextObject::RemoveCharAttribs( USHORT /*nWhich*/ ) { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return FALSE; } BOOL EditTextObject::RemoveParaAttribs( USHORT /*nWhich*/ ) { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return FALSE; } BOOL EditTextObject::HasStyleSheet( const XubString& /*rName*/, SfxStyleFamily /*eFamily*/ ) const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return FALSE; } void EditTextObject::GetStyleSheet( USHORT /*nPara*/, XubString& /*rName*/, SfxStyleFamily& /*eFamily*/ ) const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); } void EditTextObject::SetStyleSheet( USHORT /*nPara*/, const XubString& /*rName*/, const SfxStyleFamily& /*eFamily*/ ) { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); } BOOL EditTextObject::ChangeStyleSheets( const XubString&, SfxStyleFamily, const XubString&, SfxStyleFamily ) { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return FALSE; } void EditTextObject::ChangeStyleSheetName( SfxStyleFamily /*eFamily*/, const XubString& /*rOldName*/, const XubString& /*rNewName*/ ) { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); } USHORT EditTextObject::GetUserType() const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return 0; } void EditTextObject::SetUserType( USHORT ) { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); } ULONG EditTextObject::GetObjectSettings() const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return 0; } void EditTextObject::SetObjectSettings( ULONG ) { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); } BOOL EditTextObject::IsVertical() const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return FALSE; } void EditTextObject::SetVertical( BOOL bVertical ) { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); ((BinTextObject*)this)->SetVertical( bVertical ); } USHORT EditTextObject::GetScriptType() const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return ((const BinTextObject*)this)->GetScriptType(); } @@ -534,17 +534,17 @@ void EditTextObject::Skip( SvStream& rIStream ) void EditTextObject::StoreData( SvStream& ) const { - DBG_ERROR( "StoreData: Base class!" ); + OSL_FAIL( "StoreData: Base class!" ); } void EditTextObject::CreateData( SvStream& ) { - DBG_ERROR( "CreateData: Base class!" ); + OSL_FAIL( "CreateData: Base class!" ); } USHORT EditTextObject::GetVersion() const { - DBG_ERROR( "Virtual method direct from EditTextObject!" ); + OSL_FAIL( "Virtual method direct from EditTextObject!" ); return 0; } @@ -1314,7 +1314,7 @@ void BinTextObject::CreateData( SvStream& rIStream ) if ( bOwnerOfCurrent && !bOwnerOfPool ) { // A global Pool was used, but not handed over to me, but I need it! - DBG_ERROR( "Give me the global TextObjectPool!" ); + OSL_FAIL( "Give me the global TextObjectPool!" ); return; } else if ( !bOwnerOfCurrent && bOwnerOfPool ) diff --git a/editeng/source/editeng/editundo.cxx b/editeng/source/editeng/editundo.cxx index 8cc732a686e7..46fee225030f 100644 --- a/editeng/source/editeng/editundo.cxx +++ b/editeng/source/editeng/editundo.cxx @@ -85,7 +85,7 @@ BOOL EditUndoManager::Undo( USHORT nCount ) pImpEE->SetActiveView( pImpEE->GetEditViews().GetObject(0) ); else { - DBG_ERROR("Undo in engine is not possible without a View! "); + OSL_FAIL("Undo in engine is not possible without a View! "); return FALSE; } } @@ -120,7 +120,7 @@ BOOL EditUndoManager::Redo( USHORT nCount ) pImpEE->SetActiveView( pImpEE->GetEditViews().GetObject(0) ); else { - DBG_ERROR( "Redo in Engine ohne View nicht moeglich!" ); + OSL_FAIL( "Redo in Engine ohne View nicht moeglich!" ); return FALSE; } } diff --git a/editeng/source/editeng/editview.cxx b/editeng/source/editeng/editview.cxx index ee3778b21103..ad67a7d35fdd 100644 --- a/editeng/source/editeng/editview.cxx +++ b/editeng/source/editeng/editview.cxx @@ -808,7 +808,7 @@ sal_Bool EditView::Drop( const DropEvent& ) ESelection EditView::GetDropPos() { - DBG_ERROR( "GetDropPos - Why?!" ); + OSL_FAIL( "GetDropPos - Why?!" ); return ESelection(); } @@ -1084,7 +1084,7 @@ void EditView::ExecuteSpellPopup( const Point& rPosPixel, Link* pCallBack ) } else { - DBG_ERROR( "content node is NULL" ); + OSL_FAIL( "content node is NULL" ); } nGuessLangWord = lcl_CheckLanguage( xSpellAlt->getWord(), xSpeller, xLangGuesser, sal_False ); diff --git a/editeng/source/editeng/edtspell.cxx b/editeng/source/editeng/edtspell.cxx index 6e638224563f..2e9f786db07d 100644 --- a/editeng/source/editeng/edtspell.cxx +++ b/editeng/source/editeng/edtspell.cxx @@ -116,7 +116,7 @@ void EditSpellWrapper::SpellStart( SvxSpellArea eArea ) } else { - DBG_ERROR( "SpellStart: Unknown Area!" ); + OSL_FAIL( "SpellStart: Unknown Area!" ); } } diff --git a/editeng/source/editeng/impedit.cxx b/editeng/source/editeng/impedit.cxx index 509ff4db87a0..a65d339b73bb 100644 --- a/editeng/source/editeng/impedit.cxx +++ b/editeng/source/editeng/impedit.cxx @@ -1143,7 +1143,7 @@ String ImpEditView::SpellIgnoreOrAddWord( sal_Bool bAdd ) { if ( bAdd ) { - DBG_ERROR( "Sorry, AddWord not implemented" ); + OSL_FAIL( "Sorry, AddWord not implemented" ); } else // Ignore { diff --git a/editeng/source/editeng/impedit2.cxx b/editeng/source/editeng/impedit2.cxx index 212b991de74e..da6cd539533d 100644 --- a/editeng/source/editeng/impedit2.cxx +++ b/editeng/source/editeng/impedit2.cxx @@ -2864,7 +2864,7 @@ EditPaM ImpEditEngine::ImpInsertParaBreak( const EditPaM& rPaM, BOOL bKeepEnding { if ( aEditDoc.Count() >= 0xFFFE ) { - DBG_ERROR( "Can't process more than 64K paragraphs!" ); + OSL_FAIL( "Can't process more than 64K paragraphs!" ); return rPaM; } @@ -3075,7 +3075,7 @@ Rectangle ImpEditEngine::PaMtoEditCursor( EditPaM aPaM, USHORT nFlags ) return aEditCursor; } } - DBG_ERROR( "Portion not found!" ); + OSL_FAIL( "Portion not found!" ); return aEditCursor; } @@ -4147,7 +4147,7 @@ long ImpEditEngine::GetXPos( ParaPortion* pParaPortion, EditLine* pLine, USHORT if( nPos >= pLine->GetCharPosArray().Count() ) { nPos = pLine->GetCharPosArray().Count()-1; - DBG_ERROR("svx::ImpEditEngine::GetXPos(), index out of range!"); + OSL_FAIL("svx::ImpEditEngine::GetXPos(), index out of range!"); } // old code restored see #i112788 (which leaves #i74188 unfixed again) diff --git a/editeng/source/editeng/impedit3.cxx b/editeng/source/editeng/impedit3.cxx index f48531cd1727..03c3bc57d54d 100644 --- a/editeng/source/editeng/impedit3.cxx +++ b/editeng/source/editeng/impedit3.cxx @@ -1048,7 +1048,7 @@ sal_Bool ImpEditEngine::CreateLines( USHORT nPara, sal_uInt32 nStartPosY ) bCompressedChars = FALSE; } break; - default: DBG_ERROR( "Was fuer ein Feature ?" ); + default: OSL_FAIL( "Was fuer ein Feature ?" ); } pNextFeature = pNode->GetCharAttribs().FindFeature( pNextFeature->GetStart() + 1 ); } @@ -1139,7 +1139,7 @@ sal_Bool ImpEditEngine::CreateLines( USHORT nPara, sal_uInt32 nStartPosY ) } else { - DBG_ERROR( "CreateLines: Tab not handled!" ); + OSL_FAIL( "CreateLines: Tab not handled!" ); } long nMaxW = aCurrentTab.nTabPos - aCurrentTab.nStartPosX - nStartX; if ( nW >= nMaxW ) @@ -1806,7 +1806,7 @@ void ImpEditEngine::ImpBreakLine( ParaPortion* pParaPortion, EditLine* pLine, Te } else if ( ( nBreakPos > nMaxBreakPos ) && !aUserOptions.allowPunctuationOutsideMargin ) { - DBG_ERROR( "I18N: XBreakIterator::getLineBreak returns position > Max" ); + OSL_FAIL( "I18N: XBreakIterator::getLineBreak returns position > Max" ); nBreakPos = nMaxBreakPos; } diff --git a/editeng/source/editeng/impedit4.cxx b/editeng/source/editeng/impedit4.cxx index 4454f2c7e5ea..277cf4fb8de6 100644 --- a/editeng/source/editeng/impedit4.cxx +++ b/editeng/source/editeng/impedit4.cxx @@ -118,7 +118,7 @@ EditPaM ImpEditEngine::Read( SvStream& rInput, const String& rBaseURL, EETextFor aPaM = ReadBin( rInput, aSel ); else { - DBG_ERROR( "Read: Unknown Format" ); + OSL_FAIL( "Read: Unknown Format" ); } FormatFullDoc(); // perhaps a simple format is enough? @@ -250,7 +250,7 @@ void ImpEditEngine::Write( SvStream& rOutput, EETextFormat eFormat, EditSelectio WriteBin( rOutput, aSel ); else { - DBG_ERROR( "Write: Unknown Format" ); + OSL_FAIL( "Write: Unknown Format" ); } } } diff --git a/editeng/source/editeng/textconv.cxx b/editeng/source/editeng/textconv.cxx index 034ee0f8f2cf..8d09f6f17215 100644 --- a/editeng/source/editeng/textconv.cxx +++ b/editeng/source/editeng/textconv.cxx @@ -234,7 +234,7 @@ void TextConvWrapper::ConvStart_impl( SvxSpellArea eArea ) } else { - DBG_ERROR( "ConvStart_impl: Unknown Area!" ); + OSL_FAIL( "ConvStart_impl: Unknown Area!" ); } } @@ -373,10 +373,10 @@ void TextConvWrapper::ReplaceUnit( case eOriginalAbove : case eReplacementBelow : case eOriginalBelow : - DBG_ERROR( "Rubies not supported" ); + OSL_FAIL( "Rubies not supported" ); break; default: - DBG_ERROR( "unexpected case" ); + OSL_FAIL( "unexpected case" ); } nUnitOffset = sal::static_int_cast< USHORT >( nUnitOffset + nUnitStart + aNewTxt.getLength()); diff --git a/editeng/source/items/flditem.cxx b/editeng/source/items/flditem.cxx index 3baae88d6636..edfe7921f88a 100644 --- a/editeng/source/items/flditem.cxx +++ b/editeng/source/items/flditem.cxx @@ -276,12 +276,12 @@ String SvxDateField::GetFormatted( Date& aDate, SvxDateFormat eFormat, SvNumberF { if ( eFormat == SVXDATEFORMAT_SYSTEM ) { - DBG_ERROR( "SVXDATEFORMAT_SYSTEM not implemented!" ); + OSL_FAIL( "SVXDATEFORMAT_SYSTEM not implemented!" ); eFormat = SVXDATEFORMAT_STDSMALL; } else if ( eFormat == SVXDATEFORMAT_APPDEFAULT ) { - DBG_ERROR( "SVXDATEFORMAT_APPDEFAULT: take them from where? "); + OSL_FAIL( "SVXDATEFORMAT_APPDEFAULT: take them from where? "); eFormat = SVXDATEFORMAT_STDSMALL; } @@ -423,7 +423,7 @@ void SvxURLField::Load( SvPersistStream & rStm ) eFormat= (SvxURLFormat)nFormat; // Relative save => make it absolute for loading - DBG_ERROR("No BaseURL!"); + OSL_FAIL("No BaseURL!"); // TODO/MBA: no BaseURL aURL = INetURLObject::GetAbsURL( String(), aTmpURL ); } @@ -433,7 +433,7 @@ void SvxURLField::Load( SvPersistStream & rStm ) void SvxURLField::Save( SvPersistStream & rStm ) { // Relative save of the URL - DBG_ERROR("No BaseURL!"); + OSL_FAIL("No BaseURL!"); // TODO/MBA: no BaseURL String aTmpURL = INetURLObject::GetRelURL( String(), aURL ); @@ -662,11 +662,11 @@ String SvxExtTimeField::GetFormatted( Time& aTime, SvxTimeFormat eFormat, SvNumb switch( eFormat ) { case SVXTIMEFORMAT_SYSTEM : - DBG_ERROR( "SVXTIMEFORMAT_SYSTEM: not implemented" ); + OSL_FAIL( "SVXTIMEFORMAT_SYSTEM: not implemented" ); eFormat = SVXTIMEFORMAT_STANDARD; break; case SVXTIMEFORMAT_APPDEFAULT : - DBG_ERROR( "SVXTIMEFORMAT_APPDEFAULT: not implemented" ); + OSL_FAIL( "SVXTIMEFORMAT_APPDEFAULT: not implemented" ); eFormat = SVXTIMEFORMAT_STANDARD; break; default: ;//prevent warning diff --git a/editeng/source/items/frmitems.cxx b/editeng/source/items/frmitems.cxx index cfea9d9ba238..45fd0b5759d7 100644 --- a/editeng/source/items/frmitems.cxx +++ b/editeng/source/items/frmitems.cxx @@ -236,7 +236,7 @@ bool SvxSizeItem::QueryValue( uno::Any& rVal, BYTE nMemberId ) const case MID_SIZE_SIZE: rVal <<= aTmp; break; case MID_SIZE_WIDTH: rVal <<= aTmp.Width; break; case MID_SIZE_HEIGHT: rVal <<= aTmp.Height; break; - default: DBG_ERROR("Wrong MemberId!"); return false; + default: OSL_FAIL("Wrong MemberId!"); return false; } return true; @@ -285,7 +285,7 @@ bool SvxSizeItem::PutValue( const uno::Any& rVal, BYTE nMemberId ) aSize.Height() = bConvert ? MM100_TO_TWIP(nVal) : nVal; } break; - default: DBG_ERROR("Wrong MemberId!"); + default: OSL_FAIL("Wrong MemberId!"); return false; } return true; @@ -470,7 +470,7 @@ bool SvxLRSpaceItem::QueryValue( uno::Any& rVal, BYTE nMemberId ) const default: bRet = false; - DBG_ERROR("unknown MemberId"); + OSL_FAIL("unknown MemberId"); } return bRet; } @@ -527,7 +527,7 @@ bool SvxLRSpaceItem::PutValue( const uno::Any& rVal, BYTE nMemberId ) break; default: - DBG_ERROR("unknown MemberId"); + OSL_FAIL("unknown MemberId"); return false; } return true; @@ -900,7 +900,7 @@ bool SvxULSpaceItem::PutValue( const uno::Any& rVal, BYTE nMemberId ) default: - DBG_ERROR("unknown MemberId"); + OSL_FAIL("unknown MemberId"); return false; } return true; @@ -1175,7 +1175,7 @@ bool SvxProtectItem::QueryValue( uno::Any& rVal, BYTE nMemberId ) const case MID_PROTECT_SIZE : bValue = bSize; break; case MID_PROTECT_POSITION: bValue = bPos; break; default: - DBG_ERROR("Wrong MemberId"); + OSL_FAIL("Wrong MemberId"); return false; } @@ -1193,7 +1193,7 @@ bool SvxProtectItem::PutValue( const uno::Any& rVal, BYTE nMemberId ) case MID_PROTECT_SIZE : bSize = bVal; break; case MID_PROTECT_POSITION: bPos = bVal; break; default: - DBG_ERROR("Wrong MemberId"); + OSL_FAIL("Wrong MemberId"); return false; } return true; @@ -1318,7 +1318,7 @@ bool SvxShadowItem::QueryValue( uno::Any& rVal, BYTE nMemberId ) const case MID_TRANSPARENT: rVal <<= aShadow.IsTransparent; break; case MID_BG_COLOR: rVal <<= aShadow.Color; break; case 0: rVal <<= aShadow; break; - default: DBG_ERROR("Wrong MemberId!"); return false; + default: OSL_FAIL("Wrong MemberId!"); return false; } return true; @@ -1351,7 +1351,7 @@ bool SvxShadowItem::PutValue( const uno::Any& rVal, BYTE nMemberId ) case MID_TRANSPARENT: rVal >>= aShadow.IsTransparent; break; case MID_BG_COLOR: rVal >>= aShadow.Color; break; case 0: rVal >>= aShadow; break; - default: DBG_ERROR("Wrong MemberId!"); return sal_False; + default: OSL_FAIL("Wrong MemberId!"); return sal_False; } if ( bRet ) @@ -1426,7 +1426,7 @@ sal_uInt16 SvxShadowItem::CalcShadowSpace( sal_uInt16 nShadow ) const break; default: - DBG_ERROR( "wrong shadow" ); + OSL_FAIL( "wrong shadow" ); } return nSpace; } @@ -2427,7 +2427,7 @@ const SvxBorderLine *SvxBoxItem::GetLine( sal_uInt16 nLine ) const pRet = pRight; break; default: - DBG_ERROR( "wrong line" ); + OSL_FAIL( "wrong line" ); break; } @@ -2459,7 +2459,7 @@ void SvxBoxItem::SetLine( const SvxBorderLine* pNew, sal_uInt16 nLine ) pRight = pTmp; break; default: - DBG_ERROR( "wrong line" ); + OSL_FAIL( "wrong line" ); } } @@ -2499,7 +2499,7 @@ sal_uInt16 SvxBoxItem::GetDistance( sal_uInt16 nLine ) const nDist = nRightDist; break; default: - DBG_ERROR( "wrong line" ); + OSL_FAIL( "wrong line" ); } return nDist; @@ -2524,7 +2524,7 @@ void SvxBoxItem::SetDistance( sal_uInt16 nNew, sal_uInt16 nLine ) nRightDist = nNew; break; default: - DBG_ERROR( "wrong line" ); + OSL_FAIL( "wrong line" ); } } @@ -2553,7 +2553,7 @@ sal_uInt16 SvxBoxItem::CalcLineSpace( sal_uInt16 nLine, sal_Bool bIgnoreLine ) c nDist = nRightDist; break; default: - DBG_ERROR( "wrong line" ); + OSL_FAIL( "wrong line" ); } if( pTmp ) @@ -2656,7 +2656,7 @@ void SvxBoxInfoItem::SetLine( const SvxBorderLine* pNew, sal_uInt16 nLine ) } else { - DBG_ERROR( "wrong line" ); + OSL_FAIL( "wrong line" ); } } @@ -2830,7 +2830,7 @@ bool SvxBoxInfoItem::QueryValue( uno::Any& rVal, BYTE nMemberId ) const bIntMember = sal_True; rVal <<= (sal_Int32)(bConvert ? TWIP_TO_MM100_UNSIGNED(GetDefDist()) : GetDefDist()); break; - default: DBG_ERROR("Wrong MemberId!"); return false; + default: OSL_FAIL("Wrong MemberId!"); return false; } if( !bIntMember ) @@ -2977,7 +2977,7 @@ bool SvxBoxInfoItem::PutValue( const uno::Any& rVal, BYTE nMemberId ) } break; } - default: DBG_ERROR("Wrong MemberId!"); return sal_False; + default: OSL_FAIL("Wrong MemberId!"); return sal_False; } return sal_True; @@ -3249,7 +3249,7 @@ bool SvxLineItem::QueryValue( uno::Any& rVal, BYTE nMemId ) const case MID_INNER_WIDTH: rVal <<= sal_Int32(pLine->GetInWidth( )); break; case MID_DISTANCE: rVal <<= sal_Int32(pLine->GetDistance()); break; default: - DBG_ERROR( "Wrong MemberId" ); + OSL_FAIL( "Wrong MemberId" ); return false; } } @@ -3290,7 +3290,7 @@ bool SvxLineItem::PutValue( const uno::Any& rVal, BYTE nMemId ) case MID_DISTANCE: pLine->SetDistance((USHORT)nVal); break; case MID_LINE_STYLE: pLine->SetStyle((SvxBorderStyle)nVal); break; default: - DBG_ERROR( "Wrong MemberId" ); + OSL_FAIL( "Wrong MemberId" ); return sal_False; } @@ -3604,7 +3604,7 @@ SvxBrushItem::SvxBrushItem( SvStream& rStream, sal_uInt16 nVersion, rStream.ReadByteString(aRel); // TODO/MBA: how can we get a BaseURL here?! - DBG_ERROR("No BaseURL!"); + OSL_FAIL("No BaseURL!"); String aAbs = INetURLObject::GetAbsURL( String(), aRel ); DBG_ASSERT( aAbs.Len(), "Invalid URL!" ); pStrLink = new String( aAbs ); @@ -3787,7 +3787,7 @@ bool SvxBrushItem::PutValue( const uno::Any& rVal, BYTE nMemberId ) if( 0 == sLink.compareToAscii( UNO_NAME_GRAPHOBJ_URLPKGPREFIX, sizeof(UNO_NAME_GRAPHOBJ_URLPKGPREFIX)-1 ) ) { - DBG_ERROR( "package urls aren't implemented" ); + OSL_FAIL( "package urls aren't implemented" ); } else if( 0 == sLink.compareToAscii( UNO_NAME_GRAPHOBJ_URLPREFIX, sizeof(UNO_NAME_GRAPHOBJ_URLPREFIX)-1 ) ) @@ -3987,7 +3987,7 @@ SvStream& SvxBrushItem::Store( SvStream& rStream , sal_uInt16 /*nItemVersion*/ ) rStream << pImpl->pGraphicObject->GetGraphic(); if ( pStrLink ) { - DBG_ERROR("No BaseURL!"); + OSL_FAIL("No BaseURL!"); // TODO/MBA: how to get a BaseURL?! String aRel = INetURLObject::GetRelURL( String(), *pStrLink ); // UNICODE: rStream << aRel; @@ -4109,7 +4109,7 @@ void SvxBrushItem::SetGraphic( const Graphic& rNew ) } else { - DBG_ERROR( "SetGraphic() on linked graphic! :-/" ); + OSL_FAIL( "SetGraphic() on linked graphic! :-/" ); } } @@ -4131,7 +4131,7 @@ void SvxBrushItem::SetGraphicObject( const GraphicObject& rNewObj ) } else { - DBG_ERROR( "SetGraphic() on linked graphic! :-/" ); + OSL_FAIL( "SetGraphic() on linked graphic! :-/" ); } } @@ -4395,7 +4395,7 @@ bool SvxFrameDirectionItem::QueryValue( com::sun::star::uno::Any& rVal, nVal = text::WritingMode2::PAGE; break; default: - DBG_ERROR("Unknown SvxFrameDirection value!"); + OSL_FAIL("Unknown SvxFrameDirection value!"); bRet = false; break; } diff --git a/editeng/source/items/itemtype.cxx b/editeng/source/items/itemtype.cxx index 0bc0e3921b12..0d169e4b0b00 100644 --- a/editeng/source/items/itemtype.cxx +++ b/editeng/source/items/itemtype.cxx @@ -96,7 +96,7 @@ XubString GetMetricText( long nVal, SfxMapUnit eSrcUnit, SfxMapUnit eDestUnit, c nVal, (MapUnit)eSrcUnit, (MapUnit)eDestUnit )); default: - DBG_ERROR( "not supported mapunit" ); + OSL_FAIL( "not supported mapunit" ); return sRet; } @@ -227,7 +227,7 @@ sal_uInt16 GetMetricId( SfxMapUnit eUnit ) break; default: - DBG_ERROR( "not supported mapunit" ); + OSL_FAIL( "not supported mapunit" ); } return nId; } diff --git a/editeng/source/items/paraitem.cxx b/editeng/source/items/paraitem.cxx index 135face506ce..d8807301872b 100644 --- a/editeng/source/items/paraitem.cxx +++ b/editeng/source/items/paraitem.cxx @@ -184,7 +184,7 @@ bool SvxLineSpacingItem::QueryValue( uno::Any& rVal, BYTE nMemberId ) const case 0 : rVal <<= aLSp; break; case MID_LINESPACE : rVal <<= aLSp.Mode; break; case MID_HEIGHT : rVal <<= aLSp.Height; break; - default: DBG_ERROR("Wrong MemberId!"); break; + default: OSL_FAIL("Wrong MemberId!"); break; } return true; @@ -206,7 +206,7 @@ bool SvxLineSpacingItem::PutValue( const uno::Any& rVal, BYTE nMemberId ) case 0 : bRet = (rVal >>= aLSp); break; case MID_LINESPACE : bRet = (rVal >>= aLSp.Mode); break; case MID_HEIGHT : bRet = (rVal >>= aLSp.Height); break; - default: DBG_ERROR("Wrong MemberId!"); break; + default: OSL_FAIL("Wrong MemberId!"); break; } if( bRet ) @@ -1347,7 +1347,7 @@ bool SvxPageModelItem::QueryValue( com::sun::star::uno::Any& rVal, BYTE nMemberI { case MID_AUTO: rVal <<= (sal_Bool) bAuto; break; case MID_NAME: rVal <<= ::rtl::OUString( GetValue() ); break; - default: DBG_ERROR("Wrong MemberId!"); return sal_False; + default: OSL_FAIL("Wrong MemberId!"); return sal_False; } return sal_True; @@ -1362,7 +1362,7 @@ bool SvxPageModelItem::PutValue( const com::sun::star::uno::Any& rVal, BYTE nMem { case MID_AUTO: bRet = ( rVal >>= bAuto ); break; case MID_NAME: bRet = ( rVal >>= aStr ); if ( bRet ) SetValue(aStr); break; - default: DBG_ERROR("Wrong MemberId!"); return sal_False; + default: OSL_FAIL("Wrong MemberId!"); return sal_False; } return bRet; diff --git a/editeng/source/items/textitem.cxx b/editeng/source/items/textitem.cxx index 33b3875044a7..0d172cf481bf 100644 --- a/editeng/source/items/textitem.cxx +++ b/editeng/source/items/textitem.cxx @@ -1386,7 +1386,7 @@ SfxItemPresentation SvxTextLineItem::GetPresentation XubString SvxTextLineItem::GetValueTextByPos( USHORT /*nPos*/ ) const { - DBG_ERROR("SvxTextLineItem::GetValueTextByPos: Pure virtual method"); + OSL_FAIL("SvxTextLineItem::GetValueTextByPos: Pure virtual method"); return XubString(); } @@ -3390,7 +3390,7 @@ bool SvxCharScaleWidthItem::PutValue( const uno::Any& rVal, BYTE /*nMemberId*/ ) return true; } - DBG_ERROR( "SvxCharScaleWidthItem::PutValue - Wrong type!" ); + OSL_FAIL( "SvxCharScaleWidthItem::PutValue - Wrong type!" ); return false; } diff --git a/editeng/source/items/writingmodeitem.cxx b/editeng/source/items/writingmodeitem.cxx index 82fde31f946c..bcf47dd222f7 100644 --- a/editeng/source/items/writingmodeitem.cxx +++ b/editeng/source/items/writingmodeitem.cxx @@ -65,13 +65,13 @@ SfxPoolItem* SvxWritingModeItem::Clone( SfxItemPool * ) const SfxPoolItem* SvxWritingModeItem::Create( SvStream & , USHORT ) const { - DBG_ERROR("SvxWritingModeItem should not be streamed!"); + OSL_FAIL("SvxWritingModeItem should not be streamed!"); return NULL; } SvStream& SvxWritingModeItem::Store( SvStream & rStrm, USHORT ) const { - DBG_ERROR("SvxWritingModeItem should not be streamed!"); + OSL_FAIL("SvxWritingModeItem should not be streamed!"); return rStrm; } diff --git a/editeng/source/misc/hangulhanja.cxx b/editeng/source/misc/hangulhanja.cxx index 21b88157bfba..ec0a91166ebc 100644 --- a/editeng/source/misc/hangulhanja.cxx +++ b/editeng/source/misc/hangulhanja.cxx @@ -279,7 +279,7 @@ namespace editeng m_eConvType = HHC::eConvSimplifiedTraditional; else { - DBG_ERROR( "failed to determine conversion type from languages" ); + OSL_FAIL( "failed to determine conversion type from languages" ); } // set remaining conversion parameters to their default values @@ -450,7 +450,7 @@ namespace editeng } catch( const Exception& ) { - DBG_ERROR( "HangulHanjaConversion_Impl::implNextConvertibleUnit: caught an exception!" ); + OSL_FAIL( "HangulHanjaConversion_Impl::implNextConvertibleUnit: caught an exception!" ); //!!! at least we want to move on in the text in order //!!! to avoid an endless loop... @@ -652,7 +652,7 @@ namespace editeng } catch( const Exception& ) { - DBG_ERROR( "HangulHanjaConversion_Impl::implGetConversionDirectionForCurrentPortion: caught an exception!" ); + OSL_FAIL( "HangulHanjaConversion_Impl::implGetConversionDirectionForCurrentPortion: caught an exception!" ); } } @@ -755,7 +755,7 @@ namespace editeng case HHC::eRubyHangulAbove: eAction = bOriginalIsHangul ? HHC::eOriginalAbove : HHC::eReplacementAbove; break; case HHC::eRubyHangulBelow: eAction = bOriginalIsHangul ? HHC::eOriginalBelow : HHC::eReplacementBelow; break; default: - DBG_ERROR( "HangulHanjaConversion_Impl::implChange: invalid/unexpected conversion format!" ); + OSL_FAIL( "HangulHanjaConversion_Impl::implChange: invalid/unexpected conversion format!" ); } } @@ -808,7 +808,7 @@ namespace editeng } catch( const Exception& ) { - DBG_ERROR( "HangulHanjaConversion_Impl::implChange: caught unexpected exception!" ); + OSL_FAIL( "HangulHanjaConversion_Impl::implChange: caught unexpected exception!" ); aOffsets.realloc(0); } } @@ -988,7 +988,7 @@ namespace editeng } catch( const Exception& ) { - DBG_ERROR( "HangulHanjaConversion_Impl::OnFind: caught an exception!" ); + OSL_FAIL( "HangulHanjaConversion_Impl::OnFind: caught an exception!" ); } } return 0L; @@ -1053,7 +1053,7 @@ namespace editeng void HangulHanjaConversion::GetNextPortion( ::rtl::OUString&, LanguageType&, sal_Bool ) { - DBG_ERROR( "HangulHanjaConversion::GetNextPortion: to be overridden!" ); + OSL_FAIL( "HangulHanjaConversion::GetNextPortion: to be overridden!" ); } void HangulHanjaConversion::ReplaceUnit( @@ -1064,12 +1064,12 @@ namespace editeng ReplacementAction, LanguageType * ) { - DBG_ERROR( "HangulHanjaConversion::ReplaceUnit: to be overridden!" ); + OSL_FAIL( "HangulHanjaConversion::ReplaceUnit: to be overridden!" ); } sal_Bool HangulHanjaConversion::HasRubySupport() const { - DBG_ERROR( "HangulHanjaConversion::HasRubySupport: to be overridden!" ); + OSL_FAIL( "HangulHanjaConversion::HasRubySupport: to be overridden!" ); return sal_False; } diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx index 0dfb8943360f..5e0a8b3f32f4 100644 --- a/editeng/source/misc/svxacorr.cxx +++ b/editeng/source/misc/svxacorr.cxx @@ -1472,7 +1472,7 @@ void SvxAutoCorrect::SaveCplSttExceptList( LanguageType eLang ) #ifdef DBG_UTIL else { - DBG_ERROR("Save an empty list? "); + OSL_FAIL("Save an empty list? "); } #endif } @@ -1488,7 +1488,7 @@ void SvxAutoCorrect::SaveWrdSttExceptList(LanguageType eLang) #ifdef DBG_UTIL else { - DBG_ERROR("Save an empty list? "); + OSL_FAIL("Save an empty list? "); } #endif } diff --git a/editeng/source/misc/unolingu.cxx b/editeng/source/misc/unolingu.cxx index 1eb6f63e69e1..3a2f8720a8b0 100644 --- a/editeng/source/misc/unolingu.cxx +++ b/editeng/source/misc/unolingu.cxx @@ -161,7 +161,7 @@ Sequence< OUString > lcl_GetLastFoundSvcs( aRes = aSvcImplNames; else { - DBG_ERROR( "type mismatch" ); + OSL_FAIL( "type mismatch" ); } } } @@ -393,7 +393,7 @@ void SvxLinguConfigUpdate::UpdateAll( sal_Bool bForceCheck ) if (!bRes) { #if OSL_DEBUG_LEVEL > 1 - DBG_ERROR( "failed to set new configuration values" ); + OSL_FAIL( "failed to set new configuration values" ); #endif } } diff --git a/editeng/source/outliner/outliner.cxx b/editeng/source/outliner/outliner.cxx index 90b661dd5791..ea79c8e14371 100644 --- a/editeng/source/outliner/outliner.cxx +++ b/editeng/source/outliner/outliner.cxx @@ -258,7 +258,7 @@ void Outliner::Init( USHORT nMode ) nCtrl |= EE_CNTRL_OUTLINER; break; - default: DBG_ERROR( "Outliner::Init - Invalid Mode!" ); + default: OSL_FAIL( "Outliner::Init - Invalid Mode!" ); } pEditEngine->SetControlWord( nCtrl ); diff --git a/editeng/source/outliner/outlundo.cxx b/editeng/source/outliner/outlundo.cxx index f4d2f939c1e3..9b3c720d11ec 100644 --- a/editeng/source/outliner/outlundo.cxx +++ b/editeng/source/outliner/outlundo.cxx @@ -132,7 +132,7 @@ void OutlinerUndoChangeDepth::Redo() void OutlinerUndoChangeDepth::Repeat() { - DBG_ERROR( "Repeat not implemented!" ); + OSL_FAIL( "Repeat not implemented!" ); } @@ -158,7 +158,7 @@ void OutlinerUndoCheckPara::Redo() void OutlinerUndoCheckPara::Repeat() { - DBG_ERROR( "Repeat not implemented!" ); + OSL_FAIL( "Repeat not implemented!" ); } DBG_NAME(OLUndoExpand); @@ -231,7 +231,7 @@ void OLUndoExpand::Redo() void OLUndoExpand::Repeat() { DBG_CHKTHIS(OLUndoExpand,0); - DBG_ERROR("Not implemented"); + OSL_FAIL("Not implemented"); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/editeng/source/outliner/outlvw.cxx b/editeng/source/outliner/outlvw.cxx index d7280fa16f3d..ff66af048c18 100644 --- a/editeng/source/outliner/outlvw.cxx +++ b/editeng/source/outliner/outlvw.cxx @@ -1430,7 +1430,7 @@ void OutlinerView::StartTextConversion( } else { - DBG_ERROR( "unexpected language" ); + OSL_FAIL( "unexpected language" ); } } diff --git a/editeng/source/outliner/paralist.cxx b/editeng/source/outliner/paralist.cxx index 11984494aa1c..9e2763e55b34 100644 --- a/editeng/source/outliner/paralist.cxx +++ b/editeng/source/outliner/paralist.cxx @@ -156,7 +156,7 @@ void ParagraphList::MoveParagraphs( ULONG nStart, ULONG nDest, ULONG _nCount ) } else { - DBG_ERROR( "MoveParagraphs: Invalid Parameters" ); + OSL_FAIL( "MoveParagraphs: Invalid Parameters" ); } } diff --git a/editeng/source/uno/unoedhlp.cxx b/editeng/source/uno/unoedhlp.cxx index 791e2c6d97ae..fc7dc6e64c34 100644 --- a/editeng/source/uno/unoedhlp.cxx +++ b/editeng/source/uno/unoedhlp.cxx @@ -124,7 +124,7 @@ void SvxEditSourceHint::SetEndValue( ULONG n ) return ::std::auto_ptr<SfxHint>( new TextHint( TEXT_HINT_INPUT_END, 0 ) ); default: - DBG_ERROR( "SvxEditSourceHelper::EENotification2Hint unknown notification" ); + OSL_FAIL( "SvxEditSourceHelper::EENotification2Hint unknown notification" ); break; } } diff --git a/editeng/source/uno/unoedprx.cxx b/editeng/source/uno/unoedprx.cxx index 1c42104550f4..1d1917d6765d 100644 --- a/editeng/source/uno/unoedprx.cxx +++ b/editeng/source/uno/unoedprx.cxx @@ -1187,23 +1187,23 @@ sal_Bool SvxAccessibleTextAdapter::IsEditable( const ESelection& rSel ) const SfxItemSet * SvxAccessibleTextAdapter::GetEmptyItemSetPtr() { - DBG_ERROR( "not implemented" ); + OSL_FAIL( "not implemented" ); return 0; } void SvxAccessibleTextAdapter::AppendParagraph() { - DBG_ERROR( "not implemented" ); + OSL_FAIL( "not implemented" ); } xub_StrLen SvxAccessibleTextAdapter::AppendTextPortion( USHORT, const String &, const SfxItemSet & ) { - DBG_ERROR( "not implemented" ); + OSL_FAIL( "not implemented" ); return 0; } void SvxAccessibleTextAdapter::CopyText(const SvxTextForwarder&) { - DBG_ERROR( "not implemented" ); + OSL_FAIL( "not implemented" ); } diff --git a/editeng/source/uno/unoedsrc.cxx b/editeng/source/uno/unoedsrc.cxx index aa54261945fe..b245cc4d6c32 100644 --- a/editeng/source/uno/unoedsrc.cxx +++ b/editeng/source/uno/unoedsrc.cxx @@ -83,7 +83,7 @@ SvxEditViewForwarder* SvxEditSource::GetEditViewForwarder( sal_Bool ) SfxBroadcaster& SvxEditSource::GetBroadcaster() const { - DBG_ERROR("SvxEditSource::GetBroadcaster called for implementation missing this feature!"); + OSL_FAIL("SvxEditSource::GetBroadcaster called for implementation missing this feature!"); static SfxBroadcaster aBroadcaster; diff --git a/editeng/source/uno/unofored.cxx b/editeng/source/uno/unofored.cxx index d06c48754bd8..8888a3553f12 100644 --- a/editeng/source/uno/unofored.cxx +++ b/editeng/source/uno/unofored.cxx @@ -91,7 +91,7 @@ SfxItemSet SvxEditEngineForwarder::GetAttribs( const ESelection& rSel, BOOL bOnl nFlags = GETATTRIBS_CHARATTRIBS; break; default: - DBG_ERROR("unknown flags for SvxOutlinerForwarder::GetAttribs"); + OSL_FAIL("unknown flags for SvxOutlinerForwarder::GetAttribs"); } return rEditEngine.GetAttribs( rSel.nStartPara, rSel.nStartPos, rSel.nEndPos, nFlags ); diff --git a/editeng/source/uno/unoforou.cxx b/editeng/source/uno/unoforou.cxx index 2d6ef9c39ca9..feb5cdc166f2 100644 --- a/editeng/source/uno/unoforou.cxx +++ b/editeng/source/uno/unoforou.cxx @@ -100,7 +100,7 @@ static SfxItemSet ImplOutlinerForwarderGetAttribs( const ESelection& rSel, BOOL nFlags = GETATTRIBS_CHARATTRIBS; break; default: - DBG_ERROR("unknown flags for SvxOutlinerForwarder::GetAttribs"); + OSL_FAIL("unknown flags for SvxOutlinerForwarder::GetAttribs"); } return rEditEngine.GetAttribs( rSel.nStartPara, rSel.nStartPos, rSel.nEndPos, nFlags ); } @@ -508,7 +508,7 @@ sal_Int16 SvxOutlinerForwarder::GetNumberingStartValue( sal_uInt16 nPara ) } else { - DBG_ERROR( "SvxOutlinerForwarder::GetNumberingStartValue)(), Invalid paragraph index"); + OSL_FAIL( "SvxOutlinerForwarder::GetNumberingStartValue)(), Invalid paragraph index"); return -1; } } @@ -521,7 +521,7 @@ void SvxOutlinerForwarder::SetNumberingStartValue( sal_uInt16 nPara, sal_Int16 } else { - DBG_ERROR( "SvxOutlinerForwarder::SetNumberingStartValue)(), Invalid paragraph index"); + OSL_FAIL( "SvxOutlinerForwarder::SetNumberingStartValue)(), Invalid paragraph index"); } } @@ -533,7 +533,7 @@ sal_Bool SvxOutlinerForwarder::IsParaIsNumberingRestart( sal_uInt16 nPara ) } else { - DBG_ERROR( "SvxOutlinerForwarder::IsParaIsNumberingRestart)(), Invalid paragraph index"); + OSL_FAIL( "SvxOutlinerForwarder::IsParaIsNumberingRestart)(), Invalid paragraph index"); return sal_False; } } @@ -546,7 +546,7 @@ void SvxOutlinerForwarder::SetParaIsNumberingRestart( sal_uInt16 nPara, sal_Boo } else { - DBG_ERROR( "SvxOutlinerForwarder::SetParaIsNumberingRestart)(), Invalid paragraph index"); + OSL_FAIL( "SvxOutlinerForwarder::SetParaIsNumberingRestart)(), Invalid paragraph index"); } } diff --git a/editeng/source/uno/unoipset.cxx b/editeng/source/uno/unoipset.cxx index 3fb7a4974812..2802b87afb6f 100644 --- a/editeng/source/uno/unoipset.cxx +++ b/editeng/source/uno/unoipset.cxx @@ -155,7 +155,7 @@ uno::Any SvxItemPropertySet::getPropertyValue( const SfxItemPropertySimpleEntry* } else { - DBG_ERROR( "No SfxPoolItem found for property!" ); + OSL_FAIL( "No SfxPoolItem found for property!" ); } return aVal; @@ -178,7 +178,7 @@ void SvxItemPropertySet::setPropertyValue( const SfxItemPropertySimpleEntry* pMa { if( pPool == NULL ) { - DBG_ERROR( "No default item and no pool?" ); + OSL_FAIL( "No default item and no pool?" ); return; } @@ -331,13 +331,13 @@ void SvxUnoConvertToMM( const SfxMapUnit eSourceMapUnit, uno::Any & rMetric ) th rMetric <<= (sal_uInt32)(TWIPS_TO_MM(*(sal_uInt32*)rMetric.getValue())); break; default: - DBG_ERROR("AW: Missing unit translation to 100th mm!"); + OSL_FAIL("AW: Missing unit translation to 100th mm!"); } break; } default: { - DBG_ERROR("AW: Missing unit translation to 100th mm!"); + OSL_FAIL("AW: Missing unit translation to 100th mm!"); } } } @@ -369,13 +369,13 @@ void SvxUnoConvertFromMM( const SfxMapUnit eDestinationMapUnit, uno::Any & rMetr rMetric <<= (sal_uInt32)(MM_TO_TWIPS(*(sal_uInt32*)rMetric.getValue())); break; default: - DBG_ERROR("AW: Missing unit translation to 100th mm!"); + OSL_FAIL("AW: Missing unit translation to 100th mm!"); } break; } default: { - DBG_ERROR("AW: Missing unit translation to PoolMetrics!"); + OSL_FAIL("AW: Missing unit translation to PoolMetrics!"); } } } diff --git a/editeng/source/xml/xmltxtexp.cxx b/editeng/source/xml/xmltxtexp.cxx index 549c66a47782..f62f4054fd0c 100644 --- a/editeng/source/xml/xmltxtexp.cxx +++ b/editeng/source/xml/xmltxtexp.cxx @@ -428,7 +428,7 @@ void SvxWriteXML( EditEngine& rEditEngine, SvStream& rStream, const ESelection& if( !xServiceFactory.is() ) { - DBG_ERROR( "got no service manager" ); + OSL_FAIL( "got no service manager" ); break; } @@ -438,7 +438,7 @@ void SvxWriteXML( EditEngine& rEditEngine, SvStream& rStream, const ESelection& if( !xWriter.is() ) { - DBG_ERROR( "com.sun.star.xml.sax.Writer service missing" ); + OSL_FAIL( "com.sun.star.xml.sax.Writer service missing" ); break; } @@ -475,7 +475,7 @@ void SvxWriteXML( EditEngine& rEditEngine, SvStream& rStream, const ESelection& } catch( uno::Exception& ) { - DBG_ERROR("exception during xml export"); + OSL_FAIL("exception during xml export"); } } diff --git a/editeng/source/xml/xmltxtimp.cxx b/editeng/source/xml/xmltxtimp.cxx index 178e08001e9e..a09c125fe0ff 100644 --- a/editeng/source/xml/xmltxtimp.cxx +++ b/editeng/source/xml/xmltxtimp.cxx @@ -174,14 +174,14 @@ void SvxReadXML( EditEngine& rEditEngine, SvStream& rStream, const ESelection& r uno::Reference<lang::XMultiServiceFactory> xServiceFactory( ::comphelper::getProcessServiceFactory() ); if( !xServiceFactory.is() ) { - DBG_ERROR( "SvxXMLXTableImport::load: got no service manager" ); + OSL_FAIL( "SvxXMLXTableImport::load: got no service manager" ); break; } uno::Reference< xml::sax::XParser > xParser( xServiceFactory->createInstance( OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.xml.sax.Parser" ) ) ), uno::UNO_QUERY ); if( !xParser.is() ) { - DBG_ERROR( "com.sun.star.xml.sax.Parser service missing" ); + OSL_FAIL( "com.sun.star.xml.sax.Parser service missing" ); break; } @@ -198,14 +198,14 @@ void SvxReadXML( EditEngine& rEditEngine, SvStream& rStream, const ESelection& r if( !xSource.is() ) { - DBG_ERROR( "got no data source from medium" ); + OSL_FAIL( "got no data source from medium" ); break; } uno::Reference< XInterface > xPipe( xServiceFactory->createInstance(OUString( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.io.Pipe") ) ) ); if( !xPipe.is() ) { - DBG_ERROR( "XMLReader::Read: com.sun.star.io.Pipe service missing" ); + OSL_FAIL( "XMLReader::Read: com.sun.star.io.Pipe service missing" ); break; } |