diff options
author | Thomas Arnhold <thomas@arnhold.org> | 2011-03-01 19:05:02 +0100 |
---|---|---|
committer | Thomas Arnhold <thomas@arnhold.org> | 2011-03-02 14:58:56 +0100 |
commit | 7b3e53b0a2700324492ec36d097cc9e68cdb7350 (patch) | |
tree | c7005c37b9d123a70b7bf8a497ff26f365d1d70a | |
parent | 73788ffb2117bd2f4119281b8d9a0dd6481f8c6b (diff) |
Move DBG_ERROR to OSL_FAIL
209 files changed, 671 insertions, 667 deletions
diff --git a/chart2/source/controller/chartapiwrapper/DiagramWrapper.cxx b/chart2/source/controller/chartapiwrapper/DiagramWrapper.cxx index 91ad0d864..6e94705f1 100644 --- a/chart2/source/controller/chartapiwrapper/DiagramWrapper.cxx +++ b/chart2/source/controller/chartapiwrapper/DiagramWrapper.cxx @@ -757,7 +757,7 @@ void SAL_CALL DiagramWrapper::setPosition( const awt::Point& aPosition ) aRelativePosition.Secondary = double(aPosition.Y)/double(aPageSize.Height); if( aRelativePosition.Primary < 0 || aRelativePosition.Secondary < 0 || aRelativePosition.Primary > 1 || aRelativePosition.Secondary > 1 ) { - DBG_ERROR("DiagramWrapper::setPosition called with a position out of range -> automatic values are taken instead" ); + OSL_FAIL("DiagramWrapper::setPosition called with a position out of range -> automatic values are taken instead" ); uno::Any aEmpty; xProp->setPropertyValue( C2U( "RelativePosition" ), aEmpty ); return; @@ -790,7 +790,7 @@ void SAL_CALL DiagramWrapper::setSize( const awt::Size& aSize ) if( aRelativeSize.Primary > 1 || aRelativeSize.Secondary > 1 ) { - DBG_ERROR("DiagramWrapper::setSize called with sizes bigger than page -> automatic values are taken instead" ); + OSL_FAIL("DiagramWrapper::setSize called with sizes bigger than page -> automatic values are taken instead" ); uno::Any aEmpty; xProp->setPropertyValue( C2U( "RelativeSize" ), aEmpty ); return; @@ -2043,7 +2043,7 @@ void SAL_CALL DiagramWrapper::setDiagram( throw (uno::RuntimeException) { //@todo: remove this method from interface - DBG_ERROR("DiagramWrapper::setDiagram is not implemented, should be removed and not be called" ); + OSL_FAIL("DiagramWrapper::setDiagram is not implemented, should be removed and not be called" ); } // ================================================================================ diff --git a/chart2/source/controller/chartapiwrapper/WrappedNumberFormatProperty.cxx b/chart2/source/controller/chartapiwrapper/WrappedNumberFormatProperty.cxx index 7aac28c78..1116f623d 100644 --- a/chart2/source/controller/chartapiwrapper/WrappedNumberFormatProperty.cxx +++ b/chart2/source/controller/chartapiwrapper/WrappedNumberFormatProperty.cxx @@ -90,7 +90,7 @@ Any WrappedNumberFormatProperty::getPropertyValue( const Reference< beans::XProp { if( !xInnerPropertySet.is() ) { - DBG_ERROR("missing xInnerPropertySet in WrappedNumberFormatProperty::getPropertyValue"); + OSL_FAIL("missing xInnerPropertySet in WrappedNumberFormatProperty::getPropertyValue"); return Any(); } Any aRet( xInnerPropertySet->getPropertyValue( m_aInnerName )); @@ -142,7 +142,7 @@ void WrappedLinkNumberFormatProperty::setPropertyValue( const Any& rOuterValue, { if( !xInnerPropertySet.is() ) { - DBG_ERROR("missing xInnerPropertySet in WrappedNumberFormatProperty::setPropertyValue"); + OSL_FAIL("missing xInnerPropertySet in WrappedNumberFormatProperty::setPropertyValue"); return; } @@ -178,7 +178,7 @@ Any WrappedLinkNumberFormatProperty::getPropertyValue( const Reference< beans::X { if( !xInnerPropertySet.is() ) { - DBG_ERROR("missing xInnerPropertySet in WrappedNumberFormatProperty::getPropertyValue"); + OSL_FAIL("missing xInnerPropertySet in WrappedNumberFormatProperty::getPropertyValue"); return getPropertyDefault(0); } bool bLink = ! xInnerPropertySet->getPropertyValue( C2U("NumberFormat" )).hasValue(); diff --git a/chart2/source/controller/dialogs/DataBrowser.cxx b/chart2/source/controller/dialogs/DataBrowser.cxx index 31f2d8a3b..85bbc8c82 100644 --- a/chart2/source/controller/dialogs/DataBrowser.cxx +++ b/chart2/source/controller/dialogs/DataBrowser.cxx @@ -1096,7 +1096,7 @@ void DataBrowser::InitController( } else { - DBG_ERROR( "Invalid Controller" ); + OSL_FAIL( "Invalid Controller" ); } } diff --git a/chart2/source/controller/dialogs/ObjectNameProvider.cxx b/chart2/source/controller/dialogs/ObjectNameProvider.cxx index b32ab04e7..92355fac9 100644 --- a/chart2/source/controller/dialogs/ObjectNameProvider.cxx +++ b/chart2/source/controller/dialogs/ObjectNameProvider.cxx @@ -401,7 +401,7 @@ OUString ObjectNameProvider::getTitleNameByType( TitleHelper::eTitleType eType ) aRet=String(SchResId(STR_OBJECT_TITLE_SECONDARY_Y_AXIS)); break; default: - DBG_ERROR("unknown title type"); + OSL_FAIL("unknown title type"); break; } diff --git a/chart2/source/controller/dialogs/res_DataLabel.cxx b/chart2/source/controller/dialogs/res_DataLabel.cxx index 1468c0960..906427587 100644 --- a/chart2/source/controller/dialogs/res_DataLabel.cxx +++ b/chart2/source/controller/dialogs/res_DataLabel.cxx @@ -236,7 +236,7 @@ IMPL_LINK( DataLabelResources, NumberFormatDialogHdl, PushButton *, pButton ) { if( !m_pPool || !m_pNumberFormatter ) { - DBG_ERROR("Missing item pool or number formatter"); + OSL_FAIL("Missing item pool or number formatter"); return 1; } diff --git a/chart2/source/controller/dialogs/tp_Scale.cxx b/chart2/source/controller/dialogs/tp_Scale.cxx index 9ade73b44..1d98cfecb 100644 --- a/chart2/source/controller/dialogs/tp_Scale.cxx +++ b/chart2/source/controller/dialogs/tp_Scale.cxx @@ -342,7 +342,7 @@ int ScaleTabPage::DeactivatePage(SfxItemSet* pItemSet) { if( !pNumFormatter ) { - DBG_ERROR( "No NumberFormatter available" ); + OSL_FAIL( "No NumberFormatter available" ); return LEAVE_PAGE; } diff --git a/chart2/source/controller/main/ChartController_Properties.cxx b/chart2/source/controller/main/ChartController_Properties.cxx index 605858fcd..78a485d83 100644 --- a/chart2/source/controller/main/ChartController_Properties.cxx +++ b/chart2/source/controller/main/ChartController_Properties.cxx @@ -103,7 +103,7 @@ namespace ObjectType eObjectType = ObjectIdentifier::getObjectType( aObjectCID ); if( OBJECTTYPE_UNKNOWN==eObjectType ) { - DBG_ERROR("unknown ObjectType"); + OSL_FAIL("unknown ObjectType"); return NULL; } diff --git a/chart2/source/controller/main/ChartRenderer.cxx b/chart2/source/controller/main/ChartRenderer.cxx index 11f6417b2..920c54065 100644 --- a/chart2/source/controller/main/ChartRenderer.cxx +++ b/chart2/source/controller/main/ChartRenderer.cxx @@ -82,7 +82,7 @@ bool ChartRenderer::DoPaint(OutputDevice* pOutDev, const Rectangle& rLogicObject if( aContainerChartSize.Width != aChartSize.Width || aContainerChartSize.Height != aChartSize.Height ) { - DBG_ERROR("chart size does not equal size assumed by the container"); + OSL_FAIL("chart size does not equal size assumed by the container"); //correct the state here on the fly -> let the container size win ChartModelHelper::setPageSize( aContainerChartSize, xModel ); } diff --git a/chart2/source/controller/main/ChartTransferable.cxx b/chart2/source/controller/main/ChartTransferable.cxx index ad8b0d950..7c784861d 100644 --- a/chart2/source/controller/main/ChartTransferable.cxx +++ b/chart2/source/controller/main/ChartTransferable.cxx @@ -162,7 +162,7 @@ sal_Bool ChartTransferable::WriteObject( SotStorageStreamRef& rxOStm, void* pUse break; default: { - DBG_ERROR( "ChartTransferable::WriteObject: unknown object id" ); + OSL_FAIL( "ChartTransferable::WriteObject: unknown object id" ); } break; } diff --git a/chart2/source/tools/CommonConverters.cxx b/chart2/source/tools/CommonConverters.cxx index 9d2fd0eb4..0a73dfe5c 100644 --- a/chart2/source/tools/CommonConverters.cxx +++ b/chart2/source/tools/CommonConverters.cxx @@ -211,12 +211,12 @@ drawing::Position3D getPointFromPoly( const drawing::PolyPolygonShape3D& rPolygo } else { - DBG_ERROR("polygon was accessed with a wrong index"); + OSL_FAIL("polygon was accessed with a wrong index"); } } else { - DBG_ERROR("polygon was accessed with a wrong index"); + OSL_FAIL("polygon was accessed with a wrong index"); } return aRet; } diff --git a/chart2/source/tools/LegendHelper.cxx b/chart2/source/tools/LegendHelper.cxx index 280963741..512cc95cc 100644 --- a/chart2/source/tools/LegendHelper.cxx +++ b/chart2/source/tools/LegendHelper.cxx @@ -113,7 +113,7 @@ uno::Reference< chart2::XLegend > LegendHelper::getLegend( } else if(bCreate) { - DBG_ERROR("need diagram for creation of legend"); + OSL_FAIL("need diagram for creation of legend"); } } catch( uno::Exception & ex ) diff --git a/chart2/source/tools/ThreeDHelper.cxx b/chart2/source/tools/ThreeDHelper.cxx index b7e63bc17..83ee9d51a 100644 --- a/chart2/source/tools/ThreeDHelper.cxx +++ b/chart2/source/tools/ThreeDHelper.cxx @@ -555,7 +555,7 @@ void ThreeDHelper::convertElevationRotationDegToXYZAngleRad( z = atan(tan(R) * sin(E)); if(cos(z)==0.0) { - DBG_ERROR("calculation error in ThreeDHelper::convertElevationRotationDegToXYZAngleRad"); + OSL_FAIL("calculation error in ThreeDHelper::convertElevationRotationDegToXYZAngleRad"); return; } double cy = cos(R)/cos(z); @@ -566,7 +566,7 @@ void ThreeDHelper::convertElevationRotationDegToXYZAngleRad( double fDenominator = cos(z)*(1.0-pow(sin(y),2)); if(fDenominator==0.0) { - DBG_ERROR("calculation error in ThreeDHelper::convertElevationRotationDegToXYZAngleRad"); + OSL_FAIL("calculation error in ThreeDHelper::convertElevationRotationDegToXYZAngleRad"); return; } double sx = cos(R)*sin(E)/fDenominator; diff --git a/chart2/source/tools/WrappedPropertySet.cxx b/chart2/source/tools/WrappedPropertySet.cxx index df2487729..dc4c6893d 100644 --- a/chart2/source/tools/WrappedPropertySet.cxx +++ b/chart2/source/tools/WrappedPropertySet.cxx @@ -116,7 +116,7 @@ void SAL_CALL WrappedPropertySet::setPropertyValue( const OUString& rPropertyNam else { #if OSL_DEBUG_LEVEL > 1 - DBG_ERROR("found no inner property set to map to"); + OSL_FAIL("found no inner property set to map to"); #endif } } @@ -165,7 +165,7 @@ Any SAL_CALL WrappedPropertySet::getPropertyValue( const OUString& rPropertyName else { #if OSL_DEBUG_LEVEL > 1 - DBG_ERROR("found no inner property set to map to"); + OSL_FAIL("found no inner property set to map to"); #endif } } diff --git a/chart2/source/view/axes/VCartesianAxis.cxx b/chart2/source/view/axes/VCartesianAxis.cxx index 99a19c050..d84357f5a 100644 --- a/chart2/source/view/axes/VCartesianAxis.cxx +++ b/chart2/source/view/axes/VCartesianAxis.cxx @@ -832,7 +832,7 @@ B2DVector VCartesianAxis::getScreenPosition( double fLogicX, double fLogicY, dou } else { - DBG_ERROR("cannot calculate scrren position in VCartesianAxis::getScreenPosition"); + OSL_FAIL("cannot calculate scrren position in VCartesianAxis::getScreenPosition"); } } else diff --git a/chart2/source/view/charttypes/AreaChart.cxx b/chart2/source/view/charttypes/AreaChart.cxx index 8c5ed9111..7682553bb 100644 --- a/chart2/source/view/charttypes/AreaChart.cxx +++ b/chart2/source/view/charttypes/AreaChart.cxx @@ -912,7 +912,7 @@ void AreaChart::createShapes() //todo implement this different for area charts break; default: - DBG_ERROR("this label alignment is not implemented yet"); + OSL_FAIL("this label alignment is not implemented yet"); aScenePosition3D.PositionY -= (aSymbolSize.DirectionY/2+1); eAlignment = LABEL_ALIGN_TOP; break; diff --git a/chart2/source/view/charttypes/BarChart.cxx b/chart2/source/view/charttypes/BarChart.cxx index feaba78fd..3f8bf9846 100644 --- a/chart2/source/view/charttypes/BarChart.cxx +++ b/chart2/source/view/charttypes/BarChart.cxx @@ -191,7 +191,7 @@ awt::Point BarChart::getLabelScreenPositionAndAlignment( { fY -= (fScaledUpperYValue-fScaledLowerYValue)/2.0; rAlignment = LABEL_ALIGN_CENTER; - DBG_ERROR( "top label placement is not really supported by horizontal bar charts" ); + OSL_FAIL( "top label placement is not really supported by horizontal bar charts" ); } } break; @@ -208,7 +208,7 @@ awt::Point BarChart::getLabelScreenPositionAndAlignment( { fY -= (fScaledUpperYValue-fScaledLowerYValue)/2.0; rAlignment = LABEL_ALIGN_CENTER; - DBG_ERROR( "bottom label placement is not supported by horizontal bar charts" ); + OSL_FAIL( "bottom label placement is not supported by horizontal bar charts" ); } } break; @@ -225,7 +225,7 @@ awt::Point BarChart::getLabelScreenPositionAndAlignment( { fY -= (fScaledUpperYValue-fScaledLowerYValue)/2.0; rAlignment = LABEL_ALIGN_CENTER; - DBG_ERROR( "left label placement is not supported by column charts" ); + OSL_FAIL( "left label placement is not supported by column charts" ); } } break; @@ -242,7 +242,7 @@ awt::Point BarChart::getLabelScreenPositionAndAlignment( { fY -= (fScaledUpperYValue-fScaledLowerYValue)/2.0; rAlignment = LABEL_ALIGN_CENTER; - DBG_ERROR( "right label placement is not supported by column charts" ); + OSL_FAIL( "right label placement is not supported by column charts" ); } } break; @@ -286,7 +286,7 @@ awt::Point BarChart::getLabelScreenPositionAndAlignment( fDepth = fabs(fScaledUpperBarDepth-fScaledLowerBarDepth)/2.0; break; default: - DBG_ERROR("this label alignment is not implemented yet"); + OSL_FAIL("this label alignment is not implemented yet"); break; } diff --git a/chart2/source/view/charttypes/BubbleChart.cxx b/chart2/source/view/charttypes/BubbleChart.cxx index 638448a57..b8d8dafe8 100644 --- a/chart2/source/view/charttypes/BubbleChart.cxx +++ b/chart2/source/view/charttypes/BubbleChart.cxx @@ -382,7 +382,7 @@ void BubbleChart::createShapes() eAlignment = LABEL_ALIGN_CENTER; break; default: - DBG_ERROR("this label alignment is not implemented yet"); + OSL_FAIL("this label alignment is not implemented yet"); aScenePosition3D.PositionY -= (aSymbolSize.DirectionY/2+1); eAlignment = LABEL_ALIGN_TOP; break; diff --git a/chart2/source/view/main/ChartView.cxx b/chart2/source/view/main/ChartView.cxx index 2a8ab68b3..204ba0b43 100644 --- a/chart2/source/view/main/ChartView.cxx +++ b/chart2/source/view/main/ChartView.cxx @@ -191,7 +191,7 @@ void SAL_CALL ChartView::initialize( const uno::Sequence< uno::Any >& aArguments uno::Reference< frame::XModel > xNewChartModel; if( !(aArguments[0] >>= xNewChartModel) ) { - DBG_ERROR( "need a Reference to frame::XModel as first parameter for view initialization" ); + OSL_FAIL( "need a Reference to frame::XModel as first parameter for view initialization" ); } impl_setChartModel( xNewChartModel ); @@ -2560,7 +2560,7 @@ void ChartView::createShapes() pPage->SetSize(Size(aPageSize.Width,aPageSize.Height)); else { - DBG_ERROR("could not set page size correctly"); + OSL_FAIL("could not set page size correctly"); } { diff --git a/chart2/source/view/main/Clipping.cxx b/chart2/source/view/main/Clipping.cxx index 2719e1477..e23501e6c 100644 --- a/chart2/source/view/main/Clipping.cxx +++ b/chart2/source/view/main/Clipping.cxx @@ -191,7 +191,7 @@ void lcl_addPointToPoly( drawing::PolyPolygonShape3D& rPoly if( nNewResultPointCount > nReallocLength ) { nReallocLength = nNewResultPointCount; - DBG_ERROR("this should not be the case to avoid performance problems"); + OSL_FAIL("this should not be the case to avoid performance problems"); } pOuterSequenceX->realloc(nReallocLength); pOuterSequenceY->realloc(nReallocLength); diff --git a/chart2/source/view/main/DrawModelWrapper.cxx b/chart2/source/view/main/DrawModelWrapper.cxx index 83e0971f3..2b68f0547 100644 --- a/chart2/source/view/main/DrawModelWrapper.cxx +++ b/chart2/source/view/main/DrawModelWrapper.cxx @@ -175,7 +175,7 @@ DrawModelWrapper::DrawModelWrapper( } catch(...) { - DBG_ERROR("Can't get Hyphenator or SpellChecker for chart"); + OSL_FAIL("Can't get Hyphenator or SpellChecker for chart"); } //ref device for font rendering diff --git a/chart2/source/view/main/NumberFormatterWrapper.cxx b/chart2/source/view/main/NumberFormatterWrapper.cxx index 24dd385f4..09d55e672 100644 --- a/chart2/source/view/main/NumberFormatterWrapper.cxx +++ b/chart2/source/view/main/NumberFormatterWrapper.cxx @@ -99,7 +99,7 @@ rtl::OUString NumberFormatterWrapper::getFormattedString( Color* pTextColor = NULL; if( !m_pNumberFormatter ) { - DBG_ERROR("Need a NumberFormatter"); + OSL_FAIL("Need a NumberFormatter"); return aText; } // i99104 handle null date correctly diff --git a/chart2/source/view/main/VDataSeries.cxx b/chart2/source/view/main/VDataSeries.cxx index 6f452b2ec..88627b125 100644 --- a/chart2/source/view/main/VDataSeries.cxx +++ b/chart2/source/view/main/VDataSeries.cxx @@ -606,7 +606,7 @@ sal_Int32 VDataSeries::getLabelPlacement( sal_Int32 nPointIndex, const uno::Refe return nLabelPlacement; } - DBG_ERROR("no label placement supported"); + OSL_FAIL("no label placement supported"); } catch( uno::Exception& e ) { diff --git a/chart2/source/view/main/VLegendSymbolFactory.cxx b/chart2/source/view/main/VLegendSymbolFactory.cxx index 485cc4953..14205060a 100644 --- a/chart2/source/view/main/VLegendSymbolFactory.cxx +++ b/chart2/source/view/main/VLegendSymbolFactory.cxx @@ -349,7 +349,7 @@ Reference< drawing::XShape > VLegendSymbolFactory::createSymbol( } else if( aSymbol.Style == chart2::SymbolStyle_AUTO ) { - DBG_ERROR("the given parameter is not allowed to contain an automatic symbol style"); + OSL_FAIL("the given parameter is not allowed to contain an automatic symbol style"); } } } diff --git a/sc/inc/miscuno.hxx b/sc/inc/miscuno.hxx index 0f5c0fde4..65d3d3136 100644 --- a/sc/inc/miscuno.hxx +++ b/sc/inc/miscuno.hxx @@ -64,22 +64,22 @@ sal_Bool SAL_CALL ClassName::supportsService( const ::rtl::OUString& ServiceName const uno::Reference<beans::XPropertyChangeListener>&) \ throw(beans::UnknownPropertyException, \ lang::WrappedTargetException, uno::RuntimeException) \ - { DBG_ERROR("not implemented"); } \ + { OSL_FAIL("not implemented"); } \ void SAL_CALL ClassName::removePropertyChangeListener( const rtl::OUString&, \ const uno::Reference<beans::XPropertyChangeListener>&) \ throw(beans::UnknownPropertyException, \ lang::WrappedTargetException, uno::RuntimeException) \ - { DBG_ERROR("not implemented"); } \ + { OSL_FAIL("not implemented"); } \ void SAL_CALL ClassName::addVetoableChangeListener( const rtl::OUString&, \ const uno::Reference<beans::XVetoableChangeListener>&) \ throw(beans::UnknownPropertyException, \ lang::WrappedTargetException, uno::RuntimeException) \ - { DBG_ERROR("not implemented"); } \ + { OSL_FAIL("not implemented"); } \ void SAL_CALL ClassName::removeVetoableChangeListener( const rtl::OUString&, \ const uno::Reference<beans::XVetoableChangeListener>&) \ throw(beans::UnknownPropertyException, \ lang::WrappedTargetException, uno::RuntimeException) \ - { DBG_ERROR("not implemented"); } + { OSL_FAIL("not implemented"); } #define SC_QUERYINTERFACE(x) \ diff --git a/sc/source/core/data/attarray.cxx b/sc/source/core/data/attarray.cxx index 39e441980..274464ceb 100644 --- a/sc/source/core/data/attarray.cxx +++ b/sc/source/core/data/attarray.cxx @@ -508,7 +508,7 @@ void ScAttrArray::ApplyStyleArea( SCROW nStartRow, SCROW nEndRow, ScStyleSheet* SCROW nStart=0; if (!Search( nStartRow, nPos )) { - DBG_ERROR("Search Failure"); + OSL_FAIL("Search Failure"); return; } @@ -603,7 +603,7 @@ void ScAttrArray::ApplyLineStyleArea( SCROW nStartRow, SCROW nEndRow, SCROW nStart=0; if (!Search( nStartRow, nPos )) { - DBG_ERROR("Search failure"); + OSL_FAIL("Search failure"); return; } @@ -733,7 +733,7 @@ void ScAttrArray::ApplyCacheArea( SCROW nStartRow, SCROW nEndRow, SfxItemPoolCac SCROW nStart=0; if (!Search( nStartRow, nPos )) { - DBG_ERROR("Search Failure"); + OSL_FAIL("Search Failure"); return; } @@ -872,7 +872,7 @@ void ScAttrArray::MergePatternArea( SCROW nStartRow, SCROW nEndRow, SCROW nStart=0; if (!Search( nStartRow, nPos )) { - DBG_ERROR("Search failure"); + OSL_FAIL("Search failure"); return; } diff --git a/sc/source/core/data/attrib.cxx b/sc/source/core/data/attrib.cxx index 3035f2c75..84f1a52b6 100644 --- a/sc/source/core/data/attrib.cxx +++ b/sc/source/core/data/attrib.cxx @@ -265,7 +265,7 @@ bool ScProtectionAttr::QueryValue( uno::Any& rVal, BYTE nMemberId ) const case MID_4 : rVal <<= (sal_Bool ) bHidePrint; break; default: - DBG_ERROR("Wrong MemberID!"); + OSL_FAIL("Wrong MemberID!"); return false; } @@ -292,7 +292,7 @@ bool ScProtectionAttr::PutValue( const uno::Any& rVal, BYTE nMemberId ) } else { - DBG_ERROR("exception - wrong argument"); + OSL_FAIL("exception - wrong argument"); } break; } @@ -305,7 +305,7 @@ bool ScProtectionAttr::PutValue( const uno::Any& rVal, BYTE nMemberId ) case MID_4 : bRet = (rVal >>= bVal); if (bRet) bHidePrint=bVal; break; default: - DBG_ERROR("Wrong MemberID!"); + OSL_FAIL("Wrong MemberID!"); } return bRet; @@ -714,7 +714,7 @@ bool ScPageHFItem::PutValue( const uno::Any& rVal, BYTE /* nMemberId */ ) if (!bRet) { - DBG_ERROR("exception - wrong argument"); + OSL_FAIL("exception - wrong argument"); } return true; @@ -924,7 +924,7 @@ void ScPageHFItem::SetArea( EditTextObject *pNew, int nArea ) case SC_HF_CENTERAREA: delete pCenterArea; pCenterArea = pNew; break; case SC_HF_RIGHTAREA: delete pRightArea; pRightArea = pNew; break; default: - DBG_ERROR( "New Area?" ); + OSL_FAIL( "New Area?" ); } } diff --git a/sc/source/core/data/cell.cxx b/sc/source/core/data/cell.cxx index 1f2fda4fa..0e9e9d616 100644 --- a/sc/source/core/data/cell.cxx +++ b/sc/source/core/data/cell.cxx @@ -127,7 +127,7 @@ ScBaseCell* lclCloneCell( const ScBaseCell& rSrcCell, ScDocument& rDestDoc, cons return new ScNoteCell; default:; } - DBG_ERROR( "lclCloneCell - unknown cell type" ); + OSL_FAIL( "lclCloneCell - unknown cell type" ); return 0; } @@ -181,7 +181,7 @@ void ScBaseCell::Delete() delete (ScNoteCell*) this; break; default: - DBG_ERROR("Unbekannter Zellentyp"); + OSL_FAIL("Unbekannter Zellentyp"); break; } } @@ -553,7 +553,7 @@ BOOL ScBaseCell::CellEqual( const ScBaseCell* pCell1, const ScBaseCell* pCell2 ) return FALSE; // unterschiedlich lang oder unterschiedliche Tokens } default: - DBG_ERROR("huch, was fuer Zellen???"); + OSL_FAIL("huch, was fuer Zellen???"); } return FALSE; } @@ -880,7 +880,7 @@ void ScFormulaCell::GetFormula( rtl::OUStringBuffer& rBuffer, } else { - DBG_ERROR("ScFormulaCell::GetFormula: not a matrix"); + OSL_FAIL("ScFormulaCell::GetFormula: not a matrix"); } } else diff --git a/sc/source/core/data/column.cxx b/sc/source/core/data/column.cxx index d47adbc42..9e13354af 100644 --- a/sc/source/core/data/column.cxx +++ b/sc/source/core/data/column.cxx @@ -570,7 +570,7 @@ const ScStyleSheet* ScColumn::GetSelectionStyle( const ScMarkData& rMark, bool& rFound = false; if (!rMark.IsMultiMarked()) { - DBG_ERROR("ScColumn::GetSelectionStyle ohne Selektion"); + OSL_FAIL("ScColumn::GetSelectionStyle ohne Selektion"); return NULL; } @@ -1279,7 +1279,7 @@ void ScColumn::CopyToColumn(SCROW nRow1, SCROW nRow2, sal_uInt16 nFlags, bool bM } else { - DBG_ERROR("CopyToColumn: bMarked, aber keine Markierung"); + OSL_FAIL("CopyToColumn: bMarked, aber keine Markierung"); } return; } diff --git a/sc/source/core/data/conditio.cxx b/sc/source/core/data/conditio.cxx index 6b1db6ed8..272090a97 100644 --- a/sc/source/core/data/conditio.cxx +++ b/sc/source/core/data/conditio.cxx @@ -852,7 +852,7 @@ BOOL ScConditionEntry::IsValid( double nArg, const ScAddress& rAddr ) const bValid = !::rtl::math::approxEqual( nComp1, 0.0 ); break; default: - DBG_ERROR("unbekannte Operation bei ScConditionEntry"); + OSL_FAIL("unbekannte Operation bei ScConditionEntry"); break; } return bValid; @@ -936,7 +936,7 @@ BOOL ScConditionEntry::IsValidStr( const String& rArg, const ScAddress& rAddr ) break; // SC_COND_DIRECT schon oben abgefragt default: - DBG_ERROR("unbekannte Operation bei ScConditionEntry"); + OSL_FAIL("unbekannte Operation bei ScConditionEntry"); bValid = FALSE; break; } @@ -1003,7 +1003,7 @@ String ScConditionEntry::GetExpression( const ScAddress& rCursor, USHORT nIndex, } else { - DBG_ERROR("GetExpression: falscher Index"); + OSL_FAIL("GetExpression: falscher Index"); } return aRet; @@ -1042,7 +1042,7 @@ ScTokenArray* ScConditionEntry::CreateTokenArry( USHORT nIndex ) const } else { - DBG_ERROR("GetExpression: falscher Index"); + OSL_FAIL("GetExpression: falscher Index"); } return pRet; @@ -1621,7 +1621,7 @@ ScConditionalFormat* ScConditionalFormatList::GetFormat( sal_uInt32 nKey ) if ((*this)[i]->GetKey() == nKey) return (*this)[i]; - DBG_ERROR("ScConditionalFormatList: Eintrag nicht gefunden"); + OSL_FAIL("ScConditionalFormatList: Eintrag nicht gefunden"); return NULL; } diff --git a/sc/source/core/data/dociter.cxx b/sc/source/core/data/dociter.cxx index bc1e5777e..af2564f69 100644 --- a/sc/source/core/data/dociter.cxx +++ b/sc/source/core/data/dociter.cxx @@ -947,7 +947,7 @@ ScCellIterator::ScCellIterator( ScDocument* pDocument, if (!pDoc->pTab[nTab]) { - DBG_ERROR("Tabelle nicht gefunden"); + OSL_FAIL("Tabelle nicht gefunden"); nStartCol = nCol = MAXCOL+1; nStartRow = nRow = MAXROW+1; nStartTab = nTab = MAXTAB+1; // -> Abbruch bei GetFirst @@ -989,7 +989,7 @@ ScCellIterator::ScCellIterator if (!pDoc->pTab[nTab]) { - DBG_ERROR("Tabelle nicht gefunden"); + OSL_FAIL("Tabelle nicht gefunden"); nStartCol = nCol = MAXCOL+1; nStartRow = nRow = MAXROW+1; nStartTab = nTab = MAXTAB+1; // -> Abbruch bei GetFirst @@ -1855,7 +1855,7 @@ const ScPatternAttr* ScHorizontalAttrIterator::GetNext( SCCOL& rCol1, SCCOL& rCo } else { - DBG_ERROR("AttrArray reicht nicht bis MAXROW"); + OSL_FAIL("AttrArray reicht nicht bis MAXROW"); pNextEnd[nPos] = MAXROW; ppPatterns[nPos] = NULL; } diff --git a/sc/source/core/data/docpool.cxx b/sc/source/core/data/docpool.cxx index 7100aac98..2d6506df2 100644 --- a/sc/source/core/data/docpool.cxx +++ b/sc/source/core/data/docpool.cxx @@ -621,7 +621,7 @@ void ScDocumentPool::Remove( const SfxPoolItem& rItem ) { if ( nRef != (ULONG) SC_SAFE_POOLREF ) { - DBG_ERROR("Wer fummelt da an meinen Ref-Counts herum"); + OSL_FAIL("Wer fummelt da an meinen Ref-Counts herum"); SetRefCount( (SfxPoolItem&)rItem, (ULONG) SC_SAFE_POOLREF ); } return; // nicht herunterzaehlen diff --git a/sc/source/core/data/documen2.cxx b/sc/source/core/data/documen2.cxx index 23998d0c1..5474a1aca 100644 --- a/sc/source/core/data/documen2.cxx +++ b/sc/source/core/data/documen2.cxx @@ -575,7 +575,7 @@ void ScDocument::ResetClip( ScDocument* pSourceDoc, const ScMarkData* pMarks ) } else { - DBG_ERROR("ResetClip"); + OSL_FAIL("ResetClip"); } } @@ -593,7 +593,7 @@ void ScDocument::ResetClip( ScDocument* pSourceDoc, SCTAB nTab ) } else { - DBG_ERROR("ResetClip"); + OSL_FAIL("ResetClip"); } } @@ -1005,7 +1005,7 @@ ULONG ScDocument::TransferTab( ScDocument* pSrcDoc, SCTAB nSrcPos, pData->SetIndex(0); // need new index, done in Insert if (!pRangeName->Insert(pData)) { - DBG_ERROR("can't insert name"); // shouldn't happen + OSL_FAIL("can't insert name"); // shouldn't happen delete pData; } else diff --git a/sc/source/core/data/documen3.cxx b/sc/source/core/data/documen3.cxx index 1d678f4c4..778d91ac8 100644 --- a/sc/source/core/data/documen3.cxx +++ b/sc/source/core/data/documen3.cxx @@ -708,7 +708,7 @@ BOOL ScDocument::TestCopyScenario( SCTAB nSrcTab, SCTAB nDestTab ) const if (ValidTab(nSrcTab) && ValidTab(nDestTab)) return pTab[nSrcTab]->TestCopyScenarioTo( pTab[nDestTab] ); - DBG_ERROR("falsche Tabelle bei TestCopyScenario"); + OSL_FAIL("falsche Tabelle bei TestCopyScenario"); return FALSE; } @@ -760,7 +760,7 @@ void ScDocument::RemoveUnoObject( SfxListener& rObject ) } else { - DBG_ERROR("No Uno broadcaster"); + OSL_FAIL("No Uno broadcaster"); } } @@ -1179,7 +1179,7 @@ BOOL ScDocument::UpdateOutlineCol( SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab, B if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->UpdateOutlineCol( nStartCol, nEndCol, bShow ); - DBG_ERROR("missing tab"); + OSL_FAIL("missing tab"); return FALSE; } @@ -1188,7 +1188,7 @@ BOOL ScDocument::UpdateOutlineRow( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, B if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->UpdateOutlineRow( nStartRow, nEndRow, bShow ); - DBG_ERROR("missing tab"); + OSL_FAIL("missing tab"); return FALSE; } @@ -1208,7 +1208,7 @@ SCSIZE ScDocument::Query(SCTAB nTab, const ScQueryParam& rQueryParam, BOOL bKeep if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->Query((ScQueryParam&)rQueryParam, bKeepSub); - DBG_ERROR("missing tab"); + OSL_FAIL("missing tab"); return 0; } @@ -1226,7 +1226,7 @@ BOOL ScDocument::CreateQueryParam(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW n if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->CreateQueryParam(nCol1, nRow1, nCol2, nRow2, rQueryParam); - DBG_ERROR("missing tab"); + OSL_FAIL("missing tab"); return FALSE; } @@ -1482,7 +1482,7 @@ Rectangle ScDocument::GetEmbeddedRect() const // 1/100 mm ScTable* pTable = pTab[aEmbedRange.aStart.Tab()]; if (!pTable) { - DBG_ERROR("GetEmbeddedRect ohne Tabelle"); + OSL_FAIL("GetEmbeddedRect ohne Tabelle"); } else { @@ -1570,7 +1570,7 @@ ScRange ScDocument::GetRange( SCTAB nTab, const Rectangle& rMMRect ) const ScTable* pTable = pTab[nTab]; if (!pTable) { - DBG_ERROR("GetRange ohne Tabelle"); + OSL_FAIL("GetRange ohne Tabelle"); return ScRange(); } @@ -1704,7 +1704,7 @@ void ScDocument::SnapVisArea( Rectangle& rRect ) const ScTable* pTable = pTab[nVisibleTab]; if (!pTable) { - DBG_ERROR("SetEmbedded ohne Tabelle"); + OSL_FAIL("SetEmbedded ohne Tabelle"); return; } @@ -1755,7 +1755,7 @@ BOOL ScDocument::IsTabProtected( SCTAB nTab ) const if (VALIDTAB(nTab) && pTab[nTab]) return pTab[nTab]->IsProtected(); - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); return FALSE; } @@ -1869,7 +1869,7 @@ Rectangle ScDocument::GetMMRect( SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol { if (!ValidTab(nTab) || !pTab[nTab]) { - DBG_ERROR("GetMMRect: falsche Tabelle"); + OSL_FAIL("GetMMRect: falsche Tabelle"); return Rectangle(0,0,0,0); } diff --git a/sc/source/core/data/documen4.cxx b/sc/source/core/data/documen4.cxx index d6e16a974..1c4c8e153 100644 --- a/sc/source/core/data/documen4.cxx +++ b/sc/source/core/data/documen4.cxx @@ -147,7 +147,7 @@ void ScDocument::InsertMatrixFormula(SCCOL nCol1, SCROW nRow1, if (i == MAXTAB + 1) { Sound::Beep(); - DBG_ERROR("ScDocument::InsertMatrixFormula Keine Tabelle markiert"); + OSL_FAIL("ScDocument::InsertMatrixFormula Keine Tabelle markiert"); return; } @@ -234,7 +234,7 @@ void ScDocument::InsertTableOp(const ScTabOpParam& rParam, // Mehrfachopera if (i == MAXTAB + 1) { Sound::Beep(); - DBG_ERROR("ScDocument::InsertTableOp: Keine Tabelle markiert"); + OSL_FAIL("ScDocument::InsertTableOp: Keine Tabelle markiert"); return; } @@ -408,7 +408,7 @@ void ScDocument::DoColResize( SCTAB nTab, SCCOL nCol1, SCCOL nCol2, SCSIZE nAdd pTab[nTab]->DoColResize( nCol1, nCol2, nAdd ); else { - DBG_ERROR("DoColResize: falsche Tabelle"); + OSL_FAIL("DoColResize: falsche Tabelle"); } } @@ -634,7 +634,7 @@ const SfxPoolItem* ScDocument::GetEffItem( } return &rSet.Get( nWhich ); } - DBG_ERROR("kein Pattern"); + OSL_FAIL("kein Pattern"); return NULL; } @@ -666,7 +666,7 @@ const ScConditionalFormat* ScDocument::GetCondFormat( return pCondFormList->GetFormat( nIndex ); else { - DBG_ERROR("pCondFormList ist 0"); + OSL_FAIL("pCondFormList ist 0"); } } diff --git a/sc/source/core/data/documen8.cxx b/sc/source/core/data/documen8.cxx index 60eaeb601..ee92c4114 100644 --- a/sc/source/core/data/documen8.cxx +++ b/sc/source/core/data/documen8.cxx @@ -575,7 +575,7 @@ BOOL ScDocument::IdleCalcTextWidth() // TRUE = demnaechst wieder versuchen } else { - DBG_ERROR( "Missing StyleSheet :-/" ); + OSL_FAIL( "Missing StyleSheet :-/" ); } } diff --git a/sc/source/core/data/document.cxx b/sc/source/core/data/document.cxx index 6f1d1dc22..403dfdda5 100644 --- a/sc/source/core/data/document.cxx +++ b/sc/source/core/data/document.cxx @@ -778,7 +778,7 @@ void ScDocument::LimitChartIfAll( ScRangeListRef& rRangeList ) } else { - DBG_ERROR("LimitChartIfAll: Ref==0"); + OSL_FAIL("LimitChartIfAll: Ref==0"); } rRangeList = aNew; } @@ -1415,7 +1415,7 @@ void ScDocument::InitUndoSelected( ScDocument* pSrcDoc, const ScMarkData& rTabSe } else { - DBG_ERROR("InitUndo"); + OSL_FAIL("InitUndo"); } } @@ -1437,7 +1437,7 @@ void ScDocument::InitUndo( ScDocument* pSrcDoc, SCTAB nTab1, SCTAB nTab2, } else { - DBG_ERROR("InitUndo"); + OSL_FAIL("InitUndo"); } } @@ -1456,7 +1456,7 @@ void ScDocument::AddUndoTab( SCTAB nTab1, SCTAB nTab2, BOOL bColInfo, BOOL bRowI } else { - DBG_ERROR("InitUndo"); + OSL_FAIL("InitUndo"); } } @@ -1467,7 +1467,7 @@ void ScDocument::SetCutMode( BOOL bVal ) GetClipParam().mbCutMode = bVal; else { - DBG_ERROR("SetCutMode without bIsClip"); + OSL_FAIL("SetCutMode without bIsClip"); } } @@ -1478,7 +1478,7 @@ BOOL ScDocument::IsCutMode() return GetClipParam().mbCutMode; else { - DBG_ERROR("IsCutMode ohne bIsClip"); + OSL_FAIL("IsCutMode ohne bIsClip"); return FALSE; } } @@ -2141,7 +2141,7 @@ void ScDocument::CopyFromClip( const ScRange& rDestRange, const ScMarkData& rMar { if (!pClipDoc) { - DBG_ERROR("CopyFromClip: no ClipDoc"); + OSL_FAIL("CopyFromClip: no ClipDoc"); pClipDoc = SC_MOD()->GetClipDoc(); } if (pClipDoc->bIsClip && pClipDoc->GetTableCount()) @@ -2472,7 +2472,7 @@ void ScDocument::SetClipArea( const ScRange& rArea, BOOL bCut ) } else { - DBG_ERROR("SetClipArea: kein Clip"); + OSL_FAIL("SetClipArea: kein Clip"); } } @@ -2481,7 +2481,7 @@ void ScDocument::GetClipArea(SCCOL& nClipX, SCROW& nClipY, BOOL bIncludeFiltered { if (!bIsClip) { - DBG_ERROR("GetClipArea: kein Clip"); + OSL_FAIL("GetClipArea: kein Clip"); return; } @@ -2543,7 +2543,7 @@ void ScDocument::GetClipStart(SCCOL& nClipX, SCROW& nClipY) } else { - DBG_ERROR("GetClipStart: kein Clip"); + OSL_FAIL("GetClipStart: kein Clip"); } } @@ -2636,7 +2636,7 @@ void ScDocument::FillTab( const ScRange& rSrcArea, const ScMarkData& rMark, } else { - DBG_ERROR("falsche Tabelle"); + OSL_FAIL("falsche Tabelle"); } } @@ -2695,7 +2695,7 @@ void ScDocument::FillTabMarked( SCTAB nSrcTab, const ScMarkData& rMark, } else { - DBG_ERROR("falsche Tabelle"); + OSL_FAIL("falsche Tabelle"); } } @@ -2896,7 +2896,7 @@ void ScDocument::GetCell( SCCOL nCol, SCROW nRow, SCTAB nTab, rpCell = pTab[nTab]->GetCell( nCol, nRow ); else { - DBG_ERROR("GetCell ohne Tabelle"); + OSL_FAIL("GetCell ohne Tabelle"); rpCell = NULL; } } @@ -2908,7 +2908,7 @@ ScBaseCell* ScDocument::GetCell( const ScAddress& rPos ) const if (ValidTab(nTab) && pTab[nTab]) return pTab[nTab]->GetCell( rPos ); - DBG_ERROR("GetCell ohne Tabelle"); + OSL_FAIL("GetCell ohne Tabelle"); return NULL; } @@ -3251,7 +3251,7 @@ USHORT ScDocument::GetColWidth( SCCOL nCol, SCTAB nTab ) const { if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetColWidth( nCol ); - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); return 0; } @@ -3260,7 +3260,7 @@ USHORT ScDocument::GetOriginalWidth( SCCOL nCol, SCTAB nTab ) const { if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetOriginalWidth( nCol ); - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); return 0; } @@ -3269,7 +3269,7 @@ USHORT ScDocument::GetCommonWidth( SCCOL nEndCol, SCTAB nTab ) const { if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetCommonWidth( nEndCol ); - DBG_ERROR("Wrong table number"); + OSL_FAIL("Wrong table number"); return 0; } @@ -3278,7 +3278,7 @@ USHORT ScDocument::GetOriginalHeight( SCROW nRow, SCTAB nTab ) const { if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetOriginalHeight( nRow ); - DBG_ERROR("Wrong table number"); + OSL_FAIL("Wrong table number"); return 0; } @@ -3287,7 +3287,7 @@ USHORT ScDocument::GetRowHeight( SCROW nRow, SCTAB nTab, bool bHiddenAsZero ) co { if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetRowHeight( nRow, NULL, NULL, bHiddenAsZero ); - DBG_ERROR("Wrong sheet number"); + OSL_FAIL("Wrong sheet number"); return 0; } @@ -3296,7 +3296,7 @@ USHORT ScDocument::GetRowHeight( SCROW nRow, SCTAB nTab, SCROW* pStartRow, SCROW { if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetRowHeight( nRow, pStartRow, pEndRow, bHiddenAsZero ); - DBG_ERROR("Wrong sheet number"); + OSL_FAIL("Wrong sheet number"); return 0; } @@ -3313,7 +3313,7 @@ ULONG ScDocument::GetRowHeight( SCROW nStartRow, SCROW nEndRow, SCTAB nTab ) con if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetRowHeight( nStartRow, nEndRow); - DBG_ERROR("wrong sheet number"); + OSL_FAIL("wrong sheet number"); return 0; } @@ -3336,7 +3336,7 @@ ULONG ScDocument::GetScaledRowHeight( SCROW nStartRow, SCROW nEndRow, if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetScaledRowHeight( nStartRow, nEndRow, fScale); - DBG_ERROR("wrong sheet number"); + OSL_FAIL("wrong sheet number"); return 0; } @@ -3344,7 +3344,7 @@ SCROW ScDocument::GetHiddenRowCount( SCROW nRow, SCTAB nTab ) const { if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetHiddenRowCount( nRow ); - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); return 0; } @@ -3353,7 +3353,7 @@ ULONG ScDocument::GetColOffset( SCCOL nCol, SCTAB nTab ) const { if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetColOffset( nCol ); - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); return 0; } @@ -3362,7 +3362,7 @@ ULONG ScDocument::GetRowOffset( SCROW nRow, SCTAB nTab ) const { if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetRowOffset( nRow ); - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); return 0; } @@ -3376,7 +3376,7 @@ USHORT ScDocument::GetOptimalColWidth( SCCOL nCol, SCTAB nTab, OutputDevice* pDe if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetOptimalColWidth( nCol, pDev, nPPTX, nPPTY, rZoomX, rZoomY, bFormula, pMarkData, pParam ); - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); return 0; } @@ -3390,7 +3390,7 @@ long ScDocument::GetNeededSize( SCCOL nCol, SCROW nRow, SCTAB nTab, if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetNeededSize ( nCol, nRow, pDev, nPPTX, nPPTY, rZoomX, rZoomY, bWidth, bTotalSize ); - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); return 0; } @@ -3405,7 +3405,7 @@ BOOL ScDocument::SetOptimalHeight( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, U if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->SetOptimalHeight( nStartRow, nEndRow, nExtra, pDev, nPPTX, nPPTY, rZoomX, rZoomY, bShrink ); - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); return FALSE; } @@ -3477,7 +3477,7 @@ BYTE ScDocument::GetColFlags( SCCOL nCol, SCTAB nTab ) const { if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetColFlags( nCol ); - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); return 0; } @@ -3485,7 +3485,7 @@ BYTE ScDocument::GetRowFlags( SCROW nRow, SCTAB nTab ) const { if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetRowFlags( nRow ); - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); return 0; } @@ -3504,12 +3504,12 @@ const ScBitMaskCompressedArray< SCROW, BYTE> & ScDocument::GetRowFlagsArray( pFlags = pTab[nTab]->GetRowFlagsArray(); else { - DBG_ERROR("wrong sheet number"); + OSL_FAIL("wrong sheet number"); pFlags = 0; } if (!pFlags) { - DBG_ERROR("no row flags at sheet"); + OSL_FAIL("no row flags at sheet"); static ScBitMaskCompressedArray< SCROW, BYTE> aDummy( MAXROW, 0); pFlags = &aDummy; } @@ -3908,7 +3908,7 @@ const SfxPoolItem* ScDocument::GetAttr( SCCOL nCol, SCROW nRow, SCTAB nTab, USHO return pTemp; else { - DBG_ERROR( "Attribut Null" ); + OSL_FAIL( "Attribut Null" ); } } return &xPoolHelper->GetDocPool()->GetDefaultItem( nWhich ); @@ -4164,7 +4164,7 @@ BOOL ScDocument::ApplyFlagsTab( SCCOL nStartCol, SCROW nStartRow, if (pTab[nTab]) return pTab[nTab]->ApplyFlags( nStartCol, nStartRow, nEndCol, nEndRow, nFlags ); - DBG_ERROR("ApplyFlags: falsche Tabelle"); + OSL_FAIL("ApplyFlags: falsche Tabelle"); return FALSE; } @@ -4176,7 +4176,7 @@ BOOL ScDocument::RemoveFlagsTab( SCCOL nStartCol, SCROW nStartRow, if (pTab[nTab]) return pTab[nTab]->RemoveFlags( nStartCol, nStartRow, nEndCol, nEndRow, nFlags ); - DBG_ERROR("RemoveFlags: falsche Tabelle"); + OSL_FAIL("RemoveFlags: falsche Tabelle"); return FALSE; } @@ -4438,7 +4438,7 @@ BOOL ScDocument::IsBlockEmpty( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, if (pTab[nTab]) return pTab[nTab]->IsBlockEmpty( nStartCol, nStartRow, nEndCol, nEndRow, bIgnoreNotes ); - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); return FALSE; } @@ -4449,7 +4449,7 @@ void ScDocument::LockTable(SCTAB nTab) pTab[nTab]->LockTable(); else { - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); } } @@ -4460,7 +4460,7 @@ void ScDocument::UnlockTable(SCTAB nTab) pTab[nTab]->UnlockTable(); else { - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); } } @@ -4482,7 +4482,7 @@ BOOL ScDocument::IsBlockEditable( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, return pTab[nTab]->IsBlockEditable( nStartCol, nStartRow, nEndCol, nEndRow, pOnlyNotBecauseOfMatrix ); - DBG_ERROR("Falsche Tabellennummer"); + OSL_FAIL("Falsche Tabellennummer"); if ( pOnlyNotBecauseOfMatrix ) *pOnlyNotBecauseOfMatrix = FALSE; return FALSE; @@ -4656,7 +4656,7 @@ BOOL ScDocument::ExtendOverlapped( SCCOL& rStartCol, SCROW& rStartRow, } else { - DBG_ERROR("ExtendOverlapped: falscher Bereich"); + OSL_FAIL("ExtendOverlapped: falscher Bereich"); } return bFound; @@ -4705,7 +4705,7 @@ BOOL ScDocument::ExtendMerge( SCCOL nStartCol, SCROW nStartRow, } else { - DBG_ERROR("ExtendMerge: falscher Bereich"); + OSL_FAIL("ExtendMerge: falscher Bereich"); } return bFound; @@ -4856,7 +4856,7 @@ BOOL ScDocument::IsHorOverlapped( SCCOL nCol, SCROW nRow, SCTAB nTab ) const return pAttr->IsHorOverlapped(); else { - DBG_ERROR("Overlapped: Attr==0"); + OSL_FAIL("Overlapped: Attr==0"); return FALSE; } } @@ -4870,7 +4870,7 @@ BOOL ScDocument::IsVerOverlapped( SCCOL nCol, SCROW nRow, SCTAB nTab ) const return pAttr->IsVerOverlapped(); else { - DBG_ERROR("Overlapped: Attr==0"); + OSL_FAIL("Overlapped: Attr==0"); return FALSE; } } @@ -4974,7 +4974,7 @@ void ScDocument::DeleteSelectionTab( SCTAB nTab, USHORT nDelFlag, const ScMarkDa pTab[nTab]->DeleteSelection( nDelFlag, rMark ); else { - DBG_ERROR("Falsche Tabelle"); + OSL_FAIL("Falsche Tabelle"); } } @@ -5142,7 +5142,7 @@ Size ScDocument::GetPageSize( SCTAB nTab ) const if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->GetPageSize(); - DBG_ERROR("falsche Tab"); + OSL_FAIL("falsche Tab"); return Size(); } @@ -5176,7 +5176,7 @@ BOOL ScDocument::HasManualBreaks( SCTAB nTab ) const if ( ValidTab(nTab) && pTab[nTab] ) return pTab[nTab]->HasManualBreaks(); - DBG_ERROR("falsche Tab"); + OSL_FAIL("falsche Tab"); return FALSE; } diff --git a/sc/source/core/data/dpdimsave.cxx b/sc/source/core/data/dpdimsave.cxx index 20d342f99..ce204177f 100644 --- a/sc/source/core/data/dpdimsave.cxx +++ b/sc/source/core/data/dpdimsave.cxx @@ -187,7 +187,7 @@ String ScDPSaveGroupDimension::CreateGroupName( const String& rPrefix ) ++nAdd; // continue with higher number } - DBG_ERROR("CreateGroupName: no valid name found"); + OSL_FAIL("CreateGroupName: no valid name found"); return EMPTY_STRING; } @@ -558,7 +558,7 @@ String ScDPDimensionSaveData::CreateGroupDimName( const String& rSourceName, else ++nAdd; // continue with higher number } - DBG_ERROR("CreateGroupDimName: no valid name found"); + OSL_FAIL("CreateGroupDimName: no valid name found"); return EMPTY_STRING; } diff --git a/sc/source/core/data/dpgroup.cxx b/sc/source/core/data/dpgroup.cxx index 4a514b43c..30eab7c1f 100644 --- a/sc/source/core/data/dpgroup.cxx +++ b/sc/source/core/data/dpgroup.cxx @@ -354,7 +354,7 @@ bool ScDPGroupDateFilter::match( const ScDPItemData & rCellData ) const return sec == matchSec; } default: - DBG_ERROR("invalid time part"); + OSL_FAIL("invalid time part"); } return false; } @@ -393,7 +393,7 @@ bool ScDPGroupDateFilter::match( const ScDPItemData & rCellData ) const return days == matchDays; } default: - DBG_ERROR("invalid date part"); + OSL_FAIL("invalid date part"); } return false; @@ -457,7 +457,7 @@ String lcl_GetDateGroupName( sal_Int32 nDatePart, sal_Int32 nValue, SvNumberForm aRet.Append( lcl_GetTwoDigitString( nValue ) ); break; default: - DBG_ERROR("invalid date part"); + OSL_FAIL("invalid date part"); } return aRet; } @@ -527,7 +527,7 @@ sal_Int32 lcl_GetDatePartValue( double fValue, sal_Int32 nDatePart, SvNumberForm } break; default: - DBG_ERROR("invalid date part"); + OSL_FAIL("invalid date part"); } } @@ -661,7 +661,7 @@ void ScDPDateGroupHelper::FillColumnEntries( case com::sun::star::sheet::DataPilotFieldGroupBy::MINUTES: nStart = 0; nEnd = 59; break; case com::sun::star::sheet::DataPilotFieldGroupBy::SECONDS: nStart = 0; nEnd = 59; break; default: - DBG_ERROR("invalid date part"); + OSL_FAIL("invalid date part"); } for ( sal_Int32 nValue = nStart; nValue <= nEnd; nValue++ ) @@ -1461,7 +1461,7 @@ BOOL ScDPGroupTableData::IsInGroup( const ScDPItemData& rGroupData, long nGroupI // date group information, too. if ( !pBaseDateHelper ) { - DBG_ERROR( "mix of date and non-date groups" ); + OSL_FAIL( "mix of date and non-date groups" ); return TRUE; } @@ -1481,7 +1481,7 @@ BOOL ScDPGroupTableData::IsInGroup( const ScDPItemData& rGroupData, long nGroupI } } - DBG_ERROR("IsInGroup: no group dimension found"); + OSL_FAIL("IsInGroup: no group dimension found"); return TRUE; } @@ -1507,7 +1507,7 @@ BOOL ScDPGroupTableData::HasCommonElement( const ScDPItemData& rFirstData, long // If one is a date group dimension, the other one must be, too. if ( !pFirstDateHelper || !pSecondDateHelper ) { - DBG_ERROR( "mix of date and non-date groups" ); + OSL_FAIL( "mix of date and non-date groups" ); return TRUE; } @@ -1540,7 +1540,7 @@ BOOL ScDPGroupTableData::HasCommonElement( const ScDPItemData& rFirstData, long } } - DBG_ERROR("HasCommonElement: no group dimension found"); + OSL_FAIL("HasCommonElement: no group dimension found"); return TRUE; } diff --git a/sc/source/core/data/dpobject.cxx b/sc/source/core/data/dpobject.cxx index b0414f7e9..12311008d 100644 --- a/sc/source/core/data/dpobject.cxx +++ b/sc/source/core/data/dpobject.cxx @@ -414,7 +414,7 @@ ScDPTableData* ScDPObject::GetTableData() // cell data if (!pSheetDesc) { - DBG_ERROR("no source descriptor"); + OSL_FAIL("no source descriptor"); pSheetDesc = new ScSheetSourceDesc(pDoc); // dummy defaults } pData.reset(new ScSheetDPData(pDoc, *pSheetDesc)); @@ -477,7 +477,7 @@ void ScDPObject::CreateObjects() } catch(uno::Exception&) { - DBG_ERROR("exception in refresh"); + OSL_FAIL("exception in refresh"); } } @@ -728,7 +728,7 @@ BOOL ScDPObject::RefsEqual( const ScDPObject& r ) const } else if ( pSheetDesc || r.pSheetDesc ) { - DBG_ERROR("RefsEqual: SheetDesc set at only one object"); + OSL_FAIL("RefsEqual: SheetDesc set at only one object"); return FALSE; } @@ -1653,7 +1653,7 @@ USHORT lcl_FirstSubTotal( const uno::Reference<beans::XPropertySet>& xDimProp ) } } - DBG_ERROR("FirstSubTotal: NULL"); + OSL_FAIL("FirstSubTotal: NULL"); return 0; } diff --git a/sc/source/core/data/dpoutput.cxx b/sc/source/core/data/dpoutput.cxx index 1a39b91e0..f41f4c260 100644 --- a/sc/source/core/data/dpoutput.cxx +++ b/sc/source/core/data/dpoutput.cxx @@ -129,7 +129,7 @@ void lcl_SetStyleById( ScDocument* pDoc, SCTAB nTab, { if ( nCol1 > nCol2 || nRow1 > nRow2 ) { - DBG_ERROR("SetStyleById: invalid range"); + OSL_FAIL("SetStyleById: invalid range"); return; } diff --git a/sc/source/core/data/dpsave.cxx b/sc/source/core/data/dpsave.cxx index 1de322da3..df7c9b9b6 100644 --- a/sc/source/core/data/dpsave.cxx +++ b/sc/source/core/data/dpsave.cxx @@ -1154,7 +1154,7 @@ void ScDPSaveData::WriteToSource( const uno::Reference<sheet::XDimensionsSupplie } catch(uno::Exception&) { - DBG_ERROR("exception in WriteToSource"); + OSL_FAIL("exception in WriteToSource"); } } @@ -1294,7 +1294,7 @@ void ScDPSaveData::Refresh( const uno::Reference<sheet::XDimensionsSupplier>& xS } catch(uno::Exception&) { - DBG_ERROR("error in ScDPSaveData::Refresh"); + OSL_FAIL("error in ScDPSaveData::Refresh"); } } diff --git a/sc/source/core/data/dpsdbtab.cxx b/sc/source/core/data/dpsdbtab.cxx index fbe6fe425..05888560b 100644 --- a/sc/source/core/data/dpsdbtab.cxx +++ b/sc/source/core/data/dpsdbtab.cxx @@ -147,7 +147,7 @@ ScDPCache* ScImportSourceDesc::CreateCache() const { delete pCache; pCache = NULL; - DBG_ERROR("Unexpected exception in database"); + OSL_FAIL("Unexpected exception in database"); } diff --git a/sc/source/core/data/dpshttab.cxx b/sc/source/core/data/dpshttab.cxx index 797d5a5cb..9f7e4846b 100644 --- a/sc/source/core/data/dpshttab.cxx +++ b/sc/source/core/data/dpshttab.cxx @@ -121,7 +121,7 @@ String ScSheetDPData::getDimensionName(long nColumn) } else if (nColumn >= aCacheTable.getColSize()) { - DBG_ERROR("getDimensionName: invalid dimension"); + OSL_FAIL("getDimensionName: invalid dimension"); return String(); } else @@ -140,7 +140,7 @@ BOOL ScSheetDPData::IsDateDimension(long nDim) } else if (nDim >= nColCount) { - DBG_ERROR("IsDateDimension: invalid dimension"); + OSL_FAIL("IsDateDimension: invalid dimension"); return FALSE; } else @@ -158,7 +158,7 @@ ULONG ScSheetDPData::GetNumberFormat(long nDim) } else if (nDim >= GetCacheTable().getColSize()) { - DBG_ERROR("GetNumberFormat: invalid dimension"); + OSL_FAIL("GetNumberFormat: invalid dimension"); return 0; } else @@ -316,7 +316,7 @@ ScDPCache* ScSheetSourceDesc::CreateCache() const ULONG nErrId = CheckSourceRange(); if (nErrId) { - DBG_ERROR( "Error Create Cache\n" ); + OSL_FAIL( "Error Create Cache\n" ); return NULL; } diff --git a/sc/source/core/data/dptabdat.cxx b/sc/source/core/data/dptabdat.cxx index a1bd3c3cf..e59c501fa 100644 --- a/sc/source/core/data/dptabdat.cxx +++ b/sc/source/core/data/dptabdat.cxx @@ -93,7 +93,7 @@ long ScDPTableData::GetDatePart( long nDateVal, long nHierarchy, long nLevel ) case 2: nRet = aDate.GetMonth(); break; case 3: nRet = aDate.GetDay(); break; default: - DBG_ERROR("GetDatePart: wrong level"); + OSL_FAIL("GetDatePart: wrong level"); } break; case SC_DAPI_HIERARCHY_WEEK: @@ -104,11 +104,11 @@ long ScDPTableData::GetDatePart( long nDateVal, long nHierarchy, long nLevel ) case 1: nRet = aDate.GetWeekOfYear(); break; case 2: nRet = (long)aDate.GetDayOfWeek(); break; default: - DBG_ERROR("GetDatePart: wrong level"); + OSL_FAIL("GetDatePart: wrong level"); } break; default: - DBG_ERROR("GetDatePart: wrong hierarchy"); + OSL_FAIL("GetDatePart: wrong hierarchy"); } nLastDateVal = nDateVal; @@ -147,14 +147,14 @@ BOOL ScDPTableData::IsNumOrDateGroup(long) const BOOL ScDPTableData::IsInGroup( const ScDPItemData&, long, const ScDPItemData&, long ) const { - DBG_ERROR("IsInGroup shouldn't be called for non-group data"); + OSL_FAIL("IsInGroup shouldn't be called for non-group data"); return FALSE; } BOOL ScDPTableData::HasCommonElement( const ScDPItemData&, long, const ScDPItemData&, long ) const { - DBG_ERROR("HasCommonElement shouldn't be called for non-group data"); + OSL_FAIL("HasCommonElement shouldn't be called for non-group data"); return FALSE; } void ScDPTableData::FillRowDataFromCacheTable(sal_Int32 nRow, const ScDPCacheTable& rCacheTable, diff --git a/sc/source/core/data/dptabres.cxx b/sc/source/core/data/dptabres.cxx index 560237b27..a1e1095ca 100644 --- a/sc/source/core/data/dptabres.cxx +++ b/sc/source/core/data/dptabres.cxx @@ -482,7 +482,7 @@ void ScDPAggData::Update( const ScDPValueData& rNext, ScSubTotalFunc eFunc, cons } break; default: - DBG_ERROR("invalid function"); + OSL_FAIL("invalid function"); } } @@ -530,7 +530,7 @@ void ScDPAggData::Calculate( ScSubTotalFunc eFunc, const ScDPSubTotalState& rSub break; default: - DBG_ERROR("invalid function"); + OSL_FAIL("invalid function"); } // calculate the selected function @@ -577,7 +577,7 @@ void ScDPAggData::Calculate( ScSubTotalFunc eFunc, const ScDPSubTotalState& rSub fResult = (fAux - fVal*fVal/(double)(nCount)) / (double)nCount; break; default: - DBG_ERROR("invalid function"); + OSL_FAIL("invalid function"); } } @@ -907,7 +907,7 @@ String ScDPResultData::GetMeasureDimensionName(long nMeasure) const { if ( nMeasure < 0 ) { - DBG_ERROR("GetMeasureDimensionName: negative"); + OSL_FAIL("GetMeasureDimensionName: negative"); return String::CreateFromAscii(RTL_CONSTASCII_STRINGPARAM("***")); } @@ -2516,7 +2516,7 @@ void ScDPDataMember::UpdateRunningTotals( const ScDPResultMember* pRefMember, fThisResult = ( fThisResult - fOtherResult ) / fOtherResult; break; default: - DBG_ERROR("invalid calculation type"); + OSL_FAIL("invalid calculation type"); } if ( bError ) { @@ -2750,7 +2750,7 @@ ScDPResultMember *ScDPResultDimension::FindMember( SCROW iData ) const if( aRes != maMemberHash.end()) { if ( aRes->second->IsNamedItem( iData ) ) return aRes->second; - DBG_ERROR("problem! hash result is not the same as IsNamedItem"); + OSL_FAIL("problem! hash result is not the same as IsNamedItem"); } unsigned int i; @@ -3010,7 +3010,7 @@ void ScDPResultDimension::ProcessData( const vector< SCROW >& aMembers, return; } - DBG_ERROR("ProcessData: Member not found"); + OSL_FAIL("ProcessData: Member not found"); } void ScDPResultDimension::FillMemberResults( uno::Sequence<sheet::MemberResult>* pSequences, @@ -3560,7 +3560,7 @@ void ScDPDataDimension::ProcessData( const vector< SCROW >& aDataMembers, const } } - DBG_ERROR("ProcessData: Member not found"); + OSL_FAIL("ProcessData: Member not found"); } void ScDPDataDimension::FillDataRow( const ScDPResultDimension* pRefDim, diff --git a/sc/source/core/data/dptabsrc.cxx b/sc/source/core/data/dptabsrc.cxx index 7d35c5661..d1fd8c0db 100644 --- a/sc/source/core/data/dptabsrc.cxx +++ b/sc/source/core/data/dptabsrc.cxx @@ -298,7 +298,7 @@ void ScDPSource::SetOrientation(long nColumn, USHORT nNew) case sheet::DataPilotFieldOrientation_HIDDEN: break; default: - DBG_ERROR( "ScDPSource::SetOrientation: unexpected orientation" ); + OSL_FAIL( "ScDPSource::SetOrientation: unexpected orientation" ); break; } } @@ -378,7 +378,7 @@ long ScDPSource::GetSourceDim(long nDim) } } - DBG_ERROR("GetSourceDim: wrong dim"); + OSL_FAIL("GetSourceDim: wrong dim"); return nDim; } @@ -422,13 +422,13 @@ void SAL_CALL ScDPSource::refresh() throw(uno::RuntimeException) void SAL_CALL ScDPSource::addRefreshListener( const uno::Reference<util::XRefreshListener >& ) throw(uno::RuntimeException) { - DBG_ERROR("not implemented"); //! exception? + OSL_FAIL("not implemented"); //! exception? } void SAL_CALL ScDPSource::removeRefreshListener( const uno::Reference<util::XRefreshListener >& ) throw(uno::RuntimeException) { - DBG_ERROR("not implemented"); //! exception? + OSL_FAIL("not implemented"); //! exception? } Sequence< Sequence<Any> > SAL_CALL ScDPSource::getDrillDownData(const Sequence<sheet::DataPilotFieldFilter>& aFilters) @@ -594,7 +594,7 @@ long lcl_CountMinMembers(const vector<ScDPDimension*>& ppDim, const vector<ScDPL if ( nPos+1 < nLevels && ppDim[nPos] == ppDim[nPos+1] ) { - DBG_ERROR("lcl_CountMinMembers: multiple levels from one dimension not implemented"); + OSL_FAIL("lcl_CountMinMembers: multiple levels from one dimension not implemented"); return 0; } @@ -1023,12 +1023,12 @@ void ScDPSource::FillLevelList( USHORT nOrientation, std::vector<ScDPLevel*> &rL nDimCount = nPageDimCount; break; default: - DBG_ERROR( "ScDPSource::FillLevelList: unexpected orientation" ); + OSL_FAIL( "ScDPSource::FillLevelList: unexpected orientation" ); break; } if (!pDimIndex) { - DBG_ERROR("invalid orientation"); + OSL_FAIL("invalid orientation"); return; } @@ -1166,7 +1166,7 @@ void SAL_CALL ScDPSource::setPropertyValue( const rtl::OUString& aPropertyName, } else { - DBG_ERROR("unknown property"); + OSL_FAIL("unknown property"); //! THROW( UnknownPropertyException() ); } } @@ -1200,7 +1200,7 @@ uno::Any SAL_CALL ScDPSource::getPropertyValue( const rtl::OUString& aPropertyNa } else { - DBG_ERROR("unknown property"); + OSL_FAIL("unknown property"); //! THROW( UnknownPropertyException() ); } return aRet; @@ -1604,7 +1604,7 @@ void SAL_CALL ScDPDimension::setPropertyValue( const rtl::OUString& aPropertyNam } if ( !bDone ) { - DBG_ERROR("Filter property is not a single string"); + OSL_FAIL("Filter property is not a single string"); throw lang::IllegalArgumentException(); } DELETEZ( pSelectedData ); // invalid after changing aSelectedPage @@ -1625,7 +1625,7 @@ void SAL_CALL ScDPDimension::setPropertyValue( const rtl::OUString& aPropertyNam aValue >>= mbHasHiddenMember; else { - DBG_ERROR("unknown property"); + OSL_FAIL("unknown property"); //! THROW( UnknownPropertyException() ); } } @@ -1712,7 +1712,7 @@ uno::Any SAL_CALL ScDPDimension::getPropertyValue( const rtl::OUString& aPropert } else { - DBG_ERROR("unknown property"); + OSL_FAIL("unknown property"); //! THROW( UnknownPropertyException() ); } return aRet; @@ -1878,7 +1878,7 @@ uno::Reference<container::XNameAccess> SAL_CALL ScDPHierarchy::getLevels() aRet = String::CreateFromAscii(RTL_CONSTASCII_STRINGPARAM("Week")); break; //! name ??????? default: - DBG_ERROR( "ScDPHierarchy::getName: unexpected hierarchy" ); + OSL_FAIL( "ScDPHierarchy::getName: unexpected hierarchy" ); break; } return aRet; @@ -1886,7 +1886,7 @@ uno::Reference<container::XNameAccess> SAL_CALL ScDPHierarchy::getLevels() void SAL_CALL ScDPHierarchy::setName( const ::rtl::OUString& /* rNewName */ ) throw(uno::RuntimeException) { - DBG_ERROR("not implemented"); //! exception? + OSL_FAIL("not implemented"); //! exception? } // ----------------------------------------------------------------------- @@ -1910,7 +1910,7 @@ ScDPLevels::ScDPLevels( ScDPSource* pSrc, long nD, long nH ) : case SC_DAPI_HIERARCHY_QUARTER: nLevCount = SC_DAPI_QUARTER_LEVELS; break; case SC_DAPI_HIERARCHY_WEEK: nLevCount = SC_DAPI_WEEK_LEVELS; break; default: - DBG_ERROR("wrong hierarchy"); + OSL_FAIL("wrong hierarchy"); nLevCount = 0; } } @@ -2177,7 +2177,7 @@ uno::Sequence<sheet::MemberResult> SAL_CALL ScDPLevel::getResults() throw(uno::R aRet = String::CreateFromAscii(RTL_CONSTASCII_STRINGPARAM("Day")); break; default: - DBG_ERROR( "ScDPLevel::getName: unexpected level" ); + OSL_FAIL( "ScDPLevel::getName: unexpected level" ); break; } } @@ -2195,7 +2195,7 @@ uno::Sequence<sheet::MemberResult> SAL_CALL ScDPLevel::getResults() throw(uno::R aRet = String::CreateFromAscii(RTL_CONSTASCII_STRINGPARAM("Weekday")); break; default: - DBG_ERROR( "ScDPLevel::getName: unexpected level" ); + OSL_FAIL( "ScDPLevel::getName: unexpected level" ); break; } } @@ -2212,7 +2212,7 @@ uno::Sequence<sheet::MemberResult> SAL_CALL ScDPLevel::getResults() throw(uno::R void SAL_CALL ScDPLevel::setName( const ::rtl::OUString& /* rNewName */ ) throw(uno::RuntimeException) { - DBG_ERROR("not implemented"); //! exception? + OSL_FAIL("not implemented"); //! exception? } uno::Sequence<sheet::GeneralFunction> ScDPLevel::getSubTotals() const @@ -2286,7 +2286,7 @@ void SAL_CALL ScDPLevel::setPropertyValue( const rtl::OUString& aPropertyName, c aValue >>= aLayoutInfo; else { - DBG_ERROR("unknown property"); + OSL_FAIL("unknown property"); } } @@ -2325,7 +2325,7 @@ uno::Any SAL_CALL ScDPLevel::getPropertyValue( const rtl::OUString& aPropertyNam } else { - DBG_ERROR("unknown property"); + OSL_FAIL("unknown property"); } return aRet; } @@ -2388,7 +2388,7 @@ ScDPMembers::ScDPMembers( ScDPSource* pSrc, long nD, long nH, long nL ) : case SC_DAPI_LEVEL_MONTH: nMbrCount = 12; break; case SC_DAPI_LEVEL_DAY: nMbrCount = 31; break; default: - DBG_ERROR( "ScDPMembers::ScDPMembers: unexpected level" ); + OSL_FAIL( "ScDPMembers::ScDPMembers: unexpected level" ); break; } } @@ -2400,7 +2400,7 @@ ScDPMembers::ScDPMembers( ScDPSource* pSrc, long nD, long nH, long nL ) : case SC_DAPI_LEVEL_WEEK: nMbrCount = 53; break; case SC_DAPI_LEVEL_WEEKDAY: nMbrCount = 7; break; default: - DBG_ERROR( "ScDPMembers::ScDPMembers: unexpected level" ); + OSL_FAIL( "ScDPMembers::ScDPMembers: unexpected level" ); break; } } @@ -2689,7 +2689,7 @@ String ScDPMember::GetNameStr() const void SAL_CALL ScDPMember::setName( const ::rtl::OUString& /* rNewName */ ) throw(uno::RuntimeException) { - DBG_ERROR("not implemented"); //! exception? + OSL_FAIL("not implemented"); //! exception? } BOOL ScDPMember::getIsVisible() const @@ -2768,7 +2768,7 @@ void SAL_CALL ScDPMember::setPropertyValue( const rtl::OUString& aPropertyName, } else { - DBG_ERROR("unknown property"); + OSL_FAIL("unknown property"); } } @@ -2788,7 +2788,7 @@ uno::Any SAL_CALL ScDPMember::getPropertyValue( const rtl::OUString& aPropertyNa aRet <<= mpLayoutName.get() ? *mpLayoutName : rtl::OUString(); else { - DBG_ERROR("unknown property"); + OSL_FAIL("unknown property"); } return aRet; } diff --git a/sc/source/core/data/drwlayer.cxx b/sc/source/core/data/drwlayer.cxx index 57d31d9e5..bb82473c8 100644 --- a/sc/source/core/data/drwlayer.cxx +++ b/sc/source/core/data/drwlayer.cxx @@ -1165,7 +1165,7 @@ void ScDrawLayer::DeleteObjectsInSelection( const ScMarkData& rMark ) } else { - DBG_ERROR("pPage?"); + OSL_FAIL("pPage?"); } } } @@ -1282,7 +1282,7 @@ void ScDrawLayer::CopyFromClip( ScDrawLayer* pClipModel, SCTAB nSourceTab, const if (bDrawIsInUndo) //! can this happen? { - DBG_ERROR("CopyFromClip, bDrawIsInUndo"); + OSL_FAIL("CopyFromClip, bDrawIsInUndo"); return; } diff --git a/sc/source/core/data/fillinfo.cxx b/sc/source/core/data/fillinfo.cxx index 899c52714..13041c0ef 100644 --- a/sc/source/core/data/fillinfo.cxx +++ b/sc/source/core/data/fillinfo.cxx @@ -258,7 +258,7 @@ void ScDocument::FillInfo( ScTableInfo& rTabInfo, SCCOL nX1, SCROW nY1, SCCOL nX ++nArrY; if (nArrY >= ROWINFO_MAX) { - DBG_ERROR("Zu grosser Bereich bei FillInfo" ); + OSL_FAIL("Zu grosser Bereich bei FillInfo" ); nYExtra = nSignedY; // Ende nY2 = nYExtra - 1; // Bereich anpassen } @@ -880,7 +880,7 @@ void ScDocument::FillInfo( ScTableInfo& rTabInfo, SCCOL nX1, SCROW nY1, SCCOL nX break; default: - DBG_ERROR("falscher Shadow-Enum"); + OSL_FAIL("falscher Shadow-Enum"); } } } diff --git a/sc/source/core/data/funcdesc.cxx b/sc/source/core/data/funcdesc.cxx index 142bedec7..c4cb2d61d 100644 --- a/sc/source/core/data/funcdesc.cxx +++ b/sc/source/core/data/funcdesc.cxx @@ -781,7 +781,7 @@ void ScFunctionMgr::fillLastRecentlyUsedFunctions(::std::vector< const formula:: { if ( _nCategoryNumber > SC_FUNCGROUP_COUNT ) { - DBG_ERROR("Invalid category number!"); + OSL_FAIL("Invalid category number!"); return ::rtl::OUString(); } diff --git a/sc/source/core/data/global.cxx b/sc/source/core/data/global.cxx index 9b00b3f87..9f5e7a3b7 100644 --- a/sc/source/core/data/global.cxx +++ b/sc/source/core/data/global.cxx @@ -606,14 +606,14 @@ void ScGlobal::InitTextHeight(SfxItemPool* pPool) { if (!pPool) { - DBG_ERROR("kein Pool bei ScGlobal::InitTextHeight"); + OSL_FAIL("kein Pool bei ScGlobal::InitTextHeight"); return; } const ScPatternAttr* pPattern = (const ScPatternAttr*)&pPool->GetDefaultItem(ATTR_PATTERN); if (!pPattern) { - DBG_ERROR("kein Default-Pattern bei ScGlobal::InitTextHeight"); + OSL_FAIL("kein Default-Pattern bei ScGlobal::InitTextHeight"); return; } diff --git a/sc/source/core/data/markdata.cxx b/sc/source/core/data/markdata.cxx index 36d333807..d1c470fcd 100644 --- a/sc/source/core/data/markdata.cxx +++ b/sc/source/core/data/markdata.cxx @@ -213,7 +213,7 @@ SCTAB ScMarkData::GetFirstSelected() const if (bTabMarked[i]) return i; - DBG_ERROR("GetFirstSelected: keine markiert"); + OSL_FAIL("GetFirstSelected: keine markiert"); return 0; } diff --git a/sc/source/core/data/olinetab.cxx b/sc/source/core/data/olinetab.cxx index 12d85a76f..6159e13a8 100644 --- a/sc/source/core/data/olinetab.cxx +++ b/sc/source/core/data/olinetab.cxx @@ -73,7 +73,7 @@ void ScOutlineEntry::Move( SCsCOLROW nDelta ) SCCOLROW nNewPos = nStart + nDelta; if (nNewPos<0) { - DBG_ERROR("OutlineEntry < 0"); + OSL_FAIL("OutlineEntry < 0"); nNewPos = 0; } nStart = nNewPos; @@ -85,7 +85,7 @@ void ScOutlineEntry::SetSize( SCSIZE nNewSize ) nSize = nNewSize; else { - DBG_ERROR("ScOutlineEntry Size == 0"); + OSL_FAIL("ScOutlineEntry Size == 0"); } } @@ -333,7 +333,7 @@ void ScOutlineArray::PromoteSub( SCCOLROW nStartPos, SCCOLROW nEndPos, USHORT nS { if (nStartLevel==0) { - DBG_ERROR("PromoteSub mit Level 0"); + OSL_FAIL("PromoteSub mit Level 0"); return; } @@ -751,7 +751,7 @@ USHORT ScSubOutlineIterator::LastEntry() const { if (nSubEntry == 0) { - DBG_ERROR("ScSubOutlineIterator::LastEntry vor GetNext"); + OSL_FAIL("ScSubOutlineIterator::LastEntry vor GetNext"); return 0; } return nSubEntry-1; @@ -761,12 +761,12 @@ void ScSubOutlineIterator::DeleteLast() { if (nSubLevel >= nDepth) { - DBG_ERROR("ScSubOutlineIterator::DeleteLast nach Ende"); + OSL_FAIL("ScSubOutlineIterator::DeleteLast nach Ende"); return; } if (nSubEntry == 0) { - DBG_ERROR("ScSubOutlineIterator::DeleteLast vor GetNext"); + OSL_FAIL("ScSubOutlineIterator::DeleteLast vor GetNext"); return; } diff --git a/sc/source/core/data/patattr.cxx b/sc/source/core/data/patattr.cxx index bfe48e7a3..fa2bbe1ab 100644 --- a/sc/source/core/data/patattr.cxx +++ b/sc/source/core/data/patattr.cxx @@ -946,7 +946,7 @@ SfxStyleSheetBase* lcl_CopyStyleToPool { if ( !pSrcStyle || !pDestPool || !pSrcPool ) { - DBG_ERROR( "CopyStyleToPool: Invalid Arguments :-/" ); + OSL_FAIL( "CopyStyleToPool: Invalid Arguments :-/" ); return NULL; } @@ -1183,7 +1183,7 @@ void ScPatternAttr::SetStyleSheet( ScStyleSheet* pNewStyle ) } else { - DBG_ERROR( "ScPatternAttr::SetStyleSheet( NULL ) :-|" ); + OSL_FAIL( "ScPatternAttr::SetStyleSheet( NULL ) :-|" ); GetItemSet().SetParent(NULL); pStyle = NULL; } diff --git a/sc/source/core/data/sortparam.cxx b/sc/source/core/data/sortparam.cxx index 9d6626597..1a705802c 100644 --- a/sc/source/core/data/sortparam.cxx +++ b/sc/source/core/data/sortparam.cxx @@ -264,7 +264,7 @@ void ScSortParam::MoveToDest() } else { - DBG_ERROR("MoveToDest, bInplace == TRUE"); + OSL_FAIL("MoveToDest, bInplace == TRUE"); } } diff --git a/sc/source/core/data/stlpool.cxx b/sc/source/core/data/stlpool.cxx index efe9c6e1b..5a12275ac 100644 --- a/sc/source/core/data/stlpool.cxx +++ b/sc/source/core/data/stlpool.cxx @@ -105,7 +105,7 @@ SfxStyleSheetBase& ScStyleSheetPool::Make( const String& rName, if ( rName.EqualsAscii(STRING_STANDARD) && Find( rName, eFam ) != NULL ) { - DBG_ERROR("renaming additional default style"); + OSL_FAIL("renaming additional default style"); sal_uInt32 nCount = aStyles.size(); for ( sal_uInt32 nAdd = 1; nAdd <= nCount; nAdd++ ) { diff --git a/sc/source/core/data/table1.cxx b/sc/source/core/data/table1.cxx index 464c9650a..1f131a8ce 100644 --- a/sc/source/core/data/table1.cxx +++ b/sc/source/core/data/table1.cxx @@ -1476,7 +1476,7 @@ void ScTable::ExtendPrintArea( OutputDevice* pDev, { if ( !pColFlags || !pRowFlags ) { - DBG_ERROR("keine ColInfo oder RowInfo in ExtendPrintArea"); + OSL_FAIL("keine ColInfo oder RowInfo in ExtendPrintArea"); return; } diff --git a/sc/source/core/data/table2.cxx b/sc/source/core/data/table2.cxx index ec0337023..f22158ed5 100644 --- a/sc/source/core/data/table2.cxx +++ b/sc/source/core/data/table2.cxx @@ -1100,7 +1100,7 @@ ScBaseCell* ScTable::GetCell( SCCOL nCol, SCROW nRow ) const if (ValidColRow( nCol, nRow )) return aCol[nCol].GetCell( nRow ); - DBG_ERROR("GetCell ausserhalb"); + OSL_FAIL("GetCell ausserhalb"); return NULL; } @@ -1306,7 +1306,7 @@ const ScPatternAttr* ScTable::GetPattern( SCCOL nCol, SCROW nRow ) const return aCol[nCol].GetPattern( nRow ); else { - DBG_ERROR("wrong column or row"); + OSL_FAIL("wrong column or row"); return pDocument->GetDefPattern(); // for safety } } @@ -1443,7 +1443,7 @@ void ScTable::FindMaxRotCol( RowInfo* pRowInfo, SCSIZE nArrCount, SCCOL nX1, SCC { if ( !pColWidth || !mpRowHeights || !pColFlags || !pRowFlags ) { - DBG_ERROR( "Spalten-/Zeileninfo fehlt" ); + OSL_FAIL( "Spalten-/Zeileninfo fehlt" ); return; } @@ -1765,7 +1765,7 @@ void ScTable::UnlockTable() --nLockCount; else { - DBG_ERROR("UnlockTable ohne LockTable"); + OSL_FAIL("UnlockTable ohne LockTable"); } } @@ -2077,7 +2077,7 @@ void ScTable::SetColWidth( SCCOL nCol, USHORT nNewWidth ) } else { - DBG_ERROR("Falsche Spaltennummer oder keine Breiten"); + OSL_FAIL("Falsche Spaltennummer oder keine Breiten"); } } @@ -2099,7 +2099,7 @@ void ScTable::SetRowHeight( SCROW nRow, USHORT nNewHeight ) { if (!nNewHeight) { - DBG_ERROR("Zeilenhoehe 0 in SetRowHeight"); + OSL_FAIL("Zeilenhoehe 0 in SetRowHeight"); nNewHeight = ScGlobal::nStdRowHeight; } @@ -2112,7 +2112,7 @@ void ScTable::SetRowHeight( SCROW nRow, USHORT nNewHeight ) } else { - DBG_ERROR("Falsche Zeilennummer oder keine Hoehen"); + OSL_FAIL("Falsche Zeilennummer oder keine Hoehen"); } } @@ -2158,7 +2158,7 @@ BOOL ScTable::SetRowHeightRange( SCROW nStartRow, SCROW nEndRow, USHORT nNewHeig { if (!nNewHeight) { - DBG_ERROR("Zeilenhoehe 0 in SetRowHeight"); + OSL_FAIL("Zeilenhoehe 0 in SetRowHeight"); nNewHeight = ScGlobal::nStdRowHeight; } @@ -2207,7 +2207,7 @@ BOOL ScTable::SetRowHeightRange( SCROW nStartRow, SCROW nEndRow, USHORT nNewHeig } else { - DBG_ERROR("Falsche Zeilennummer oder keine Hoehen"); + OSL_FAIL("Falsche Zeilennummer oder keine Hoehen"); } return bChanged; @@ -2235,7 +2235,7 @@ void ScTable::SetManualHeight( SCROW nStartRow, SCROW nEndRow, BOOL bManual ) } else { - DBG_ERROR("Falsche Zeilennummer oder keine Zeilenflags"); + OSL_FAIL("Falsche Zeilennummer oder keine Zeilenflags"); } } @@ -2273,7 +2273,7 @@ USHORT ScTable::GetCommonWidth( SCCOL nEndCol ) if ( !ValidCol(nEndCol) ) { - DBG_ERROR("wrong column"); + OSL_FAIL("wrong column"); nEndCol = MAXCOL; } @@ -2459,7 +2459,7 @@ void ScTable::ShowCol(SCCOL nCol, bool bShow) } else { - DBG_ERROR("Falsche Spaltennummer oder keine Flags"); + OSL_FAIL("Falsche Spaltennummer oder keine Flags"); } } @@ -2483,7 +2483,7 @@ void ScTable::ShowRow(SCROW nRow, bool bShow) } else { - DBG_ERROR("Falsche Zeilennummer oder keine Flags"); + OSL_FAIL("Falsche Zeilennummer oder keine Flags"); } } @@ -2510,7 +2510,7 @@ void ScTable::DBShowRow(SCROW nRow, bool bShow) } else { - DBG_ERROR("Falsche Zeilennummer oder keine Flags"); + OSL_FAIL("Falsche Zeilennummer oder keine Flags"); } } @@ -2601,7 +2601,7 @@ void ScTable::SetColFlags( SCCOL nCol, BYTE nNewFlags ) pColFlags[nCol] = nNewFlags; else { - DBG_ERROR("Falsche Spaltennummer oder keine Flags"); + OSL_FAIL("Falsche Spaltennummer oder keine Flags"); } } @@ -2612,7 +2612,7 @@ void ScTable::SetRowFlags( SCROW nRow, BYTE nNewFlags ) pRowFlags->SetValue( nRow, nNewFlags); else { - DBG_ERROR("Falsche Zeilennummer oder keine Flags"); + OSL_FAIL("Falsche Zeilennummer oder keine Flags"); } } @@ -2623,7 +2623,7 @@ void ScTable::SetRowFlags( SCROW nStartRow, SCROW nEndRow, BYTE nNewFlags ) pRowFlags->SetValue( nStartRow, nEndRow, nNewFlags); else { - DBG_ERROR("Falsche Zeilennummer(n) oder keine Flags"); + OSL_FAIL("Falsche Zeilennummer(n) oder keine Flags"); } } @@ -3007,7 +3007,7 @@ ULONG ScTable::GetRowOffset( SCROW nRow ) const } else { - DBG_ERROR("GetRowOffset: Daten fehlen"); + OSL_FAIL("GetRowOffset: Daten fehlen"); } return n; } @@ -3051,7 +3051,7 @@ ULONG ScTable::GetColOffset( SCCOL nCol ) const } else { - DBG_ERROR("GetColumnOffset: Daten fehlen"); + OSL_FAIL("GetColumnOffset: Daten fehlen"); } return n; } diff --git a/sc/source/core/data/table3.cxx b/sc/source/core/data/table3.cxx index 3f1f31973..7eca63eb3 100644 --- a/sc/source/core/data/table3.cxx +++ b/sc/source/core/data/table3.cxx @@ -1767,7 +1767,7 @@ BOOL ScTable::CreateExcelQuery(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow if ( nVisible > SCSIZE_MAX / sizeof(void*) ) { - DBG_ERROR("zu viele Filterkritierien"); + OSL_FAIL("zu viele Filterkritierien"); nVisible = 0; } diff --git a/sc/source/core/data/table4.cxx b/sc/source/core/data/table4.cxx index 27afcaece..9bf76f50f 100644 --- a/sc/source/core/data/table4.cxx +++ b/sc/source/core/data/table4.cxx @@ -1087,7 +1087,7 @@ String ScTable::GetAutoFillPreview( const ScRange& rSource, SCCOL nEndX, SCROW n } else { - DBG_ERROR("GetAutoFillPreview: falscher Modus"); + OSL_FAIL("GetAutoFillPreview: falscher Modus"); } } diff --git a/sc/source/core/data/table5.cxx b/sc/source/core/data/table5.cxx index 33aee6a38..fa4400d3a 100644 --- a/sc/source/core/data/table5.cxx +++ b/sc/source/core/data/table5.cxx @@ -87,7 +87,7 @@ void ScTable::UpdatePageBreaks( const ScRange* pUserArea ) Find( aPageStyle, SFX_STYLE_FAMILY_PAGE ); if ( !pStyle ) { - DBG_ERROR("UpdatePageBreaks: Style nicht gefunden"); + OSL_FAIL("UpdatePageBreaks: Style nicht gefunden"); return; } SfxItemSet* pStyleSet = &pStyle->GetItemSet(); diff --git a/sc/source/core/data/table6.cxx b/sc/source/core/data/table6.cxx index 842f7f454..98fcf8db2 100644 --- a/sc/source/core/data/table6.cxx +++ b/sc/source/core/data/table6.cxx @@ -136,7 +136,7 @@ BOOL ScTable::SearchCell(const SvxSearchItem& rSearchItem, SCCOL nCol, SCROW nRo } else { - DBG_ERROR("pSearchText == NULL"); + OSL_FAIL("pSearchText == NULL"); return bFound; } @@ -612,7 +612,7 @@ BOOL ScTable::ReplaceStyle(const SvxSearchItem& rSearchItem, SCCOL& rCol, SCROW& ApplyStyle( rCol, rRow, *pReplaceStyle ); else { - DBG_ERROR("pReplaceStyle==0"); + OSL_FAIL("pReplaceStyle==0"); } } @@ -676,7 +676,7 @@ BOOL ScTable::ReplaceAllStyle(const SvxSearchItem& rSearchItem, ScMarkData& rMar } else { - DBG_ERROR("pReplaceStyle==0"); + OSL_FAIL("pReplaceStyle==0"); } } diff --git a/sc/source/core/data/tabprotection.cxx b/sc/source/core/data/tabprotection.cxx index c737f571e..f45ec4bb3 100644 --- a/sc/source/core/data/tabprotection.cxx +++ b/sc/source/core/data/tabprotection.cxx @@ -351,7 +351,7 @@ bool ScTableProtectionImpl::isOptionEnabled(SCSIZE nOptId) const { if ( maOptions.size() <= static_cast<size_t>(nOptId) ) { - DBG_ERROR("ScTableProtectionImpl::isOptionEnabled: wrong size"); + OSL_FAIL("ScTableProtectionImpl::isOptionEnabled: wrong size"); return false; } @@ -362,7 +362,7 @@ void ScTableProtectionImpl::setOption(SCSIZE nOptId, bool bEnabled) { if ( maOptions.size() <= static_cast<size_t>(nOptId) ) { - DBG_ERROR("ScTableProtectionImpl::setOption: wrong size"); + OSL_FAIL("ScTableProtectionImpl::setOption: wrong size"); return; } diff --git a/sc/source/core/data/userdat.cxx b/sc/source/core/data/userdat.cxx index 3f923ec4f..9ad9a75a3 100644 --- a/sc/source/core/data/userdat.cxx +++ b/sc/source/core/data/userdat.cxx @@ -60,7 +60,7 @@ IMPL_LINK_INLINE_START( ScDrawObjFactory, MakeUserData, SdrObjFactory *, pObjFac pObjFactory->pNewData = new ScMacroInfo; else { - DBG_ERROR("MakeUserData: falsche ID"); + OSL_FAIL("MakeUserData: falsche ID"); } } return 0; diff --git a/sc/source/core/data/validat.cxx b/sc/source/core/data/validat.cxx index 4c435a864..b27a35da1 100644 --- a/sc/source/core/data/validat.cxx +++ b/sc/source/core/data/validat.cxx @@ -537,7 +537,7 @@ BOOL ScValidationData::IsDataValid( ScBaseCell* pCell, const ScAddress& rPos ) c break; default: - DBG_ERROR("hammanochnich"); + OSL_FAIL("hammanochnich"); break; } @@ -935,7 +935,7 @@ ScValidationData* ScValidationDataList::GetData( sal_uInt32 nKey ) if ((*this)[i]->GetKey() == nKey) return (*this)[i]; - DBG_ERROR("ScValidationDataList: Eintrag nicht gefunden"); + OSL_FAIL("ScValidationDataList: Eintrag nicht gefunden"); return NULL; } diff --git a/sc/source/core/inc/jumpmatrix.hxx b/sc/source/core/inc/jumpmatrix.hxx index 46fe43f11..f3ecd82f2 100644 --- a/sc/source/core/inc/jumpmatrix.hxx +++ b/sc/source/core/inc/jumpmatrix.hxx @@ -141,7 +141,7 @@ public: nRow = 0; else if (nCols <= nCol || nRows <= nRow) { - DBG_ERROR("ScJumpMatrix::GetJump: dimension error"); + OSL_FAIL("ScJumpMatrix::GetJump: dimension error"); nCol = 0; nRow = 0; } diff --git a/sc/source/core/tool/addincfg.cxx b/sc/source/core/tool/addincfg.cxx index f41ecc173..ce8cdbb56 100644 --- a/sc/source/core/tool/addincfg.cxx +++ b/sc/source/core/tool/addincfg.cxx @@ -56,7 +56,7 @@ ScAddInCfg::ScAddInCfg() : void ScAddInCfg::Commit() { - DBG_ERROR("ScAddInCfg shouldn't be modified"); + OSL_FAIL("ScAddInCfg shouldn't be modified"); } void ScAddInCfg::Notify( const uno::Sequence<rtl::OUString>& ) diff --git a/sc/source/core/tool/addincol.cxx b/sc/source/core/tool/addincol.cxx index d58f42855..f12e97256 100644 --- a/sc/source/core/tool/addincol.cxx +++ b/sc/source/core/tool/addincol.cxx @@ -1473,14 +1473,14 @@ void ScUnoAddInCall::SetParam( long nPos, const uno::Any& rValue ) aVarArg.getArray()[nVarPos] = rValue; else { - DBG_ERROR("wrong argument number"); + OSL_FAIL("wrong argument number"); } } else if ( nPos < aArgs.getLength() ) aArgs.getArray()[nPos] = rValue; else { - DBG_ERROR("wrong argument number"); + OSL_FAIL("wrong argument number"); } } } @@ -1510,7 +1510,7 @@ void ScUnoAddInCall::ExecuteCall() long nCallPos = pFuncData->GetCallerPos(); if (nCallPos>nUserLen) // should not happen { - DBG_ERROR("wrong CallPos"); + OSL_FAIL("wrong CallPos"); nCallPos = nUserLen; } diff --git a/sc/source/core/tool/adiasync.cxx b/sc/source/core/tool/adiasync.cxx index 85916d1e9..ec6a0e56b 100644 --- a/sc/source/core/tool/adiasync.cxx +++ b/sc/source/core/tool/adiasync.cxx @@ -138,7 +138,7 @@ void ScAddInAsync::CallBack( ULONG nHandleP, void* pData ) p->pStr = new String( (sal_Char*)pData, osl_getThreadTextEncoding() ); break; default : - DBG_ERROR( "unbekannter AsyncType" ); + OSL_FAIL( "unbekannter AsyncType" ); return; } p->bValid = TRUE; diff --git a/sc/source/core/tool/charthelper.cxx b/sc/source/core/tool/charthelper.cxx index fe11fcc79..b357ceeef 100644 --- a/sc/source/core/tool/charthelper.cxx +++ b/sc/source/core/tool/charthelper.cxx @@ -278,7 +278,7 @@ void ScChartHelper::SetChartRanges( const uno::Reference< chart2::XChartDocument catch ( uno::Exception& ex ) { (void)ex; - DBG_ERROR("Exception in ScChartHelper::SetChartRanges - invalid range string?"); + OSL_FAIL("Exception in ScChartHelper::SetChartRanges - invalid range string?"); } if( xModel.is() ) diff --git a/sc/source/core/tool/chartlock.cxx b/sc/source/core/tool/chartlock.cxx index 78230d037..dd3eb9c8d 100644 --- a/sc/source/core/tool/chartlock.cxx +++ b/sc/source/core/tool/chartlock.cxx @@ -106,7 +106,7 @@ ScChartLockGuard::ScChartLockGuard( ScDocument* pDoc ) : } catch ( uno::Exception& ) { - DBG_ERROR("Unexpected exception in ScChartLockGuard"); + OSL_FAIL("Unexpected exception in ScChartLockGuard"); } } } @@ -125,7 +125,7 @@ ScChartLockGuard::~ScChartLockGuard() } catch ( uno::Exception& ) { - DBG_ERROR("Unexpected exception in ScChartLockGuard"); + OSL_FAIL("Unexpected exception in ScChartLockGuard"); } } } @@ -149,7 +149,7 @@ void ScChartLockGuard::AlsoLockThisChart( const Reference< frame::XModel >& xMod } catch ( uno::Exception& ) { - DBG_ERROR("Unexpected exception in ScChartLockGuard"); + OSL_FAIL("Unexpected exception in ScChartLockGuard"); } } } diff --git a/sc/source/core/tool/chgtrack.cxx b/sc/source/core/tool/chgtrack.cxx index a5d3d0db5..43bb19b3d 100644 --- a/sc/source/core/tool/chgtrack.cxx +++ b/sc/source/core/tool/chgtrack.cxx @@ -653,7 +653,7 @@ ScChangeActionIns::ScChangeActionIns( const ScRange& rRange ) } else { - DBG_ERROR( "ScChangeActionIns: Block not supported!" ); + OSL_FAIL( "ScChangeActionIns: Block not supported!" ); } } @@ -766,7 +766,7 @@ ScChangeActionDel::ScChangeActionDel( const ScRange& rRange, } else { - DBG_ERROR( "ScChangeActionDel: Block not supported!" ); + OSL_FAIL( "ScChangeActionDel: Block not supported!" ); } } @@ -1777,7 +1777,7 @@ void ScChangeActionContent::GetFormulaString( String& rStr, pCell->GetFormula( rStr ); else { - DBG_ERROR( "ScChangeActionContent::GetFormulaString: aPos != pCell->aPos" ); + OSL_FAIL( "ScChangeActionContent::GetFormulaString: aPos != pCell->aPos" ); ScFormulaCell* pNew = new ScFormulaCell( *pCell, *pCell->GetDocument(), aPos ); pNew->GetFormula( rStr ); delete pNew; @@ -2466,7 +2466,7 @@ void ScChangeTrack::AppendDeleteRange( const ScRange& rRange, } else { - DBG_ERROR( "ScChangeTrack::AppendDeleteRange: Block not supported!" ); + OSL_FAIL( "ScChangeTrack::AppendDeleteRange: Block not supported!" ); } SetInDeleteTop( FALSE ); } @@ -3132,7 +3132,7 @@ void ScChangeTrack::Undo( ULONG nStartAction, ULONG nEndAction, bool bMerge ) } else { - DBG_ERROR( "ScChangeTrack::Undo: nCut not found" ); + OSL_FAIL( "ScChangeTrack::Undo: nCut not found" ); } } EndBlockModify( nEnd ); @@ -3323,7 +3323,7 @@ void ScChangeTrack::UpdateReference( ScChangeAction** ppFirstAction, ((ScChangeActionMove*)pAct)->GetDelta( nDx, nDy, nDz ); break; default: - DBG_ERROR( "ScChangeTrack::UpdateReference: unknown Type" ); + OSL_FAIL( "ScChangeTrack::UpdateReference: unknown Type" ); } if ( bUndo ) { @@ -4330,7 +4330,7 @@ BOOL ScChangeTrack::Reject( ScChangeAction* pAct, ScChangeActionTable* pTable, } else { - DBG_ERROR( "ScChangeTrack::Reject: say what?" ); + OSL_FAIL( "ScChangeTrack::Reject: say what?" ); } return bRejected; diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx index 5ecd92db2..e04d98f66 100644 --- a/sc/source/core/tool/compiler.cxx +++ b/sc/source/core/tool/compiler.cxx @@ -1047,7 +1047,7 @@ struct ConventionOOO_A1 : public Convention_A1 if (!lcl_getLastTabName(aLastTabName, rTabName, aTabNames, aRef)) { - DBG_ERROR( "ConventionOOO_A1::makeExternalRefStrImpl: sheet name not found"); + OSL_FAIL( "ConventionOOO_A1::makeExternalRefStrImpl: sheet name not found"); // aLastTabName contains #REF!, proceed. } } @@ -3980,7 +3980,7 @@ BOOL ScCompiler::HandleExternalReference(const FormulaToken& _aToken) return GetToken(); } default: - DBG_ERROR("Wrong type for external reference!"); + OSL_FAIL("Wrong type for external reference!"); return FALSE; } return TRUE; diff --git a/sc/source/core/tool/consoli.cxx b/sc/source/core/tool/consoli.cxx index 2e4e739dc..ffcfd8668 100644 --- a/sc/source/core/tool/consoli.cxx +++ b/sc/source/core/tool/consoli.cxx @@ -495,7 +495,7 @@ double lcl_CalcData( ScSubTotalFunc eFunc, break; default: { - DBG_ERROR("unbekannte Funktion bei Consoli::CalcData"); + OSL_FAIL("unbekannte Funktion bei Consoli::CalcData"); fCount = -MAXDOUBLE; } break; diff --git a/sc/source/core/tool/detfunc.cxx b/sc/source/core/tool/detfunc.cxx index 83e2e8e13..36507c6db 100644 --- a/sc/source/core/tool/detfunc.cxx +++ b/sc/source/core/tool/detfunc.cxx @@ -417,7 +417,7 @@ BOOL ScDetectiveFunc::HasArrow( const ScAddress& rStart, if (bStartAlien && bEndAlien) { - DBG_ERROR("bStartAlien && bEndAlien"); + OSL_FAIL("bStartAlien && bEndAlien"); return TRUE; } @@ -1316,7 +1316,7 @@ BOOL ScDetectiveFunc::DeleteAll( ScDetectiveDelete eWhat ) bDoThis = !bCaption && !bCircle; // don't include circles else { - DBG_ERROR("wat?"); + OSL_FAIL("wat?"); } } if ( bDoThis ) diff --git a/sc/source/core/tool/doubleref.cxx b/sc/source/core/tool/doubleref.cxx index fa0674876..b91d51d78 100644 --- a/sc/source/core/tool/doubleref.cxx +++ b/sc/source/core/tool/doubleref.cxx @@ -177,7 +177,7 @@ bool lcl_createExcelQuery( SCSIZE nVisible = pQueryRef->getVisibleDataCellCount(); if ( nVisible > SCSIZE_MAX / sizeof(void*) ) { - DBG_ERROR("zu viele Filterkritierien"); + OSL_FAIL("zu viele Filterkritierien"); nVisible = 0; } diff --git a/sc/source/core/tool/editutil.cxx b/sc/source/core/tool/editutil.cxx index a245e54de..90f51f565 100644 --- a/sc/source/core/tool/editutil.cxx +++ b/sc/source/core/tool/editutil.cxx @@ -686,7 +686,7 @@ String ScHeaderEditEngine::CalcFieldValue( const SvxFieldItem& rField, } else { - DBG_ERROR("FieldData ist 0"); + OSL_FAIL("FieldData ist 0"); aRet = '?'; } diff --git a/sc/source/core/tool/filtopt.cxx b/sc/source/core/tool/filtopt.cxx index c1a8787fa..4e915f450 100644 --- a/sc/source/core/tool/filtopt.cxx +++ b/sc/source/core/tool/filtopt.cxx @@ -110,12 +110,12 @@ void ScFilterOptions::Commit() { // options are never modified from office - DBG_ERROR("trying to commit changed ScFilterOptions?"); + OSL_FAIL("trying to commit changed ScFilterOptions?"); } void ScFilterOptions::Notify( const Sequence<OUString>& /* aPropertyNames */ ) { - DBG_ERROR("properties have been changed"); + OSL_FAIL("properties have been changed"); } diff --git a/sc/source/core/tool/inputopt.cxx b/sc/source/core/tool/inputopt.cxx index 6adba88a1..1f9c472bc 100644 --- a/sc/source/core/tool/inputopt.cxx +++ b/sc/source/core/tool/inputopt.cxx @@ -258,7 +258,7 @@ void ScInputCfg::Commit() void ScInputCfg::Notify( const Sequence<OUString>& /* aPropertyNames */ ) { - DBG_ERROR("properties have been changed"); + OSL_FAIL("properties have been changed"); } void ScInputCfg::SetOptions( const ScInputOptions& rNew ) diff --git a/sc/source/core/tool/interpr3.cxx b/sc/source/core/tool/interpr3.cxx index 395562d30..d42dec1c5 100644 --- a/sc/source/core/tool/interpr3.cxx +++ b/sc/source/core/tool/interpr3.cxx @@ -3287,7 +3287,7 @@ void ScInterpreter::ScPercentrank() if ( nOldCount == 0 ) { - DBG_ERROR("should not happen"); + OSL_FAIL("should not happen"); fRes = 0.0; } else diff --git a/sc/source/core/tool/interpr4.cxx b/sc/source/core/tool/interpr4.cxx index 52a1a7618..72cc4f7c7 100644 --- a/sc/source/core/tool/interpr4.cxx +++ b/sc/source/core/tool/interpr4.cxx @@ -1446,7 +1446,7 @@ void ScInterpreter::PopExternalSingleRef(ScExternalRefCache::TokenRef& rToken, S if (aData.IsTabRel()) { - DBG_ERROR("ScCompiler::GetToken: external single reference must have an absolute table reference!"); + OSL_FAIL("ScCompiler::GetToken: external single reference must have an absolute table reference!"); SetError(errNoRef); return; } @@ -1515,7 +1515,7 @@ void ScInterpreter::PopExternalDoubleRef(ScExternalRefCache::TokenArrayRef& rArr } if (aData.Ref1.IsTabRel() || aData.Ref2.IsTabRel()) { - DBG_ERROR("ScCompiler::GetToken: external double reference must have an absolute table reference!"); + OSL_FAIL("ScCompiler::GetToken: external double reference must have an absolute table reference!"); SetError(errNoRef); return; } diff --git a/sc/source/core/tool/progress.cxx b/sc/source/core/tool/progress.cxx index 916f71349..e6970a02b 100644 --- a/sc/source/core/tool/progress.cxx +++ b/sc/source/core/tool/progress.cxx @@ -92,7 +92,7 @@ ScProgress::ScProgress( SfxObjectShell* pObjSh, const String& rText, } else { - DBG_ERROR( "ScProgress: there can be only one!" ); + OSL_FAIL( "ScProgress: there can be only one!" ); pProgress = NULL; } } diff --git a/sc/source/core/tool/queryparam.cxx b/sc/source/core/tool/queryparam.cxx index 5402d3a00..90d96f4f5 100644 --- a/sc/source/core/tool/queryparam.cxx +++ b/sc/source/core/tool/queryparam.cxx @@ -334,7 +334,7 @@ void ScQueryParam::MoveToDest() } else { - DBG_ERROR("MoveToDest, bInplace == TRUE"); + OSL_FAIL("MoveToDest, bInplace == TRUE"); } } diff --git a/sc/source/core/tool/rangenam.cxx b/sc/source/core/tool/rangenam.cxx index 8b50bad23..85e034fd1 100644 --- a/sc/source/core/tool/rangenam.cxx +++ b/sc/source/core/tool/rangenam.cxx @@ -411,7 +411,7 @@ void ScRangeData::UpdateTabRef(SCTAB nOldTable, USHORT nFlag, SCTAB nNewTable) break; default: { - DBG_ERROR("ScRangeName::UpdateTabRef: Unknown Flag"); + OSL_FAIL("ScRangeName::UpdateTabRef: Unknown Flag"); } break; } diff --git a/sc/source/core/tool/rangeseq.cxx b/sc/source/core/tool/rangeseq.cxx index 4ae5ff92b..698b65742 100644 --- a/sc/source/core/tool/rangeseq.cxx +++ b/sc/source/core/tool/rangeseq.cxx @@ -250,7 +250,7 @@ double lcl_GetValueFromCell( ScBaseCell& rCell ) else if ( eType == CELLTYPE_FORMULA ) return ((ScFormulaCell&)rCell).GetValue(); // called only if result is value - DBG_ERROR( "GetValueFromCell: wrong type" ); + OSL_FAIL( "GetValueFromCell: wrong type" ); return 0; } diff --git a/sc/source/core/tool/rangeutl.cxx b/sc/source/core/tool/rangeutl.cxx index dbaba083b..d66598786 100644 --- a/sc/source/core/tool/rangeutl.cxx +++ b/sc/source/core/tool/rangeutl.cxx @@ -341,7 +341,7 @@ BOOL ScRangeUtil::MakeRangeFromName ( } else { - DBG_ERROR( "ScRangeUtil::MakeRangeFromName" ); + OSL_FAIL( "ScRangeUtil::MakeRangeFromName" ); } if( bResult ) diff --git a/sc/source/core/tool/rechead.cxx b/sc/source/core/tool/rechead.cxx index 06cba51dc..1a7193e02 100644 --- a/sc/source/core/tool/rechead.cxx +++ b/sc/source/core/tool/rechead.cxx @@ -56,7 +56,7 @@ ScMultipleReadHeader::ScMultipleReadHeader(SvStream& rNewStream) : rStream >> nID; if (nID != SCID_SIZES) { - DBG_ERROR("SCID_SIZES nicht gefunden"); + OSL_FAIL("SCID_SIZES nicht gefunden"); if ( rStream.GetError() == SVSTREAM_OK ) rStream.SetError( SVSTREAM_FILEFORMAT_ERROR ); @@ -121,7 +121,7 @@ ULONG ScMultipleReadHeader::BytesLeft() const if (nReadEnd <= nEntryEnd) return nEntryEnd-nReadEnd; - DBG_ERROR("Fehler bei ScMultipleReadHeader::BytesLeft"); + OSL_FAIL("Fehler bei ScMultipleReadHeader::BytesLeft"); return 0; } diff --git a/sc/source/core/tool/zforauto.cxx b/sc/source/core/tool/zforauto.cxx index e4681f593..b0ff74ad0 100644 --- a/sc/source/core/tool/zforauto.cxx +++ b/sc/source/core/tool/zforauto.cxx @@ -90,7 +90,7 @@ void ScNumFormatAbbrev::PutFormatIndex(ULONG nFormat, } else { - DBG_ERROR("SCNumFormatAbbrev:: unbekanntes Zahlformat"); + OSL_FAIL("SCNumFormatAbbrev:: unbekanntes Zahlformat"); eLnge = LANGUAGE_SYSTEM; eSysLnge = LANGUAGE_GERMAN; // sonst passt "Standard" nicht sFormatstring.AssignAscii( RTL_CONSTASCII_STRINGPARAM( pStandardName ) ); diff --git a/sc/source/filter/dif/difimp.cxx b/sc/source/filter/dif/difimp.cxx index f22bfa607..221bf19a7 100644 --- a/sc/source/filter/dif/difimp.cxx +++ b/sc/source/filter/dif/difimp.cxx @@ -222,7 +222,7 @@ FltError ScFormatFilterPluginImpl::ScImportDif( SvStream& rIn, ScDocument* pDoc, case D_SYNT_ERROR: break; default: - DBG_ERROR( "ScImportDif - missing enum" ); + OSL_FAIL( "ScImportDif - missing enum" ); } } diff --git a/sc/source/filter/excel/excform.cxx b/sc/source/filter/excel/excform.cxx index 6bf5e48e3..30d7a1578 100644 --- a/sc/source/filter/excel/excform.cxx +++ b/sc/source/filter/excel/excform.cxx @@ -515,7 +515,7 @@ ConvErr ExcelToSc::Convert( const ScTokenArray*& pErgebnis, XclImpStream& aIn, s case EXC_BIFF4: aIn.Ignore( 8 ); break; case EXC_BIFF5: aIn.Ignore( 12 ); break; default: - DBG_ERROR( + OSL_FAIL( "-ExcelToSc::Convert(): Ein wenig vergesslich, was?" ); } const XclImpName* pName = GetNameManager().GetName( nUINT16 ); @@ -1042,7 +1042,7 @@ ConvErr ExcelToSc::Convert( _ScRangeListTabs& rRangeList, XclImpStream& aIn, sal case EXC_BIFF3: case EXC_BIFF4: nIgnore = 10; break; case EXC_BIFF5: nIgnore = 14; break; - default: DBG_ERROR( "-ExcelToSc::Convert(): Ein wenig vergesslich, was?" ); + default: OSL_FAIL( "-ExcelToSc::Convert(): Ein wenig vergesslich, was?" ); } break; case 0x44: @@ -1701,7 +1701,7 @@ const ScTokenArray* ExcelToSc::GetBoolErr( XclBoolError eType ) case xlErrFalse: eOc = ocFalse; nError = 0; break; case xlErrUnknown: eOc = ocStop; nError = errUnknownState; break; default: - DBG_ERROR( "ExcelToSc::GetBoolErr - wrong enum!" ); + OSL_FAIL( "ExcelToSc::GetBoolErr - wrong enum!" ); eOc = ocNoName; nError = errUnknownState; } diff --git a/sc/source/filter/excel/read.cxx b/sc/source/filter/excel/read.cxx index 77011d088..ffc274f70 100644 --- a/sc/source/filter/excel/read.cxx +++ b/sc/source/filter/excel/read.cxx @@ -745,9 +745,9 @@ FltError ImportExcel::Read( void ) break; // ---------------------------------------------------------------- case Z_Ende: // ----------------------------------- Z_Ende - - DBG_ERROR( "*ImportExcel::Read(): Not possible state!" ); + OSL_FAIL( "*ImportExcel::Read(): Not possible state!" ); break; - default: DBG_ERROR( "-ImportExcel::Read(): Zustand vergessen!" ); + default: OSL_FAIL( "-ImportExcel::Read(): Zustand vergessen!" ); } } diff --git a/sc/source/filter/excel/tokstack.cxx b/sc/source/filter/excel/tokstack.cxx index 0bb5b3ebf..8dd682f65 100644 --- a/sc/source/filter/excel/tokstack.cxx +++ b/sc/source/filter/excel/tokstack.cxx @@ -322,7 +322,7 @@ void TokenPool::GetElement( const UINT16 nId ) { #ifdef DBG_UTIL case T_Id: - DBG_ERROR( "-TokenPool::GetElement(): hier hast Du nichts zu suchen!" ); + OSL_FAIL( "-TokenPool::GetElement(): hier hast Du nichts zu suchen!" ); break; #endif case T_Str: @@ -408,7 +408,7 @@ void TokenPool::GetElement( const UINT16 nId ) } break; default: - DBG_ERROR("-TokenPool::GetElement(): Zustand undefiniert!?"); + OSL_FAIL("-TokenPool::GetElement(): Zustand undefiniert!?"); } } } @@ -515,7 +515,7 @@ void TokenPool::GetElementRek( const UINT16 nId ) } break; default: - DBG_ERROR("-TokenPool::GetElementRek(): Zustand undefiniert!?"); + OSL_FAIL("-TokenPool::GetElementRek(): Zustand undefiniert!?"); } } else // elementarer SC_Token diff --git a/sc/source/filter/excel/xlstyle.cxx b/sc/source/filter/excel/xlstyle.cxx index 64a14819b..ebc016286 100644 --- a/sc/source/filter/excel/xlstyle.cxx +++ b/sc/source/filter/excel/xlstyle.cxx @@ -1647,7 +1647,7 @@ void XclCellAlign::SetScHorAlign( SvxCellHorJustify eHorJust ) case SVX_HOR_JUSTIFY_BLOCK: mnHorAlign = EXC_XF_HOR_JUSTIFY; break; case SVX_HOR_JUSTIFY_REPEAT: mnHorAlign = EXC_XF_HOR_FILL; break; default: mnHorAlign = EXC_XF_HOR_GENERAL; - DBG_ERROR( "XclCellAlign::SetScHorAlign - unknown horizontal alignment" ); + OSL_FAIL( "XclCellAlign::SetScHorAlign - unknown horizontal alignment" ); } } @@ -1660,7 +1660,7 @@ void XclCellAlign::SetScVerAlign( SvxCellVerJustify eVerJust ) case SVX_VER_JUSTIFY_CENTER: mnVerAlign = EXC_XF_VER_CENTER; break; case SVX_VER_JUSTIFY_BOTTOM: mnVerAlign = EXC_XF_VER_BOTTOM; break; default: mnVerAlign = EXC_XF_VER_BOTTOM; - DBG_ERROR( "XclCellAlign::SetScVerAlign - unknown vertical alignment" ); + OSL_FAIL( "XclCellAlign::SetScVerAlign - unknown vertical alignment" ); } } diff --git a/sc/source/filter/html/htmlpars.cxx b/sc/source/filter/html/htmlpars.cxx index 031110354..bdb142a2b 100644 --- a/sc/source/filter/html/htmlpars.cxx +++ b/sc/source/filter/html/htmlpars.cxx @@ -845,7 +845,7 @@ void ScHTMLLayoutParser::TableDataOn( ImportInfo* pInfo ) CloseEntry( pInfo ); if ( !nTableLevel ) { - DBG_ERROR( "Dummbatz-Dok! <TH> oder <TD> ohne vorheriges <TABLE>" ); + OSL_FAIL( "Dummbatz-Dok! <TH> oder <TD> ohne vorheriges <TABLE>" ); TableOn( pInfo ); } bInCell = TRUE; @@ -1074,7 +1074,7 @@ void ScHTMLLayoutParser::TableOff( ImportInfo* pInfo ) TableRowOff( pInfo ); // das optionale TableRowOff war nicht if ( !nTableLevel ) { - DBG_ERROR( "Dummbatz-Dok! </TABLE> ohne oeffnendes <TABLE>" ); + OSL_FAIL( "Dummbatz-Dok! </TABLE> ohne oeffnendes <TABLE>" ); return ; } if ( --nTableLevel > 0 ) diff --git a/sc/source/filter/lotus/lotform.cxx b/sc/source/filter/lotus/lotform.cxx index dc34edf03..6396cfdfa 100644 --- a/sc/source/filter/lotus/lotform.cxx +++ b/sc/source/filter/lotus/lotform.cxx @@ -267,7 +267,7 @@ void LotusToSc::LotusRelToScRel( UINT16 nCol, UINT16 nRow, ScSingleRefData& rSRD nRow &= 0x1FFF; break; default: - DBG_ERROR( "*LotusToSc::LotusRelToScRel(): etwas vergessen...?" ); + OSL_FAIL( "*LotusToSc::LotusRelToScRel(): etwas vergessen...?" ); } } else @@ -287,7 +287,7 @@ void LotusToSc::LotusRelToScRel( UINT16 nCol, UINT16 nRow, ScSingleRefData& rSRD nRow &= 0x3FFF; break; default: - DBG_ERROR( "*LotusToSc::LotusRelToScRel(): etwas vergessen...?" ); + OSL_FAIL( "*LotusToSc::LotusRelToScRel(): etwas vergessen...?" ); } } @@ -648,7 +648,7 @@ ConvErr LotusToSc::Convert( const ScTokenArray*& rpErg, INT32& rRest, } break; default: - DBG_ERROR( "*LotusToSc::Convert(): unbekannter enum!" ); + OSL_FAIL( "*LotusToSc::Convert(): unbekannter enum!" ); } } diff --git a/sc/source/filter/lotus/lotread.cxx b/sc/source/filter/lotus/lotread.cxx index ee54bfef1..29657483e 100644 --- a/sc/source/filter/lotus/lotread.cxx +++ b/sc/source/filter/lotus/lotread.cxx @@ -197,7 +197,7 @@ FltError ImportLotus::Read() // ----------------------------------------------------------- #ifdef DBG_UTIL default: - DBG_ERROR( "*ImportLotus::Read(): State unbekannt!" ); + OSL_FAIL( "*ImportLotus::Read(): State unbekannt!" ); eAkt = S_END; #endif } diff --git a/sc/source/filter/starcalc/scflt.cxx b/sc/source/filter/starcalc/scflt.cxx index ad8e3ab02..54970f550 100644 --- a/sc/source/filter/starcalc/scflt.cxx +++ b/sc/source/filter/starcalc/scflt.cxx @@ -417,7 +417,7 @@ Sc10FontCollection::Sc10FontCollection(SvStream& rStream) : } else { - DBG_ERROR( "FontID" ); + OSL_FAIL( "FontID" ); nError = errUnknownID; } } @@ -458,7 +458,7 @@ Sc10NameCollection::Sc10NameCollection(SvStream& rStream) : } else { - DBG_ERROR( "NameID" ); + OSL_FAIL( "NameID" ); nError = errUnknownID; } } @@ -503,7 +503,7 @@ Sc10PatternCollection::Sc10PatternCollection(SvStream& rStream) : } else { - DBG_ERROR( "PatternID" ); + OSL_FAIL( "PatternID" ); nError = errUnknownID; } } @@ -567,7 +567,7 @@ Sc10DataBaseCollection::Sc10DataBaseCollection(SvStream& rStream) : } else { - DBG_ERROR( "DataBaseID" ); + OSL_FAIL( "DataBaseID" ); nError = errUnknownID; } } @@ -1466,7 +1466,7 @@ void Sc10Import::LoadTables() rStream >> ID; if (ID != ColWidthID) { - DBG_ERROR( "ColWidthID" ); + OSL_FAIL( "ColWidthID" ); nError = errUnknownID; return; } @@ -1485,7 +1485,7 @@ void Sc10Import::LoadTables() rStream >> ID; if (ID != ColAttrID) { - DBG_ERROR( "ColAttrID" ); + OSL_FAIL( "ColAttrID" ); nError = errUnknownID; return; } @@ -1515,7 +1515,7 @@ void Sc10Import::LoadTables() rStream >> ID; if (ID != RowHeightID) { - DBG_ERROR( "RowHeightID" ); + OSL_FAIL( "RowHeightID" ); nError = errUnknownID; return; } @@ -1535,7 +1535,7 @@ void Sc10Import::LoadTables() rStream >> ID; if (ID != RowAttrID) { - DBG_ERROR( "RowAttrID" ); + OSL_FAIL( "RowAttrID" ); nError = errUnknownID; return; } @@ -1565,7 +1565,7 @@ void Sc10Import::LoadTables() rStream >> ID; if (ID != TableID) { - DBG_ERROR( "TableID" ); + OSL_FAIL( "TableID" ); nError = errUnknownID; return; } @@ -2378,7 +2378,7 @@ void Sc10Import::LoadObjects() } else { - DBG_ERROR( "ObjectID" ); + OSL_FAIL( "ObjectID" ); nError = errUnknownID; } } diff --git a/sc/source/filter/xcl97/XclExpChangeTrack.cxx b/sc/source/filter/xcl97/XclExpChangeTrack.cxx index 381ea8424..e0e9701ee 100644 --- a/sc/source/filter/xcl97/XclExpChangeTrack.cxx +++ b/sc/source/filter/xcl97/XclExpChangeTrack.cxx @@ -1064,7 +1064,7 @@ XclExpChTrInsert::XclExpChTrInsert( case SC_CAT_DELETE_COLS: nOpCode = EXC_CHTR_OP_DELCOL; break; case SC_CAT_DELETE_ROWS: nOpCode = EXC_CHTR_OP_DELROW; break; default: - DBG_ERROR( "XclExpChTrInsert::XclExpChTrInsert - unknown action" ); + OSL_FAIL( "XclExpChTrInsert::XclExpChTrInsert - unknown action" ); } if( nOpCode & EXC_CHTR_OP_COLFLAG ) diff --git a/sc/source/filter/xcl97/XclImpChangeTrack.cxx b/sc/source/filter/xcl97/XclImpChangeTrack.cxx index c47b8ebcd..3bad00a34 100644 --- a/sc/source/filter/xcl97/XclImpChangeTrack.cxx +++ b/sc/source/filter/xcl97/XclImpChangeTrack.cxx @@ -146,7 +146,7 @@ sal_Bool XclImpChangeTrack::CheckRecord( sal_uInt16 nOpCode ) { if( (nOpCode != EXC_CHTR_OP_UNKNOWN) && (aRecHeader.nOpCode != nOpCode) ) { - DBG_ERROR( "XclImpChangeTrack::CheckRecord - unknown action" ); + OSL_FAIL( "XclImpChangeTrack::CheckRecord - unknown action" ); return sal_False; } return aRecHeader.nIndex != 0; @@ -266,7 +266,7 @@ void XclImpChangeTrack::ReadCell( } break; default: - DBG_ERROR( "XclImpChangeTrack::ReadCell - unknown data type" ); + OSL_FAIL( "XclImpChangeTrack::ReadCell - unknown data type" ); } } @@ -280,7 +280,7 @@ void XclImpChangeTrack::ReadChTrInsert() (aRecHeader.nOpCode != EXC_CHTR_OP_DELROW) && (aRecHeader.nOpCode != EXC_CHTR_OP_DELCOL) ) { - DBG_ERROR( "XclImpChangeTrack::ReadChTrInsert - unknown action" ); + OSL_FAIL( "XclImpChangeTrack::ReadChTrInsert - unknown action" ); return; } @@ -351,7 +351,7 @@ void XclImpChangeTrack::ReadChTrCellContent() case 0x0000: break; case 0x1100: pStrm->Ignore( 16 ); break; case 0x1300: pStrm->Ignore( 8 ); break; - default: DBG_ERROR( "XclImpChangeTrack::ReadChTrCellContent - unknown format info" ); + default: OSL_FAIL( "XclImpChangeTrack::ReadChTrCellContent - unknown format info" ); } ScBaseCell* pOldCell; @@ -362,7 +362,7 @@ void XclImpChangeTrack::ReadChTrCellContent() ReadCell( pNewCell, nNewFormat, nNewValueType, aPosition ); if( !pStrm->IsValid() || (pStrm->GetRecLeft() > 0) ) { - DBG_ERROR( "XclImpChangeTrack::ReadChTrCellContent - bytes left, action ignored" ); + OSL_FAIL( "XclImpChangeTrack::ReadChTrCellContent - bytes left, action ignored" ); if( pOldCell ) pOldCell->Delete(); if( pNewCell ) diff --git a/sc/source/filter/xml/XMLChangeTrackingExportHelper.cxx b/sc/source/filter/xml/XMLChangeTrackingExportHelper.cxx index 37a7bcd21..22576f192 100644 --- a/sc/source/filter/xml/XMLChangeTrackingExportHelper.cxx +++ b/sc/source/filter/xml/XMLChangeTrackingExportHelper.cxx @@ -492,7 +492,7 @@ void ScChangeTrackingExportHelper::AddInsertionAttributes(const ScChangeAction* break; default : { - DBG_ERROR("wrong insertion type"); + OSL_FAIL("wrong insertion type"); } break; } @@ -556,7 +556,7 @@ void ScChangeTrackingExportHelper::AddDeletionAttributes(const ScChangeActionDel break; default : { - DBG_ERROR("wrong deletion type"); + OSL_FAIL("wrong deletion type"); } break; } @@ -711,7 +711,7 @@ void ScChangeTrackingExportHelper::WorkWithChangeAction(ScChangeAction* pAction) WriteRejection(pAction); else { - DBG_ERROR("not a writeable type"); + OSL_FAIL("not a writeable type"); } rExport.CheckAttrList(); } diff --git a/sc/source/filter/xml/XMLChangeTrackingImportHelper.cxx b/sc/source/filter/xml/XMLChangeTrackingImportHelper.cxx index e2acf1d4b..95933585a 100644 --- a/sc/source/filter/xml/XMLChangeTrackingImportHelper.cxx +++ b/sc/source/filter/xml/XMLChangeTrackingImportHelper.cxx @@ -278,7 +278,7 @@ sal_uInt32 ScXMLChangeTrackingImportHelper::GetIDFromString(const rtl::OUString& } else { - DBG_ERROR("wrong change action ID"); + OSL_FAIL("wrong change action ID"); } } return nResult; @@ -373,7 +373,7 @@ void ScXMLChangeTrackingImportHelper::SetInsertionCutOff(const sal_uInt32 nID, c } else { - DBG_ERROR("wrong action type"); + OSL_FAIL("wrong action type"); } } @@ -386,7 +386,7 @@ void ScXMLChangeTrackingImportHelper::AddMoveCutOff(const sal_uInt32 nID, const } else { - DBG_ERROR("wrong action type"); + OSL_FAIL("wrong action type"); } } @@ -398,7 +398,7 @@ void ScXMLChangeTrackingImportHelper::SetMoveRanges(const ScBigRange& aSourceRan } else { - DBG_ERROR("wrong action type"); + OSL_FAIL("wrong action type"); } } @@ -420,7 +420,7 @@ void ScXMLChangeTrackingImportHelper::GetMultiSpannedRange() } else { - DBG_ERROR("wrong action type"); + OSL_FAIL("wrong action type"); } } @@ -438,7 +438,7 @@ void ScXMLChangeTrackingImportHelper::AddGenerated(ScMyCellInfo* pCellInfo, cons } else { - DBG_ERROR("try to insert a generated action to a wrong action"); + OSL_FAIL("try to insert a generated action to a wrong action"); } } @@ -451,7 +451,7 @@ void ScXMLChangeTrackingImportHelper::EndChangeAction() aActions.push_back(pCurrentAction); else { - DBG_ERROR("no current action"); + OSL_FAIL("no current action"); } pCurrentAction = NULL; } @@ -615,7 +615,7 @@ void ScXMLChangeTrackingImportHelper::SetDeletionDependencies(ScMyDelAction* pAc } else { - DBG_ERROR("no cut off insert action"); + OSL_FAIL("no cut off insert action"); } } if (!pAction->aMoveCutOffs.empty()) @@ -637,7 +637,7 @@ void ScXMLChangeTrackingImportHelper::SetDeletionDependencies(ScMyDelAction* pAc } else { - DBG_ERROR("no cut off move action"); + OSL_FAIL("no cut off move action"); } aItr = pAction->aMoveCutOffs.erase(aItr); } @@ -747,7 +747,7 @@ void ScXMLChangeTrackingImportHelper::SetDependencies(ScMyBaseAction* pAction) } else { - DBG_ERROR("could not find the action"); + OSL_FAIL("could not find the action"); } } @@ -822,7 +822,7 @@ void ScXMLChangeTrackingImportHelper::SetNewCell(ScMyContentAction* pAction) } else { - DBG_ERROR("wrong cell position"); + OSL_FAIL("wrong cell position"); } } } @@ -889,7 +889,7 @@ void ScXMLChangeTrackingImportHelper::CreateChangeTrack(ScDocument* pTempDoc) pTrack->AppendLoaded(pAction); else { - DBG_ERROR("no action"); + OSL_FAIL("no action"); } ++aItr; diff --git a/sc/source/filter/xml/XMLExportDataPilot.cxx b/sc/source/filter/xml/XMLExportDataPilot.cxx index 0e9089477..240cbbf5c 100644 --- a/sc/source/filter/xml/XMLExportDataPilot.cxx +++ b/sc/source/filter/xml/XMLExportDataPilot.cxx @@ -123,7 +123,7 @@ rtl::OUString ScXMLExportDataPilot::getDPOperatorXML(const ScQueryOp aFilterOper case SC_TOPVAL : return GetXMLToken(XML_TOP_VALUES); default: - DBG_ERROR("This FilterOperator is not supported."); + OSL_FAIL("This FilterOperator is not supported."); } return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("=")); } diff --git a/sc/source/filter/xml/XMLExportIterator.cxx b/sc/source/filter/xml/XMLExportIterator.cxx index 3c93eb043..4e7ddf599 100644 --- a/sc/source/filter/xml/XMLExportIterator.cxx +++ b/sc/source/filter/xml/XMLExportIterator.cxx @@ -353,7 +353,7 @@ void ScMyAreaLinksContainer::SetCellData( ScMyCell& rMyCell ) ScUnoConversion::FillApiStartAddress( aAddress, aItr->aDestRange ); if (aAddress == rMyCell.aCellAddress) { - DBG_ERROR("more than one linked range on one cell"); + OSL_FAIL("more than one linked range on one cell"); aItr = aAreaLinkList.erase( aItr ); } else @@ -676,7 +676,7 @@ void ScMyNotEmptyCellsIterator::Clear() delete pCellItr; if (!aAnnotations.empty()) { - DBG_ERROR("not all Annotations saved"); + OSL_FAIL("not all Annotations saved"); aAnnotations.clear(); } pCellItr = NULL; diff --git a/sc/source/filter/xml/XMLStylesExportHelper.cxx b/sc/source/filter/xml/XMLStylesExportHelper.cxx index 263dbab11..bb06773a4 100644 --- a/sc/source/filter/xml/XMLStylesExportHelper.cxx +++ b/sc/source/filter/xml/XMLStylesExportHelper.cxx @@ -387,7 +387,7 @@ void ScMyValidationsContainer::WriteValidations(ScXMLExport& rExport) rExport.AddAttribute(XML_NAMESPACE_TABLE, XML_DISPLAY_LIST, XML_SORTED_ASCENDING); break; default: - DBG_ERROR("unknown ListType"); + OSL_FAIL("unknown ListType"); } } } @@ -762,7 +762,7 @@ sal_Int32 ScRowFormatRanges::GetMaxRows() const } else { - DBG_ERROR("no ranges found"); + OSL_FAIL("no ranges found"); } return nMaxRows; } diff --git a/sc/source/filter/xml/XMLStylesImportHelper.cxx b/sc/source/filter/xml/XMLStylesImportHelper.cxx index 05b86d6c4..af169af7d 100644 --- a/sc/source/filter/xml/XMLStylesImportHelper.cxx +++ b/sc/source/filter/xml/XMLStylesImportHelper.cxx @@ -122,7 +122,7 @@ void ScMyStyleRanges::AddRange(const ScRange& rRange, break; default: { - DBG_ERROR("wrong type"); + OSL_FAIL("wrong type"); } break; } @@ -347,7 +347,7 @@ ScMyStylesSet::iterator ScMyStylesImportHelper::GetIterator(const rtl::OUString* aStyle.sStyleName = *pStyleNameP; else { - DBG_ERROR("here is no stylename given"); + OSL_FAIL("here is no stylename given"); } ScMyStylesSet::iterator aItr(aCellStyles.find(aStyle)); if (aItr == aCellStyles.end()) @@ -357,7 +357,7 @@ ScMyStylesSet::iterator ScMyStylesImportHelper::GetIterator(const rtl::OUString* aItr = aPair.first; else { - DBG_ERROR("not possible to insert style"); + OSL_FAIL("not possible to insert style"); return aCellStyles.end(); } } diff --git a/sc/source/filter/xml/XMLTableShapeResizer.cxx b/sc/source/filter/xml/XMLTableShapeResizer.cxx index ae9a3e03c..b98ff9ec0 100644 --- a/sc/source/filter/xml/XMLTableShapeResizer.cxx +++ b/sc/source/filter/xml/XMLTableShapeResizer.cxx @@ -140,7 +140,7 @@ void ScMyOLEFixer::FixupOLEs() { // #i78086# also call CreateChartListener for invalid position (anchored to sheet) if (!IsOLE(aItr->xShape)) - DBG_ERROR("Only OLEs should be in here now"); + OSL_FAIL("Only OLEs should be in here now"); if (IsOLE(aItr->xShape)) { diff --git a/sc/source/filter/xml/XMLTrackedChangesContext.cxx b/sc/source/filter/xml/XMLTrackedChangesContext.cxx index f40fdd7a1..d29b9a677 100644 --- a/sc/source/filter/xml/XMLTrackedChangesContext.cxx +++ b/sc/source/filter/xml/XMLTrackedChangesContext.cxx @@ -1821,7 +1821,7 @@ SvXMLImportContext *ScXMLDeletionContext::CreateChildContext( USHORT nPrefix, pContext = new ScXMLCutOffsContext(GetScImport(), nPrefix, rLocalName, xAttrList, pChangeTrackingImportHelper); else { - DBG_ERROR("don't know this"); + OSL_FAIL("don't know this"); } } diff --git a/sc/source/filter/xml/xmlcelli.cxx b/sc/source/filter/xml/xmlcelli.cxx index 07b4b4c73..2cd7c849e 100644 --- a/sc/source/filter/xml/xmlcelli.cxx +++ b/sc/source/filter/xml/xmlcelli.cxx @@ -1000,7 +1000,7 @@ void ScXMLTableRowCellContext::EndElement() break; default: { - DBG_ERROR("no cell type given"); + OSL_FAIL("no cell type given"); } break; } diff --git a/sc/source/filter/xml/xmlexprt.cxx b/sc/source/filter/xml/xmlexprt.cxx index 77d20d606..d7046a85e 100644 --- a/sc/source/filter/xml/xmlexprt.cxx +++ b/sc/source/filter/xml/xmlexprt.cxx @@ -1657,7 +1657,7 @@ void ScXMLExport::_ExportContent() sal_Int32 nShapesCount(0); sal_Int32 nCellCount(pDoc ? pDoc->GetCellCount() : 0); CollectSharedData(nTableCount, nShapesCount, nCellCount); - DBG_ERROR("no shared data setted"); + OSL_FAIL("no shared data setted"); } ScXMLExportDatabaseRanges aExportDatabaseRanges(*this); if (!GetModel().is()) diff --git a/sc/source/filter/xml/xmlimprt.cxx b/sc/source/filter/xml/xmlimprt.cxx index 36f52697b..e53dfbd4b 100644 --- a/sc/source/filter/xml/xmlimprt.cxx +++ b/sc/source/filter/xml/xmlimprt.cxx @@ -1982,7 +1982,7 @@ void ScXMLImport::SetStatistics( if (i_rStats[i].Value >>= val) { nCount += val; } else { - DBG_ERROR("ScXMLImport::SetStatistics: invalid entry"); + OSL_FAIL("ScXMLImport::SetStatistics: invalid entry"); } } } @@ -2375,7 +2375,7 @@ sal_Bool ScXMLImport::IsCurrencySymbol(const sal_Int32 nNumberFormat, const rtl: } catch ( uno::Exception& ) { - DBG_ERROR("Numberformat not found"); + OSL_FAIL("Numberformat not found"); } } } @@ -2439,7 +2439,7 @@ void ScXMLImport::SetType(uno::Reference <beans::XPropertySet>& rProperties, } catch ( uno::Exception& ) { - DBG_ERROR("Numberformat not found"); + OSL_FAIL("Numberformat not found"); } } } @@ -2803,7 +2803,7 @@ void ScXMLImport::SetNamedRanges() } catch( uno::RuntimeException& ) { - DBG_ERROR("here are some Named Ranges with the same name"); + OSL_FAIL("here are some Named Ranges with the same name"); uno::Reference < container::XIndexAccess > xIndex(xNamedRanges, uno::UNO_QUERY); if (xIndex.is()) { diff --git a/sc/source/filter/xml/xmlstyle.cxx b/sc/source/filter/xml/xmlstyle.cxx index 3a68e300d..29aa9bb82 100644 --- a/sc/source/filter/xml/xmlstyle.cxx +++ b/sc/source/filter/xml/xmlstyle.cxx @@ -1882,7 +1882,7 @@ sal_Bool XmlScPropHdl_IsEqual::importXML( const ::rtl::OUString& /* rStrImpValue ::com::sun::star::uno::Any& /* rValue */, const SvXMLUnitConverter& /* rUnitConverter */ ) const { - DBG_ERROR("should never be called"); + OSL_FAIL("should never be called"); return sal_False; } @@ -1890,7 +1890,7 @@ sal_Bool XmlScPropHdl_IsEqual::exportXML( ::rtl::OUString& /* rStrExpValue */, const ::com::sun::star::uno::Any& /* rValue */, const SvXMLUnitConverter& /* rUnitConverter */ ) const { - DBG_ERROR("should never be called"); + OSL_FAIL("should never be called"); return sal_False; } diff --git a/sc/source/filter/xml/xmlstyli.cxx b/sc/source/filter/xml/xmlstyli.cxx index 5fa6f7cbd..01b4b0e5e 100644 --- a/sc/source/filter/xml/xmlstyli.cxx +++ b/sc/source/filter/xml/xmlstyli.cxx @@ -618,7 +618,7 @@ sal_Int32 XMLTableStyleContext::GetNumberFormat() pMyStyles->FindStyleChildContext(XML_STYLE_FAMILY_DATA_STYLE, sDataStyleName, sal_True)); else { - DBG_ERROR("not possible to get style"); + OSL_FAIL("not possible to get style"); } } if (pStyle) diff --git a/sc/source/filter/xml/xmlsubti.cxx b/sc/source/filter/xml/xmlsubti.cxx index fc27f5831..15ce55225 100644 --- a/sc/source/filter/xml/xmlsubti.cxx +++ b/sc/source/filter/xml/xmlsubti.cxx @@ -786,7 +786,7 @@ sal_Bool ScMyTables::IsPartOfMatrix(sal_Int32 nColumn, sal_Int32 nRow) { if (nCurrentSheet > aItr->aRange.Sheet) { - DBG_ERROR("should never hapen, because the list should be cleared in DeleteTable"); + OSL_FAIL("should never hapen, because the list should be cleared in DeleteTable"); aItr = aMatrixRangeList.erase(aItr); } else if ((nRow > aItr->aRange.EndRow) && (nColumn > aItr->aRange.EndColumn)) diff --git a/sc/source/ui/Accessibility/AccessibleContextBase.cxx b/sc/source/ui/Accessibility/AccessibleContextBase.cxx index 13236f51e..29f37001c 100644 --- a/sc/source/ui/Accessibility/AccessibleContextBase.cxx +++ b/sc/source/ui/Accessibility/AccessibleContextBase.cxx @@ -182,7 +182,7 @@ uno::Reference< XAccessible > SAL_CALL ScAccessibleContextBase::getAccessibleAtP const awt::Point& /* rPoint */ ) throw (uno::RuntimeException) { - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); return uno::Reference<XAccessible>(); } @@ -246,7 +246,7 @@ sal_Bool SAL_CALL ScAccessibleContextBase::isVisible( ) void SAL_CALL ScAccessibleContextBase::grabFocus( ) throw (uno::RuntimeException) { - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); } sal_Int32 SAL_CALL ScAccessibleContextBase::getForeground( ) @@ -267,7 +267,7 @@ sal_Int32 SAL_CALL ScAccessibleContextBase::getAccessibleChildCount(void) throw (uno::RuntimeException) { - DBG_ERROR("should be implemented in the abrevated class"); + OSL_FAIL("should be implemented in the abrevated class"); return 0; } @@ -275,7 +275,7 @@ uno::Reference<XAccessible> SAL_CALL ScAccessibleContextBase::getAccessibleChild(sal_Int32 /* nIndex */) throw (lang::IndexOutOfBoundsException, uno::RuntimeException) { - DBG_ERROR("should be implemented in the abrevated class"); + OSL_FAIL("should be implemented in the abrevated class"); return uno::Reference<XAccessible>(); } @@ -544,7 +544,7 @@ uno::Sequence<sal_Int8> SAL_CALL ScAccessibleContextBase::createAccessibleDescription(void) throw (uno::RuntimeException) { - DBG_ERROR("should be implemented in the abrevated class"); + OSL_FAIL("should be implemented in the abrevated class"); return rtl::OUString(); } @@ -552,7 +552,7 @@ uno::Sequence<sal_Int8> SAL_CALL ScAccessibleContextBase::createAccessibleName(void) throw (uno::RuntimeException) { - DBG_ERROR("should be implemented in the abrevated class"); + OSL_FAIL("should be implemented in the abrevated class"); return rtl::OUString(); } @@ -604,14 +604,14 @@ void ScAccessibleContextBase::CommitFocusLost() const Rectangle ScAccessibleContextBase::GetBoundingBoxOnScreen(void) const throw (uno::RuntimeException) { - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); return Rectangle(); } Rectangle ScAccessibleContextBase::GetBoundingBox(void) const throw (uno::RuntimeException) { - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); return Rectangle(); } diff --git a/sc/source/ui/Accessibility/AccessibleSpreadsheet.cxx b/sc/source/ui/Accessibility/AccessibleSpreadsheet.cxx index 703312201..047695e2b 100644 --- a/sc/source/ui/Accessibility/AccessibleSpreadsheet.cxx +++ b/sc/source/ui/Accessibility/AccessibleSpreadsheet.cxx @@ -332,7 +332,7 @@ void ScAccessibleSpreadsheet::Notify( SfxBroadcaster& rBC, const SfxHint& rHint } else { - DBG_ERROR("is it a deletion or a insertion?"); + OSL_FAIL("is it a deletion or a insertion?"); } CommitTableModelChange(rRef.GetRange().aStart.Row(), @@ -779,14 +779,14 @@ void ScAccessibleSpreadsheet::CreateSortedMarkedCells() } else { - DBG_ERROR("Range of wrong table"); + OSL_FAIL("Range of wrong table"); } } else if(pRange->aStart.Tab() == maActiveCell.Tab()) AddMarkedRange(*pRange); else { - DBG_ERROR("Range of wrong table"); + OSL_FAIL("Range of wrong table"); } } std::sort(mpSortedMarkedCells->begin(), mpSortedMarkedCells->end()); diff --git a/sc/source/ui/Accessibility/AccessibleTableBase.cxx b/sc/source/ui/Accessibility/AccessibleTableBase.cxx index 21e206a6c..d57e57dc2 100644 --- a/sc/source/ui/Accessibility/AccessibleTableBase.cxx +++ b/sc/source/ui/Accessibility/AccessibleTableBase.cxx @@ -115,7 +115,7 @@ sal_Int32 SAL_CALL ScAccessibleTableBase::getAccessibleColumnCount( ) ::rtl::OUString SAL_CALL ScAccessibleTableBase::getAccessibleRowDescription( sal_Int32 nRow ) throw (uno::RuntimeException, lang::IndexOutOfBoundsException) { - DBG_ERROR("Here should be a implementation to fill the description"); + OSL_FAIL("Here should be a implementation to fill the description"); if ((nRow > (maRange.aEnd.Row() - maRange.aStart.Row())) || (nRow < 0)) throw lang::IndexOutOfBoundsException(); @@ -127,7 +127,7 @@ sal_Int32 SAL_CALL ScAccessibleTableBase::getAccessibleColumnCount( ) ::rtl::OUString SAL_CALL ScAccessibleTableBase::getAccessibleColumnDescription( sal_Int32 nColumn ) throw (uno::RuntimeException, lang::IndexOutOfBoundsException) { - DBG_ERROR("Here should be a implementation to fill the description"); + OSL_FAIL("Here should be a implementation to fill the description"); if ((nColumn > (maRange.aEnd.Col() - maRange.aStart.Col())) || (nColumn < 0)) throw lang::IndexOutOfBoundsException(); @@ -198,7 +198,7 @@ uno::Reference< XAccessibleTable > SAL_CALL ScAccessibleTableBase::getAccessible throw (uno::RuntimeException) { uno::Reference< XAccessibleTable > xAccessibleTable; - DBG_ERROR("Here should be a implementation to fill the row headers"); + OSL_FAIL("Here should be a implementation to fill the row headers"); //CommitChange return xAccessibleTable; @@ -208,7 +208,7 @@ uno::Reference< XAccessibleTable > SAL_CALL ScAccessibleTableBase::getAccessible throw (uno::RuntimeException) { uno::Reference< XAccessibleTable > xAccessibleTable; - DBG_ERROR("Here should be a implementation to fill the column headers"); + OSL_FAIL("Here should be a implementation to fill the column headers"); //CommitChange return xAccessibleTable; @@ -217,7 +217,7 @@ uno::Reference< XAccessibleTable > SAL_CALL ScAccessibleTableBase::getAccessible uno::Sequence< sal_Int32 > SAL_CALL ScAccessibleTableBase::getSelectedAccessibleRows( ) throw (uno::RuntimeException) { - DBG_ERROR("not implemented yet"); + OSL_FAIL("not implemented yet"); uno::Sequence< sal_Int32 > aSequence; return aSequence; } @@ -225,7 +225,7 @@ uno::Sequence< sal_Int32 > SAL_CALL ScAccessibleTableBase::getSelectedAccessible uno::Sequence< sal_Int32 > SAL_CALL ScAccessibleTableBase::getSelectedAccessibleColumns( ) throw (uno::RuntimeException) { - DBG_ERROR("not implemented yet"); + OSL_FAIL("not implemented yet"); uno::Sequence< sal_Int32 > aSequence; return aSequence; } @@ -233,21 +233,21 @@ uno::Sequence< sal_Int32 > SAL_CALL ScAccessibleTableBase::getSelectedAccessible sal_Bool SAL_CALL ScAccessibleTableBase::isAccessibleRowSelected( sal_Int32 /* nRow */ ) throw (uno::RuntimeException, lang::IndexOutOfBoundsException) { - DBG_ERROR("not implemented yet"); + OSL_FAIL("not implemented yet"); return sal_False; } sal_Bool SAL_CALL ScAccessibleTableBase::isAccessibleColumnSelected( sal_Int32 /* nColumn */ ) throw (uno::RuntimeException, lang::IndexOutOfBoundsException) { - DBG_ERROR("not implemented yet"); + OSL_FAIL("not implemented yet"); return sal_False; } uno::Reference< XAccessible > SAL_CALL ScAccessibleTableBase::getAccessibleCellAt( sal_Int32 /* nRow */, sal_Int32 /* nColumn */ ) throw (uno::RuntimeException, lang::IndexOutOfBoundsException) { - DBG_ERROR("not implemented yet"); + OSL_FAIL("not implemented yet"); uno::Reference< XAccessible > xAccessible; return xAccessible; } @@ -255,7 +255,7 @@ uno::Reference< XAccessible > SAL_CALL ScAccessibleTableBase::getAccessibleCellA uno::Reference< XAccessible > SAL_CALL ScAccessibleTableBase::getAccessibleCaption( ) throw (uno::RuntimeException) { - DBG_ERROR("not implemented yet"); + OSL_FAIL("not implemented yet"); uno::Reference< XAccessible > xAccessible; return xAccessible; } @@ -263,7 +263,7 @@ uno::Reference< XAccessible > SAL_CALL ScAccessibleTableBase::getAccessibleCapti uno::Reference< XAccessible > SAL_CALL ScAccessibleTableBase::getAccessibleSummary( ) throw (uno::RuntimeException) { - DBG_ERROR("not implemented yet"); + OSL_FAIL("not implemented yet"); uno::Reference< XAccessible > xAccessible; return xAccessible; } @@ -271,7 +271,7 @@ uno::Reference< XAccessible > SAL_CALL ScAccessibleTableBase::getAccessibleSumma sal_Bool SAL_CALL ScAccessibleTableBase::isAccessibleSelected( sal_Int32 /* nRow */, sal_Int32 /* nColumn */ ) throw (uno::RuntimeException, lang::IndexOutOfBoundsException) { - DBG_ERROR("not implemented yet"); + OSL_FAIL("not implemented yet"); return sal_False; } @@ -373,7 +373,7 @@ uno::Reference<XAccessibleRelationSet> SAL_CALL ScAccessibleTableBase::getAccessibleRelationSet(void) throw (uno::RuntimeException) { - DBG_ERROR("should be implemented in the abrevated class"); + OSL_FAIL("should be implemented in the abrevated class"); return uno::Reference<XAccessibleRelationSet>(); } @@ -381,7 +381,7 @@ uno::Reference<XAccessibleStateSet> SAL_CALL ScAccessibleTableBase::getAccessibleStateSet(void) throw (uno::RuntimeException) { - DBG_ERROR("should be implemented in the abrevated class"); + OSL_FAIL("should be implemented in the abrevated class"); uno::Reference< XAccessibleStateSet > xAccessibleStateSet; return xAccessibleStateSet; } diff --git a/sc/source/ui/Accessibility/AccessibleText.cxx b/sc/source/ui/Accessibility/AccessibleText.cxx index f8a833e4b..9f4f1a78b 100644 --- a/sc/source/ui/Accessibility/AccessibleText.cxx +++ b/sc/source/ui/Accessibility/AccessibleText.cxx @@ -115,7 +115,7 @@ Rectangle ScViewForwarder::GetVisArea() const } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return aVisArea; } @@ -130,7 +130,7 @@ Point ScViewForwarder::LogicToPixel( const Point& rPoint, const MapMode& rMapMod } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return Point(); } @@ -145,7 +145,7 @@ Point ScViewForwarder::PixelToLogic( const Point& rPoint, const MapMode& rMapMod } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return Point(); } @@ -205,7 +205,7 @@ Rectangle ScEditObjectViewForwarder::GetVisArea() const } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return aVisArea; } @@ -226,7 +226,7 @@ Point ScEditObjectViewForwarder::LogicToPixel( const Point& rPoint, const MapMod } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return Point(); } @@ -247,7 +247,7 @@ Point ScEditObjectViewForwarder::PixelToLogic( const Point& rPoint, const MapMod } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return Point(); } @@ -299,7 +299,7 @@ BOOL ScPreviewViewForwarder::IsValid() const Rectangle ScPreviewViewForwarder::GetVisArea() const { Rectangle aVisArea; - DBG_ERROR("should be implemented in an abrevated class"); + OSL_FAIL("should be implemented in an abrevated class"); return aVisArea; } @@ -317,7 +317,7 @@ Point ScPreviewViewForwarder::LogicToPixel( const Point& rPoint, const MapMode& } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return Point(); } @@ -340,7 +340,7 @@ Point ScPreviewViewForwarder::PixelToLogic( const Point& rPoint, const MapMode& } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return Point(); } @@ -426,7 +426,7 @@ Rectangle ScPreviewHeaderFooterViewForwarder::GetVisArea() const } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return aVisArea; } @@ -466,7 +466,7 @@ Rectangle ScPreviewCellViewForwarder::GetVisArea() const } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return aVisArea; } @@ -512,7 +512,7 @@ Rectangle ScPreviewHeaderCellViewForwarder::GetVisArea() const } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return aVisArea; } @@ -556,7 +556,7 @@ Rectangle ScPreviewNoteViewForwarder::GetVisArea() const } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return aVisArea; } @@ -616,7 +616,7 @@ Rectangle ScEditViewForwarder::GetVisArea() const } else { - DBG_ERROR("this EditViewForwarder is no longer valid"); + OSL_FAIL("this EditViewForwarder is no longer valid"); } return aVisArea; } @@ -627,7 +627,7 @@ Point ScEditViewForwarder::LogicToPixel( const Point& rPoint, const MapMode& rMa return mpWindow->LogicToPixel( rPoint, rMapMode ); else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return Point(); } @@ -638,7 +638,7 @@ Point ScEditViewForwarder::PixelToLogic( const Point& rPoint, const MapMode& rMa return mpWindow->PixelToLogic( rPoint, rMapMode ); else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return Point(); } @@ -653,7 +653,7 @@ sal_Bool ScEditViewForwarder::GetSelection( ESelection& rSelection ) const } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return bResult; } @@ -668,7 +668,7 @@ sal_Bool ScEditViewForwarder::SetSelection( const ESelection& rSelection ) } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return bResult; } @@ -683,7 +683,7 @@ sal_Bool ScEditViewForwarder::Copy() } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return bResult; } @@ -698,7 +698,7 @@ sal_Bool ScEditViewForwarder::Cut() } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return bResult; } @@ -713,7 +713,7 @@ sal_Bool ScEditViewForwarder::Paste() } else { - DBG_ERROR("this ViewForwarder is not valid"); + OSL_FAIL("this ViewForwarder is not valid"); } return bResult; } diff --git a/sc/source/ui/app/client.cxx b/sc/source/ui/app/client.cxx index a66c08ec9..3bb4898b1 100644 --- a/sc/source/ui/app/client.cxx +++ b/sc/source/ui/app/client.cxx @@ -99,7 +99,7 @@ void ScClient::RequestNewObjectArea( Rectangle& aLogicRect ) ScTabViewShell* pViewSh = PTR_CAST( ScTabViewShell, pSfxViewSh ); if (!pViewSh) { - DBG_ERROR("Wrong ViewShell"); + OSL_FAIL("Wrong ViewShell"); return; } @@ -161,7 +161,7 @@ void ScClient::ObjectAreaChanged() ScTabViewShell* pViewSh = PTR_CAST( ScTabViewShell, pSfxViewSh ); if (!pViewSh) { - DBG_ERROR("Wrong ViewShell"); + OSL_FAIL("Wrong ViewShell"); return; } @@ -202,7 +202,7 @@ void ScClient::ViewChanged() aSz = xObj->getVisualAreaSize( GetAspect() ); } catch ( embed::NoVisualAreaSizeException& ) { - DBG_ERROR("The visual area size must be available!\n"); + OSL_FAIL("The visual area size must be available!\n"); } MapUnit aMapUnit = VCLUnoHelper::UnoEmbed2VCLMapUnit( xObj->getMapUnit( GetAspect() ) ); diff --git a/sc/source/ui/app/drwtrans.cxx b/sc/source/ui/app/drwtrans.cxx index fdf12bab2..b5776b533 100644 --- a/sc/source/ui/app/drwtrans.cxx +++ b/sc/source/ui/app/drwtrans.cxx @@ -249,12 +249,12 @@ ScDrawTransferObj::~ScDrawTransferObj() ScModule* pScMod = SC_MOD(); if ( pScMod->GetClipData().pDrawClipboard == this ) { - DBG_ERROR("ScDrawTransferObj wasn't released"); + OSL_FAIL("ScDrawTransferObj wasn't released"); pScMod->SetClipObject( NULL, NULL ); } if ( pScMod->GetDragData().pDrawTransfer == this ) { - DBG_ERROR("ScDrawTransferObj wasn't released"); + OSL_FAIL("ScDrawTransferObj wasn't released"); pScMod->ResetDragObject(); } @@ -613,7 +613,7 @@ sal_Bool ScDrawTransferObj::WriteObject( SotStorageStreamRef& rxOStm, void* pUse break; default: - DBG_ERROR("unknown object id"); + OSL_FAIL("unknown object id"); } return bRet; } diff --git a/sc/source/ui/app/inputhdl.cxx b/sc/source/ui/app/inputhdl.cxx index 5cef5bdf4..e995ee1e3 100644 --- a/sc/source/ui/app/inputhdl.cxx +++ b/sc/source/ui/app/inputhdl.cxx @@ -290,7 +290,7 @@ void ScInputHandler::UpdateRange( USHORT nIndex, const ScRange& rNew ) } else { - DBG_ERROR("UpdateRange: da fehlt was"); + OSL_FAIL("UpdateRange: da fehlt was"); } } @@ -1679,7 +1679,7 @@ void ScInputHandler::ViewShellGone(ScTabViewShell* pViewSh) // wird synchron au if ( pActiveViewSh && pActiveViewSh == pViewSh ) { - DBG_ERROR("pActiveViewSh weg"); + OSL_FAIL("pActiveViewSh weg"); pActiveViewSh = NULL; } @@ -2220,7 +2220,7 @@ void ScInputHandler::ShowRefFrame() } else { - DBG_ERROR("ViewFrame fuer Referenzeingabe ist nicht mehr da"); + OSL_FAIL("ViewFrame fuer Referenzeingabe ist nicht mehr da"); } } } @@ -2891,7 +2891,7 @@ void ScInputHandler::InsertFunction( const String& rFuncName, BOOL bAddPar ) { if ( eMode == SC_INPUT_NONE ) { - DBG_ERROR("InsertFunction, nicht im Eingabemodus"); + OSL_FAIL("InsertFunction, nicht im Eingabemodus"); return; } @@ -2938,7 +2938,7 @@ void ScInputHandler::ClearText() { if ( eMode == SC_INPUT_NONE ) { - DBG_ERROR("ClearText, nicht im Eingabemodus"); + OSL_FAIL("ClearText, nicht im Eingabemodus"); return; } diff --git a/sc/source/ui/app/scmod.cxx b/sc/source/ui/app/scmod.cxx index 80d82dd1b..58d561a77 100644 --- a/sc/source/ui/app/scmod.cxx +++ b/sc/source/ui/app/scmod.cxx @@ -639,7 +639,7 @@ void ScModule::Execute( SfxRequest& rReq ) break; default: - DBG_ERROR( "ScApplication: Unknown Message." ); + OSL_FAIL( "ScApplication: Unknown Message." ); break; } } @@ -1807,7 +1807,7 @@ void ScModule::SetReference( const ScRange& rRef, ScDocument* pDoc, pHdl->SetReference( aNew, pDoc ); else { - DBG_ERROR("SetReference ohne Empfaenger"); + OSL_FAIL("SetReference ohne Empfaenger"); } } } @@ -2182,7 +2182,7 @@ IMPL_LINK( ScModule, CalcFieldValueHdl, EditFieldInfo*, pInfo ) } else { - DBG_ERROR("unbekannter Feldbefehl"); + OSL_FAIL("unbekannter Feldbefehl"); pInfo->SetRepresentation(String('?')); } } diff --git a/sc/source/ui/app/scmod2.cxx b/sc/source/ui/app/scmod2.cxx index 47bde0cb5..585499109 100644 --- a/sc/source/ui/app/scmod2.cxx +++ b/sc/source/ui/app/scmod2.cxx @@ -96,7 +96,7 @@ BOOL ScModule::HasThesaurusLanguage( USHORT nLang ) } catch( uno::Exception& ) { - DBG_ERROR("Error in Thesaurus"); + OSL_FAIL("Error in Thesaurus"); } return bHasLang; diff --git a/sc/source/ui/app/transobj.cxx b/sc/source/ui/app/transobj.cxx index 0fb215385..9c3379ed4 100644 --- a/sc/source/ui/app/transobj.cxx +++ b/sc/source/ui/app/transobj.cxx @@ -197,12 +197,12 @@ ScTransferObj::~ScTransferObj() ScModule* pScMod = SC_MOD(); if ( pScMod->GetClipData().pCellClipboard == this ) { - DBG_ERROR("ScTransferObj wasn't released"); + OSL_FAIL("ScTransferObj wasn't released"); pScMod->SetClipObject( NULL, NULL ); } if ( pScMod->GetDragData().pCellTransfer == this ) { - DBG_ERROR("ScTransferObj wasn't released"); + OSL_FAIL("ScTransferObj wasn't released"); pScMod->ResetDragObject(); } @@ -228,7 +228,7 @@ ScTransferObj* ScTransferObj::GetOwnClipboard( Window* pUIWin ) TransferableDataHelper aDataHelper( TransferableDataHelper::CreateFromSystemClipboard( pUIWin ) ); if ( !aDataHelper.HasFormat( SOT_FORMATSTR_ID_DIF ) ) { -// DBG_ERROR("ScTransferObj wasn't released"); +// OSL_FAIL("ScTransferObj wasn't released"); pObj = NULL; } } @@ -335,7 +335,7 @@ sal_Bool ScTransferObj::GetData( const datatransfer::DataFlavor& rFlavor ) } else { - DBG_ERROR("unknown DataType"); + OSL_FAIL("unknown DataType"); } } else if ( nFormat == SOT_FORMAT_BITMAP ) @@ -474,7 +474,7 @@ sal_Bool ScTransferObj::WriteObject( SotStorageStreamRef& rxOStm, void* pUserObj break; default: - DBG_ERROR("unknown object id"); + OSL_FAIL("unknown object id"); } return bRet; } @@ -768,7 +768,7 @@ void ScTransferObj::StripRefs( ScDocument* pDoc, if (!pDoc->HasTable(nSrcTab) || !pDestDoc->HasTable(nDestTab)) { - DBG_ERROR("Sheet not found in ScTransferObj::StripRefs"); + OSL_FAIL("Sheet not found in ScTransferObj::StripRefs"); return; } diff --git a/sc/source/ui/app/wtcdummy.cxx b/sc/source/ui/app/wtcdummy.cxx index c1f5eed9b..da15940df 100644 --- a/sc/source/ui/app/wtcdummy.cxx +++ b/sc/source/ui/app/wtcdummy.cxx @@ -40,12 +40,12 @@ class SdbColumns SdbColumns::SdbColumns() { - DBG_ERROR("WATCOM Hack failed !"); + OSL_FAIL("WATCOM Hack failed !"); } SdbColumns::~SdbColumns() { - DBG_ERROR("WATCOM Hack failed !"); + OSL_FAIL("WATCOM Hack failed !"); } class SdbRow @@ -57,12 +57,12 @@ class SdbRow SdbRow::SdbRow() { - DBG_ERROR("WATCOM Hack failed !"); + OSL_FAIL("WATCOM Hack failed !"); } SdbRow::~SdbRow() { - DBG_ERROR("WATCOM Hack failed !"); + OSL_FAIL("WATCOM Hack failed !"); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sc/source/ui/dbgui/dapidata.cxx b/sc/source/ui/dbgui/dapidata.cxx index 365d7b1b8..4edaaee94 100644 --- a/sc/source/ui/dbgui/dapidata.cxx +++ b/sc/source/ui/dbgui/dapidata.cxx @@ -107,7 +107,7 @@ ScDataPilotDatabaseDlg::ScDataPilotDatabaseDlg( Window* pParent ) : } catch(uno::Exception&) { - DBG_ERROR("exception in database"); + OSL_FAIL("exception in database"); } aLbDatabase.SelectEntryPos( 0 ); diff --git a/sc/source/ui/dbgui/filtdlg.cxx b/sc/source/ui/dbgui/filtdlg.cxx index 018083074..71495f665 100644 --- a/sc/source/ui/dbgui/filtdlg.cxx +++ b/sc/source/ui/dbgui/filtdlg.cxx @@ -541,13 +541,13 @@ void ScFilterDlg::UpdateHdrInValueList( USHORT nList ) } else { - DBG_ERROR("Eintag in Liste nicht gefunden"); + OSL_FAIL("Eintag in Liste nicht gefunden"); } } } else { - DBG_ERROR("Spalte noch nicht initialisiert"); + OSL_FAIL("Spalte noch nicht initialisiert"); } } } diff --git a/sc/source/ui/dbgui/pvlaydlg.cxx b/sc/source/ui/dbgui/pvlaydlg.cxx index 37a6c14ab..6f8e119dc 100644 --- a/sc/source/ui/dbgui/pvlaydlg.cxx +++ b/sc/source/ui/dbgui/pvlaydlg.cxx @@ -992,7 +992,7 @@ void ScDPLayoutDlg::NotifyDoubleClick( ScDPFieldType eType, size_t nFieldIndex ) { if ( nFieldIndex >= pArr->size() ) { - DBG_ERROR("invalid selection"); + OSL_FAIL("invalid selection"); return; } diff --git a/sc/source/ui/dbgui/tpsubt.cxx b/sc/source/ui/dbgui/tpsubt.cxx index 290638e85..91a3ff02f 100644 --- a/sc/source/ui/dbgui/tpsubt.cxx +++ b/sc/source/ui/dbgui/tpsubt.cxx @@ -355,7 +355,7 @@ ScSubTotalFunc ScTpSubTotalGroup::LbPosToFunc( USHORT nPos ) case 9: return SUBTOTAL_FUNC_VAR; case 10: return SUBTOTAL_FUNC_VARP; default: - DBG_ERROR( "ScTpSubTotalGroup::LbPosToFunc" ); + OSL_FAIL( "ScTpSubTotalGroup::LbPosToFunc" ); return SUBTOTAL_FUNC_NONE; } } @@ -379,7 +379,7 @@ USHORT ScTpSubTotalGroup::FuncToLbPos( ScSubTotalFunc eFunc ) case SUBTOTAL_FUNC_VAR: return 9; case SUBTOTAL_FUNC_VARP: return 10; default: - DBG_ERROR( "ScTpSubTotalGroup::FuncToLbPos" ); + OSL_FAIL( "ScTpSubTotalGroup::FuncToLbPos" ); return 0; } } diff --git a/sc/source/ui/docshell/dbdocfun.cxx b/sc/source/ui/docshell/dbdocfun.cxx index b3966d4d2..2c96f7bcc 100644 --- a/sc/source/ui/docshell/dbdocfun.cxx +++ b/sc/source/ui/docshell/dbdocfun.cxx @@ -427,7 +427,7 @@ BOOL ScDBDocFunc::Sort( SCTAB nTab, const ScSortParam& rSortParam, rSortParam.nCol2, rSortParam.nRow2 ); if (!pDBData) { - DBG_ERROR( "Sort: keine DBData" ); + OSL_FAIL( "Sort: keine DBData" ); return FALSE; } @@ -606,7 +606,7 @@ BOOL ScDBDocFunc::Sort( SCTAB nTab, const ScSortParam& rSortParam, } else { - DBG_ERROR("Zielbereich nicht da"); + OSL_FAIL("Zielbereich nicht da"); } } @@ -663,7 +663,7 @@ BOOL ScDBDocFunc::Query( SCTAB nTab, const ScQueryParam& rQueryParam, rQueryParam.nCol2, rQueryParam.nRow2 ); if (!pDBData) { - DBG_ERROR( "Query: keine DBData" ); + OSL_FAIL( "Query: keine DBData" ); return FALSE; } @@ -935,7 +935,7 @@ BOOL ScDBDocFunc::Query( SCTAB nTab, const ScQueryParam& rQueryParam, } else { - DBG_ERROR("Zielbereich nicht da"); + OSL_FAIL("Zielbereich nicht da"); } } @@ -1002,7 +1002,7 @@ BOOL ScDBDocFunc::DoSubTotals( SCTAB nTab, const ScSubTotalParam& rParam, rParam.nCol2, rParam.nRow2 ); if (!pDBData) { - DBG_ERROR( "SubTotals: keine DBData" ); + OSL_FAIL( "SubTotals: keine DBData" ); return FALSE; } @@ -1289,7 +1289,7 @@ BOOL ScDBDocFunc::DataPilotUpdate( ScDPObject* pOldObj, const ScDPObject* pNewOb pDestObj->SetAlive(TRUE); if ( !pDoc->GetDPCollection()->InsertNewTable(pDestObj) ) { - DBG_ERROR("cannot insert DPObject"); + OSL_FAIL("cannot insert DPObject"); DELETEZ( pDestObj ); } } diff --git a/sc/source/ui/docshell/dbdocimp.cxx b/sc/source/ui/docshell/dbdocimp.cxx index 41bdc3bf0..d21e8303f 100644 --- a/sc/source/ui/docshell/dbdocimp.cxx +++ b/sc/source/ui/docshell/dbdocimp.cxx @@ -112,7 +112,7 @@ void ScDBDocFunc::ShowInBeamer( const ScImportParam& rParam, SfxViewFrame* pFram } else { - DBG_ERROR("no selection supplier in the beamer!"); + OSL_FAIL("no selection supplier in the beamer!"); } } } @@ -230,7 +230,7 @@ BOOL ScDBDocFunc::DoImport( SCTAB nTab, const ScImportParam& rParam, rParam.nCol2, rParam.nRow2 ); if (!pDBData) { - DBG_ERROR( "DoImport: no DBData" ); + OSL_FAIL( "DoImport: no DBData" ); return FALSE; } } @@ -457,7 +457,7 @@ BOOL ScDBDocFunc::DoImport( SCTAB nTab, const ScImportParam& rParam, } catch ( uno::Exception& ) { - DBG_ERROR("Unexpected exception in database"); + OSL_FAIL("Unexpected exception in database"); } pImportDoc->DoColResize( nTab, rParam.nCol1,nEndCol, 0 ); diff --git a/sc/source/ui/docshell/docfunc.cxx b/sc/source/ui/docshell/docfunc.cxx index 8579baa04..60425895e 100644 --- a/sc/source/ui/docshell/docfunc.cxx +++ b/sc/source/ui/docshell/docfunc.cxx @@ -518,7 +518,7 @@ BOOL ScDocFunc::DetectiveRefresh( BOOL bAutomatic ) aFunc.ShowError( nCol, nRow ); break; default: - DBG_ERROR("falsche Op bei DetectiveRefresh"); + OSL_FAIL("falsche Op bei DetectiveRefresh"); } } } @@ -589,7 +589,7 @@ BOOL ScDocFunc::DeleteContents( const ScMarkData& rMark, USHORT nFlags, if ( !rMark.IsMarked() && !rMark.IsMultiMarked() ) { - DBG_ERROR("ScDocFunc::DeleteContents ohne Markierung"); + OSL_FAIL("ScDocFunc::DeleteContents ohne Markierung"); return FALSE; } @@ -1359,7 +1359,7 @@ BOOL ScDocFunc::InsertCells( const ScRange& rRange, const ScMarkData* pTabMark, if ( !ValidRow(nStartRow) || !ValidRow(nEndRow) ) { - DBG_ERROR("invalid row in InsertCells"); + OSL_FAIL("invalid row in InsertCells"); return FALSE; } @@ -1638,7 +1638,7 @@ BOOL ScDocFunc::InsertCells( const ScRange& rRange, const ScMarkData* pTabMark, nPaintFlags |= PAINT_TOP; break; default: - DBG_ERROR("Falscher Code beim Einfuegen"); + OSL_FAIL("Falscher Code beim Einfuegen"); bSuccess = FALSE; break; } @@ -1794,7 +1794,7 @@ BOOL ScDocFunc::DeleteCells( const ScRange& rRange, const ScMarkData* pTabMark, if ( !ValidRow(nStartRow) || !ValidRow(nEndRow) ) { - DBG_ERROR("invalid row in DeleteCells"); + OSL_FAIL("invalid row in DeleteCells"); return FALSE; } @@ -2100,7 +2100,7 @@ BOOL ScDocFunc::DeleteCells( const ScRange& rRange, const ScMarkData* pTabMark, nPaintFlags |= PAINT_TOP; break; default: - DBG_ERROR("Falscher Code beim Loeschen"); + OSL_FAIL("Falscher Code beim Loeschen"); break; } @@ -2280,7 +2280,7 @@ BOOL ScDocFunc::MoveBlock( const ScRange& rSource, const ScAddress& rDestPos, if ( !ValidRow(nStartRow) || !ValidRow(nEndRow) || !ValidRow(nDestRow) ) { - DBG_ERROR("invalid row in MoveBlock"); + OSL_FAIL("invalid row in MoveBlock"); return FALSE; } @@ -4195,7 +4195,7 @@ BOOL ScDocFunc::FillAuto( ScRange& rRange, const ScMarkData* pTabMark, FillDir e case FILL_TO_TOP: if (nCount > sal::static_int_cast<ULONG>( aSourceArea.aStart.Row() )) { - DBG_ERROR("FillAuto: Row < 0"); + OSL_FAIL("FillAuto: Row < 0"); nCount = aSourceArea.aStart.Row(); } aDestArea.aStart.SetRow( sal::static_int_cast<SCROW>( aSourceArea.aStart.Row() - nCount ) ); @@ -4206,13 +4206,13 @@ BOOL ScDocFunc::FillAuto( ScRange& rRange, const ScMarkData* pTabMark, FillDir e case FILL_TO_LEFT: if (nCount > sal::static_int_cast<ULONG>( aSourceArea.aStart.Col() )) { - DBG_ERROR("FillAuto: Col < 0"); + OSL_FAIL("FillAuto: Col < 0"); nCount = aSourceArea.aStart.Col(); } aDestArea.aStart.SetCol( sal::static_int_cast<SCCOL>( aSourceArea.aStart.Col() - nCount ) ); break; default: - DBG_ERROR("Falsche Richtung bei FillAuto"); + OSL_FAIL("Falsche Richtung bei FillAuto"); break; } @@ -4584,7 +4584,7 @@ void ScDocFunc::CreateOneName( ScRangeName& rList, ScAddress( nPosX, nPosY, nTab)); if (!rList.Insert(pData)) { - DBG_ERROR("nanu?"); + OSL_FAIL("nanu?"); delete pData; } } diff --git a/sc/source/ui/docshell/docsh.cxx b/sc/source/ui/docshell/docsh.cxx index 05a5cf159..e3614a831 100644 --- a/sc/source/ui/docshell/docsh.cxx +++ b/sc/source/ui/docshell/docsh.cxx @@ -224,7 +224,7 @@ void ScDocShell::FillClass( SvGlobalName* pClassName, } else { - DBG_ERROR("wat fuer ne Version?"); + OSL_FAIL("wat fuer ne Version?"); } } @@ -400,7 +400,7 @@ void ScDocShell::AfterXMLLoading(sal_Bool bRet) } else { - DBG_ERROR("The Modificator should exist"); + OSL_FAIL("The Modificator should exist"); } aDocument.DisableIdle( FALSE ); @@ -902,7 +902,7 @@ void ScDocShell::Notify( SfxBroadcaster&, const SfxHint& rHint ) } catch ( uno::Exception& ) { - DBG_ERROR( "SFX_EVENT_SAVEDOC: caught exception\n" ); + OSL_FAIL( "SFX_EVENT_SAVEDOC: caught exception\n" ); SC_MOD()->SetInSharedDocSaving( false ); try @@ -1200,7 +1200,7 @@ BOOL ScDocShell::ConvertFrom( SfxMedium& rMedium ) } else { - DBG_ERROR( "No Stream" ); + OSL_FAIL( "No Stream" ); } } @@ -1312,7 +1312,7 @@ BOOL ScDocShell::ConvertFrom( SfxMedium& rMedium ) } else { - DBG_ERROR( "No Stream" ); + OSL_FAIL( "No Stream" ); } } @@ -1370,7 +1370,7 @@ BOOL ScDocShell::ConvertFrom( SfxMedium& rMedium ) } else { - DBG_ERROR( "No Stream" ); + OSL_FAIL( "No Stream" ); } } @@ -1419,7 +1419,7 @@ BOOL ScDocShell::ConvertFrom( SfxMedium& rMedium ) } else { - DBG_ERROR( "No Stream" ); + OSL_FAIL( "No Stream" ); } } @@ -1437,7 +1437,7 @@ BOOL ScDocShell::ConvertFrom( SfxMedium& rMedium ) } else { - DBG_ERROR("Kein Filter bei ConvertFrom"); + OSL_FAIL("Kein Filter bei ConvertFrom"); } InitItems(); @@ -1887,7 +1887,7 @@ void ScDocShell::AsciiSave( SvStream& rStream, const ScImportOptions& rAsciiOpt } break; default: - DBG_ERROR( "ScDocShell::AsciiSave: unknown CellType" ); + OSL_FAIL( "ScDocShell::AsciiSave: unknown CellType" ); aString.Erase(); bString = FALSE; } @@ -2055,7 +2055,7 @@ BOOL ScDocShell::ConvertTo( SfxMedium &rMed ) if (aFltName.EqualsAscii(pFilterXML)) { //TODO/LATER: this shouldn't happen! - DBG_ERROR("XML filter in ConvertFrom?!"); + OSL_FAIL("XML filter in ConvertFrom?!"); bRet = SaveXML( &rMed, NULL ); } else if (aFltName.EqualsAscii(pFilterExcel5) || aFltName.EqualsAscii(pFilterExcel95) || @@ -2576,7 +2576,7 @@ ScDocShell::~ScDocShell() if (pModificator) { - DBG_ERROR("The Modificator should not exist"); + OSL_FAIL("The Modificator should not exist"); delete pModificator; } } diff --git a/sc/source/ui/docshell/docsh3.cxx b/sc/source/ui/docshell/docsh3.cxx index a8fa71f01..80f68a9f2 100644 --- a/sc/source/ui/docshell/docsh3.cxx +++ b/sc/source/ui/docshell/docsh3.cxx @@ -274,7 +274,7 @@ void ScDocShell::UnlockPaint_Impl(BOOL bDoc) } else { - DBG_ERROR("UnlockPaint ohne LockPaint"); + OSL_FAIL("UnlockPaint ohne LockPaint"); } } @@ -347,7 +347,7 @@ void ScDocShell::UnlockDocument() } else { - DBG_ERROR("UnlockDocument without LockDocument"); + OSL_FAIL("UnlockDocument without LockDocument"); } } @@ -407,7 +407,7 @@ void ScDocShell::CalcOutputFactor() nPrtToScreenFactor = nPrinterWidth / (double) nWindowWidth; else { - DBG_ERROR("GetTextSize gibt 0 ??"); + OSL_FAIL("GetTextSize gibt 0 ??"); nPrtToScreenFactor = 1.0; } } @@ -800,7 +800,7 @@ bool lcl_FindAction( ScDocument* pDoc, const ScChangeAction* pAction, ScDocument pA->GetDescription( aADesc, pSearchDoc, TRUE ); if ( aActionDesc.Equals( aADesc ) ) { - DBG_ERROR( "lcl_FindAction(): found equal action!" ); + OSL_FAIL( "lcl_FindAction(): found equal action!" ); return true; } } @@ -1064,7 +1064,7 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc, bool bShared, bool bCheck pViewSh->EnterData( aPos.Col(), aPos.Row(), aPos.Tab(), aValue ); break; default: - DBG_ERROR( "MergeDocument: unknown MatrixFlag" ); + OSL_FAIL( "MergeDocument: unknown MatrixFlag" ); } } break; @@ -1136,7 +1136,7 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc, bool bShared, bool bCheck pAct->SetComment( rComment ); #ifdef DBG_UTIL else - DBG_ERROR( "MergeDocument: wohin mit dem Kommentar?!?" ); + OSL_FAIL( "MergeDocument: wohin mit dem Kommentar?!?" ); #endif } diff --git a/sc/source/ui/docshell/docsh4.cxx b/sc/source/ui/docshell/docsh4.cxx index 99c4b2578..9d3f1916e 100644 --- a/sc/source/ui/docshell/docsh4.cxx +++ b/sc/source/ui/docshell/docsh4.cxx @@ -297,7 +297,7 @@ void ScDocShell::Execute( SfxRequest& rReq ) } else { - DBG_ERROR( "arguments expected" ); + OSL_FAIL( "arguments expected" ); } } break; @@ -433,13 +433,13 @@ void ScDocShell::Execute( SfxRequest& rReq ) } else { - DBG_ERROR("UpdateChartArea: keine ViewShell oder falsche Daten"); + OSL_FAIL("UpdateChartArea: keine ViewShell oder falsche Daten"); } rReq.Done(); } else { - DBG_ERROR("SID_CHART_SOURCE ohne Argumente"); + OSL_FAIL("SID_CHART_SOURCE ohne Argumente"); } break; @@ -591,7 +591,7 @@ void ScDocShell::Execute( SfxRequest& rReq ) case SID_AUTO_STYLE: - DBG_ERROR("use ScAutoStyleHint instead of SID_AUTO_STYLE"); + OSL_FAIL("use ScAutoStyleHint instead of SID_AUTO_STYLE"); break; case SID_GET_COLORTABLE: @@ -1110,7 +1110,7 @@ void ScDocShell::Execute( SfxRequest& rReq ) } catch ( uno::Exception& ) { - DBG_ERROR( "SID_SHARE_DOC: caught exception\n" ); + OSL_FAIL( "SID_SHARE_DOC: caught exception\n" ); SC_MOD()->SetInSharedDocSaving( false ); try @@ -2672,7 +2672,7 @@ uno::Reference< frame::XModel > ScDocShell::LoadSharedDocument() } catch ( uno::Exception& ) { - DBG_ERROR( "ScDocShell::LoadSharedDocument(): caught exception\n" ); + OSL_FAIL( "ScDocShell::LoadSharedDocument(): caught exception\n" ); SC_MOD()->SetInSharedDocLoading( false ); try { diff --git a/sc/source/ui/docshell/docsh5.cxx b/sc/source/ui/docshell/docsh5.cxx index d4efb869c..1ef55718e 100644 --- a/sc/source/ui/docshell/docsh5.cxx +++ b/sc/source/ui/docshell/docsh5.cxx @@ -761,7 +761,7 @@ void ScDocShell::UseScenario( SCTAB nTab, const String& rName, BOOL bRecord ) } else { - DBG_ERROR( "UseScenario auf Szenario-Blatt" ); + OSL_FAIL( "UseScenario auf Szenario-Blatt" ); } } diff --git a/sc/source/ui/docshell/docsh8.cxx b/sc/source/ui/docshell/docsh8.cxx index 4628f371e..abbcb3d45 100644 --- a/sc/source/ui/docshell/docsh8.cxx +++ b/sc/source/ui/docshell/docsh8.cxx @@ -322,7 +322,7 @@ ULONG ScDocShell::DBaseImport( const String& rFullFileName, CharSet eCharSet, long nRowCount = 0; if ( nRowCount < 0 ) { - DBG_ERROR("can't get row count"); + OSL_FAIL("can't get row count"); nRowCount = 0; } @@ -477,7 +477,7 @@ ULONG ScDocShell::DBaseImport( const String& rFullFileName, CharSet eCharSet, } catch ( uno::Exception& ) { - DBG_ERROR("Unexpected exception in database"); + OSL_FAIL("Unexpected exception in database"); nErr = ERRCODE_IO_GENERAL; } @@ -1037,7 +1037,7 @@ ULONG ScDocShell::DBaseExport( const String& rFullFileName, CharSet eCharSet, BO break; default: - DBG_ERROR( "ScDocShell::DBaseExport: unknown FieldType" ); + OSL_FAIL( "ScDocShell::DBaseExport: unknown FieldType" ); if ( nErr == eERR_OK ) nErr = SCWARN_EXPORT_DATALOST; aDocument.GetValue( nDocCol, nDocRow, nTab, fVal ); @@ -1164,7 +1164,7 @@ ULONG ScDocShell::DBaseExport( const String& rFullFileName, CharSet eCharSet, BO } catch ( uno::Exception& ) { - DBG_ERROR("Unexpected exception in database"); + OSL_FAIL("Unexpected exception in database"); nErr = ERRCODE_IO_GENERAL; } diff --git a/sc/source/ui/docshell/externalrefmgr.cxx b/sc/source/ui/docshell/externalrefmgr.cxx index 75c1961a1..4d1a9db81 100644 --- a/sc/source/ui/docshell/externalrefmgr.cxx +++ b/sc/source/ui/docshell/externalrefmgr.cxx @@ -1304,7 +1304,7 @@ static FormulaToken* lcl_convertToToken(ScBaseCell* pCell) } } default: - DBG_ERROR("attempted to convert an unknown cell type."); + OSL_FAIL("attempted to convert an unknown cell type."); } return NULL; @@ -1408,7 +1408,7 @@ static ScTokenArray* lcl_convertToTokenArray(const ScDocument* pSrcDoc, ScRange& } break; default: - DBG_ERROR("attempted to convert an unknown cell type."); + OSL_FAIL("attempted to convert an unknown cell type."); } } } @@ -2456,7 +2456,7 @@ void ScExternalRefManager::addLinkListener(sal_uInt16 nFileId, LinkListener* pLi LinkListenerMap::value_type(nFileId, LinkListeners())); if (!r.second) { - DBG_ERROR("insertion of new link listener list failed"); + OSL_FAIL("insertion of new link listener list failed"); return; } diff --git a/sc/source/ui/docshell/servobj.cxx b/sc/source/ui/docshell/servobj.cxx index 8db782969..7a2373252 100644 --- a/sc/source/ui/docshell/servobj.cxx +++ b/sc/source/ui/docshell/servobj.cxx @@ -113,7 +113,7 @@ ScServerObject::ScServerObject( ScDocShell* pShell, const String& rItem ) : } else { - DBG_ERROR("ScServerObject: invalid item"); + OSL_FAIL("ScServerObject: invalid item"); } } diff --git a/sc/source/ui/drawfunc/drawsh4.cxx b/sc/source/ui/drawfunc/drawsh4.cxx index 863a079e7..cd80262db 100644 --- a/sc/source/ui/drawfunc/drawsh4.cxx +++ b/sc/source/ui/drawfunc/drawsh4.cxx @@ -103,7 +103,7 @@ void ScDrawShell::GetFormTextState(SfxItemSet& rSet) if ( pColorTable ) pDlg->SetColorTable( pColorTable ); else - { DBG_ERROR( "ColorList not found :-/" ); } + { OSL_FAIL( "ColorList not found :-/" ); } } } SfxItemSet aViewAttr(pDrView->GetModel()->GetItemPool()); diff --git a/sc/source/ui/drawfunc/drawsh5.cxx b/sc/source/ui/drawfunc/drawsh5.cxx index 8d474a425..603009975 100644 --- a/sc/source/ui/drawfunc/drawsh5.cxx +++ b/sc/source/ui/drawfunc/drawsh5.cxx @@ -252,7 +252,7 @@ void ScDrawShell::ExecuteHLink( SfxRequest& rReq ) } break; default: - DBG_ERROR("falscher Slot"); + OSL_FAIL("falscher Slot"); } } @@ -376,7 +376,7 @@ void ScDrawShell::ExecDrawFunc( SfxRequest& rReq ) break; case SID_PASTE: - DBG_ERROR( "SdrView::PasteClipboard not supported anymore" ); + OSL_FAIL( "SdrView::PasteClipboard not supported anymore" ); break; case SID_SELECTALL: diff --git a/sc/source/ui/drawfunc/drtxtob2.cxx b/sc/source/ui/drawfunc/drtxtob2.cxx index a700f9391..810244aaf 100644 --- a/sc/source/ui/drawfunc/drtxtob2.cxx +++ b/sc/source/ui/drawfunc/drtxtob2.cxx @@ -286,7 +286,7 @@ void ScDrawTextObjectBar::GetFormTextState(SfxItemSet& rSet) if ( pColorTable ) pDlg->SetColorTable( pColorTable ); else - { DBG_ERROR( "ColorList not found :-/" ); } + { OSL_FAIL( "ColorList not found :-/" ); } } } SfxItemSet aViewAttr(pDrView->GetModel()->GetItemPool()); diff --git a/sc/source/ui/drawfunc/fuconarc.cxx b/sc/source/ui/drawfunc/fuconarc.cxx index 11a49e61f..6192a9b5f 100644 --- a/sc/source/ui/drawfunc/fuconarc.cxx +++ b/sc/source/ui/drawfunc/fuconarc.cxx @@ -216,7 +216,7 @@ SdrObject* FuConstArc::CreateDefaultObject(const sal_uInt16 nID, const Rectangle } else { - DBG_ERROR("Object is NO circle object"); + OSL_FAIL("Object is NO circle object"); } } diff --git a/sc/source/ui/drawfunc/fuconpol.cxx b/sc/source/ui/drawfunc/fuconpol.cxx index 9dc549409..bfbb991be 100644 --- a/sc/source/ui/drawfunc/fuconpol.cxx +++ b/sc/source/ui/drawfunc/fuconpol.cxx @@ -344,7 +344,7 @@ SdrObject* FuConstPolygon::CreateDefaultObject(const sal_uInt16 nID, const Recta } else { - DBG_ERROR("Object is NO path object"); + OSL_FAIL("Object is NO path object"); } pObj->SetLogicRect(rRectangle); diff --git a/sc/source/ui/drawfunc/fuconrec.cxx b/sc/source/ui/drawfunc/fuconrec.cxx index a46e6d7ce..79e0d1cbf 100644 --- a/sc/source/ui/drawfunc/fuconrec.cxx +++ b/sc/source/ui/drawfunc/fuconrec.cxx @@ -253,7 +253,7 @@ SdrObject* FuConstRectangle::CreateDefaultObject(const sal_uInt16 nID, const Rec } else { - DBG_ERROR("Object is NO line object"); + OSL_FAIL("Object is NO line object"); } break; @@ -287,7 +287,7 @@ SdrObject* FuConstRectangle::CreateDefaultObject(const sal_uInt16 nID, const Rec } else { - DBG_ERROR("Object is NO caption object"); + OSL_FAIL("Object is NO caption object"); } break; diff --git a/sc/source/ui/drawfunc/fuins2.cxx b/sc/source/ui/drawfunc/fuins2.cxx index 51dfb4bfc..feb29d8bf 100644 --- a/sc/source/ui/drawfunc/fuins2.cxx +++ b/sc/source/ui/drawfunc/fuins2.cxx @@ -319,7 +319,7 @@ FuInsertOLE::FuInsertOLE(ScTabViewShell* pViewSh, Window* pWin, ScDrawView* pVie } else { - DBG_ERROR("Invalid URL!"); + OSL_FAIL("Invalid URL!"); //! error message //! can this happen??? } @@ -654,7 +654,7 @@ FuInsertChart::FuInsertChart(ScTabViewShell* pViewSh, Window* pWin, ScDrawView* } else { - DBG_ERROR( "Could not create new table :-/" ); + OSL_FAIL( "Could not create new table :-/" ); } } else if ( nToTable != pData->GetTabNo() ) diff --git a/sc/source/ui/drawfunc/futext.cxx b/sc/source/ui/drawfunc/futext.cxx index 2b96b0d33..ad5b132c4 100644 --- a/sc/source/ui/drawfunc/futext.cxx +++ b/sc/source/ui/drawfunc/futext.cxx @@ -803,7 +803,7 @@ SdrObject* FuText::CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rR } else { - DBG_ERROR("Object is NO text object"); + OSL_FAIL("Object is NO text object"); } } diff --git a/sc/source/ui/miscdlgs/conflictsdlg.cxx b/sc/source/ui/miscdlgs/conflictsdlg.cxx index 1606d8a4d..0287eb564 100644 --- a/sc/source/ui/miscdlgs/conflictsdlg.cxx +++ b/sc/source/ui/miscdlgs/conflictsdlg.cxx @@ -137,7 +137,7 @@ void ScConflictsListHelper::Transform_Impl( ScChangeActionList& rActionList, ScC else { aItr = rActionList.erase( aItr ); - DBG_ERROR( "ScConflictsListHelper::Transform_Impl: erased action from conflicts list!" ); + OSL_FAIL( "ScConflictsListHelper::Transform_Impl: erased action from conflicts list!" ); } } } diff --git a/sc/source/ui/miscdlgs/sharedocdlg.cxx b/sc/source/ui/miscdlgs/sharedocdlg.cxx index 7cf5ee1b8..e30cb25bd 100644 --- a/sc/source/ui/miscdlgs/sharedocdlg.cxx +++ b/sc/source/ui/miscdlgs/sharedocdlg.cxx @@ -186,7 +186,7 @@ void ScShareDocumentDlg::UpdateView() } catch ( uno::Exception& ) { - DBG_ERROR( "ScShareDocumentDlg::UpdateView(): caught exception\n" ); + OSL_FAIL( "ScShareDocumentDlg::UpdateView(): caught exception\n" ); maLbUsers.Clear(); maLbUsers.InsertEntry( maStrNoUserData, NULL ); } diff --git a/sc/source/ui/navipi/content.cxx b/sc/source/ui/navipi/content.cxx index 2ad87f4b4..dec8065aa 100644 --- a/sc/source/ui/navipi/content.cxx +++ b/sc/source/ui/navipi/content.cxx @@ -198,7 +198,7 @@ void ScContentTree::InsertContent( USHORT nType, const String& rValue ) { if (nType >= SC_CONTENT_COUNT) { - DBG_ERROR("ScContentTree::InsertContent mit falschem Typ"); + OSL_FAIL("ScContentTree::InsertContent mit falschem Typ"); return; } @@ -207,7 +207,7 @@ void ScContentTree::InsertContent( USHORT nType, const String& rValue ) InsertEntry( rValue, pParent ); else { - DBG_ERROR("InsertContent ohne Parent"); + OSL_FAIL("InsertContent ohne Parent"); } } @@ -741,7 +741,7 @@ bool ScContentTree::IsPartOfType( USHORT nContentType, USHORT nObjIdentifier ) bRet = ( nObjIdentifier != OBJ_GRAF && nObjIdentifier != OBJ_OLE2 ); // everything else break; default: - DBG_ERROR("unknown content type"); + OSL_FAIL("unknown content type"); } return bRet; } @@ -847,7 +847,7 @@ const ScAreaLink* ScContentTree::GetLink( ULONG nIndex ) } } - DBG_ERROR("Link nicht gefunden"); + OSL_FAIL("Link nicht gefunden"); return NULL; } @@ -903,7 +903,7 @@ ScAddress ScContentTree::GetNotePos( ULONG nIndex ) } } - DBG_ERROR("Notiz nicht gefunden"); + OSL_FAIL("Notiz nicht gefunden"); return ScAddress(); } @@ -1428,7 +1428,7 @@ void ScContentTree::SelectDoc(const String& rName) // rName wie im Menue/Listbo } else { - DBG_ERROR("SelectDoc: nicht gefunden"); + OSL_FAIL("SelectDoc: nicht gefunden"); } } diff --git a/sc/source/ui/optdlg/tpusrlst.cxx b/sc/source/ui/optdlg/tpusrlst.cxx index ca59ef528..c0513e50f 100644 --- a/sc/source/ui/optdlg/tpusrlst.cxx +++ b/sc/source/ui/optdlg/tpusrlst.cxx @@ -331,7 +331,7 @@ void ScTpUserLists::UpdateEntries( USHORT nList ) } else { - DBG_ERROR( "Invalid ListIndex :-/" ); + OSL_FAIL( "Invalid ListIndex :-/" ); } } @@ -395,7 +395,7 @@ void ScTpUserLists::AddNewList( const String& rEntriesStr ) if ( !pUserLists->Insert( new ScUserListData( theEntriesStr ) ) ) { - DBG_ERROR( "Entry could not be inserted :-/" ); + OSL_FAIL( "Entry could not be inserted :-/" ); } } diff --git a/sc/source/ui/pagedlg/tphf.cxx b/sc/source/ui/pagedlg/tphf.cxx index 42fe96ffb..a01af91d6 100644 --- a/sc/source/ui/pagedlg/tphf.cxx +++ b/sc/source/ui/pagedlg/tphf.cxx @@ -212,7 +212,7 @@ IMPL_LINK( ScHFPage, HFEditHdl, void*, EMPTYARG ) if ( !pViewSh ) { - DBG_ERROR( "Current ViewShell not found." ); + OSL_FAIL( "Current ViewShell not found." ); return 0; } diff --git a/sc/source/ui/styleui/styledlg.cxx b/sc/source/ui/styleui/styledlg.cxx index 8d686e9f0..6a3ef05ef 100644 --- a/sc/source/ui/styleui/styledlg.cxx +++ b/sc/source/ui/styleui/styledlg.cxx @@ -122,7 +122,7 @@ ScStyleDlg::ScStyleDlg( Window* pParent, break; default: - DBG_ERROR( "Family not supported" ); + OSL_FAIL( "Family not supported" ); } //-------------------------------------------------------------------- diff --git a/sc/source/ui/undo/undoblk.cxx b/sc/source/ui/undo/undoblk.cxx index 44508e86b..172f2a9e4 100644 --- a/sc/source/ui/undo/undoblk.cxx +++ b/sc/source/ui/undo/undoblk.cxx @@ -1630,7 +1630,7 @@ void ScUndoSelectionStyle::DoChange( const BOOL bUndo ) (ScStyleSheet*) pStlPool->Find( aStyleName, SFX_STYLE_FAMILY_PARA ); if (!pStyleSheet) { - DBG_ERROR("StyleSheet not found"); + OSL_FAIL("StyleSheet not found"); return; } pDoc->ApplySelectionStyle( *pStyleSheet, aMarkData ); @@ -1668,7 +1668,7 @@ void ScUndoSelectionStyle::Repeat(SfxRepeatTarget& rTarget) Find( aStyleName, SFX_STYLE_FAMILY_PARA ); if (!pStyleSheet) { - DBG_ERROR("StyleSheet not found"); + OSL_FAIL("StyleSheet not found"); return; } diff --git a/sc/source/ui/undo/undoblk3.cxx b/sc/source/ui/undo/undoblk3.cxx index d49b14045..c59e0bae6 100644 --- a/sc/source/ui/undo/undoblk3.cxx +++ b/sc/source/ui/undo/undoblk3.cxx @@ -1484,7 +1484,7 @@ void ScUndoConversion::SetChangeTrack() nStartChangeAction, nEndChangeAction ); else { - DBG_ERROR( "ScUndoConversion::SetChangeTrack: kein UndoDoc" ); + OSL_FAIL( "ScUndoConversion::SetChangeTrack: kein UndoDoc" ); nStartChangeAction = nEndChangeAction = 0; } } @@ -1532,7 +1532,7 @@ void ScUndoConversion::DoChange( ScDocument* pRefDoc, const ScAddress& rCursorPo } else { - DBG_ERROR("Kein Un-/RedoDoc bei Un-/RedoSpelling"); + OSL_FAIL("Kein Un-/RedoDoc bei Un-/RedoSpelling"); } } @@ -1817,7 +1817,7 @@ ScAreaLink* lcl_FindAreaLink( sfx2::LinkManager* pLinkManager, const String& rDo return (ScAreaLink*)pBase; } - DBG_ERROR("ScAreaLink nicht gefunden"); + OSL_FAIL("ScAreaLink nicht gefunden"); return NULL; } diff --git a/sc/source/ui/undo/undocell.cxx b/sc/source/ui/undo/undocell.cxx index 1ba5fd503..a33fa19fd 100644 --- a/sc/source/ui/undo/undocell.cxx +++ b/sc/source/ui/undo/undocell.cxx @@ -778,7 +778,7 @@ void ScUndoThesaurus::DoChange( BOOL bUndo, const String& rStr, } else { - DBG_ERROR("Nicht CELLTYPE_EDIT bei Un/RedoThesaurus"); + OSL_FAIL("Nicht CELLTYPE_EDIT bei Un/RedoThesaurus"); } } } @@ -1036,7 +1036,7 @@ void ScUndoDetective::Undo() pList->DeleteAndDestroy( nPos, 1 ); else { - DBG_ERROR("Detektiv-Eintrag in der Liste nicht gefunden"); + OSL_FAIL("Detektiv-Eintrag in der Liste nicht gefunden"); } } } diff --git a/sc/source/ui/undo/undodat.cxx b/sc/source/ui/undo/undodat.cxx index b0264e71f..56e9ec4ba 100644 --- a/sc/source/ui/undo/undodat.cxx +++ b/sc/source/ui/undo/undodat.cxx @@ -1720,7 +1720,7 @@ void ScUndoDataPilot::Undo() pDestObj->SetAlive(TRUE); if ( !pDoc->GetDPCollection()->InsertNewTable(pDestObj) ) { - DBG_ERROR("cannot insert DPObject"); + OSL_FAIL("cannot insert DPObject"); DELETEZ( pDestObj ); } } @@ -1897,7 +1897,7 @@ void ScUndoConsolidate::Undo() } else { - DBG_ERROR("alte DB-Daten nicht gefunden"); + OSL_FAIL("alte DB-Daten nicht gefunden"); } } } diff --git a/sc/source/ui/undo/undotab.cxx b/sc/source/ui/undo/undotab.cxx index 8a253a138..e638c801f 100644 --- a/sc/source/ui/undo/undotab.cxx +++ b/sc/source/ui/undo/undotab.cxx @@ -1053,7 +1053,7 @@ void ScUndoImportTab::Redo() { if (!pRedoDoc) { - DBG_ERROR("wo ist mein Redo-Document?"); + OSL_FAIL("wo ist mein Redo-Document?"); return; } @@ -1588,7 +1588,7 @@ SdrObject* ScUndoRenameObject::GetObject() } } } - DBG_ERROR("Object not found"); + OSL_FAIL("Object not found"); return NULL; } diff --git a/sc/source/ui/unoobj/afmtuno.cxx b/sc/source/ui/unoobj/afmtuno.cxx index 1b575945f..168f9d78a 100644 --- a/sc/source/ui/unoobj/afmtuno.cxx +++ b/sc/source/ui/unoobj/afmtuno.cxx @@ -283,7 +283,7 @@ void SAL_CALL ScAutoFormatsObj::insertByName( const rtl::OUString& aName, const else { delete pNew; - DBG_ERROR("AutoFormat konnte nicht eingefuegt werden"); + OSL_FAIL("AutoFormat konnte nicht eingefuegt werden"); throw uno::RuntimeException(); } } @@ -600,7 +600,7 @@ void SAL_CALL ScAutoFormatObj::setName( const rtl::OUString& aNewName ) else { delete pNew; - DBG_ERROR("AutoFormat konnte nicht eingefuegt werden"); + OSL_FAIL("AutoFormat konnte nicht eingefuegt werden"); nFormatIndex = 0; //! alter Index ist ungueltig } } diff --git a/sc/source/ui/unoobj/celllistsource.cxx b/sc/source/ui/unoobj/celllistsource.cxx index 44faacc0c..f7bb32af6 100644 --- a/sc/source/ui/unoobj/celllistsource.cxx +++ b/sc/source/ui/unoobj/celllistsource.cxx @@ -337,7 +337,7 @@ namespace calc } catch( const Exception& ) { - DBG_ERROR( "OCellListSource::notifyModified: caught a (non-runtime) exception!" ); + OSL_FAIL( "OCellListSource::notifyModified: caught a (non-runtime) exception!" ); } } @@ -414,7 +414,7 @@ namespace calc } catch( const Exception& ) { - DBG_ERROR( "OCellListSource::initialize: caught an exception while retrieving the cell object!" ); + OSL_FAIL( "OCellListSource::initialize: caught an exception while retrieving the cell object!" ); } diff --git a/sc/source/ui/unoobj/cellsuno.cxx b/sc/source/ui/unoobj/cellsuno.cxx index 1acf4b102..eb91107ec 100644 --- a/sc/source/ui/unoobj/cellsuno.cxx +++ b/sc/source/ui/unoobj/cellsuno.cxx @@ -1838,7 +1838,7 @@ beans::PropertyState ScCellRangesBase::GetOnePropertyState( USHORT nItemWhich, c eRet = beans::PropertyState_AMBIGUOUS_VALUE; else { - DBG_ERROR("unbekannter ItemState"); + OSL_FAIL("unbekannter ItemState"); } } } @@ -2521,7 +2521,7 @@ void SAL_CALL ScCellRangesBase::addPropertyChangeListener( const rtl::OUString& if ( aRanges.empty() ) throw uno::RuntimeException(); - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); } void SAL_CALL ScCellRangesBase::removePropertyChangeListener( const rtl::OUString& /* aPropertyName */, @@ -2533,7 +2533,7 @@ void SAL_CALL ScCellRangesBase::removePropertyChangeListener( const rtl::OUStrin if ( aRanges.empty() ) throw uno::RuntimeException(); - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); } void SAL_CALL ScCellRangesBase::addVetoableChangeListener( const rtl::OUString&, @@ -2541,7 +2541,7 @@ void SAL_CALL ScCellRangesBase::addVetoableChangeListener( const rtl::OUString&, throw(beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException) { - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); } void SAL_CALL ScCellRangesBase::removeVetoableChangeListener( const rtl::OUString&, @@ -2549,7 +2549,7 @@ void SAL_CALL ScCellRangesBase::removeVetoableChangeListener( const rtl::OUStrin throw(beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException) { - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); } // XMultiPropertySet @@ -2594,7 +2594,7 @@ void SAL_CALL ScCellRangesBase::setPropertyValues( const uno::Sequence< rtl::OUS } catch ( lang::IllegalArgumentException& ) { - DBG_ERROR("exception when setting cell style"); // not supposed to happen + OSL_FAIL("exception when setting cell style"); // not supposed to happen } } } @@ -2673,20 +2673,20 @@ void SAL_CALL ScCellRangesBase::addPropertiesChangeListener( const uno::Sequence const uno::Reference< beans::XPropertiesChangeListener >& /* xListener */ ) throw (uno::RuntimeException) { - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); } void SAL_CALL ScCellRangesBase::removePropertiesChangeListener( const uno::Reference< beans::XPropertiesChangeListener >& /* xListener */ ) throw (uno::RuntimeException) { - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); } void SAL_CALL ScCellRangesBase::firePropertiesChangeEvent( const uno::Sequence< rtl::OUString >& /* aPropertyNames */, const uno::Reference< beans::XPropertiesChangeListener >& /* xListener */ ) throw (uno::RuntimeException) { - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); } IMPL_LINK( ScCellRangesBase, ValueListenerHdl, SfxHint*, pHint ) @@ -2744,7 +2744,7 @@ uno::Sequence< beans::SetPropertyTolerantFailed > SAL_CALL ScCellRangesBase::set } catch ( lang::IllegalArgumentException& ) { - DBG_ERROR("exception when setting cell style"); // not supposed to happen + OSL_FAIL("exception when setting cell style"); // not supposed to happen } } } @@ -4980,7 +4980,7 @@ uno::Reference<table::XTableColumns> SAL_CALL ScCellRangeObj::getColumns() throw return new ScTableColumnsObj( pDocSh, aRange.aStart.Tab(), aRange.aStart.Col(), aRange.aEnd.Col() ); - DBG_ERROR("Dokument ungueltig"); + OSL_FAIL("Dokument ungueltig"); return NULL; } @@ -4992,7 +4992,7 @@ uno::Reference<table::XTableRows> SAL_CALL ScCellRangeObj::getRows() throw(uno:: return new ScTableRowsObj( pDocSh, aRange.aStart.Tab(), aRange.aStart.Row(), aRange.aEnd.Row() ); - DBG_ERROR("Dokument ungueltig"); + OSL_FAIL("Dokument ungueltig"); return NULL; } @@ -5016,7 +5016,7 @@ uno::Reference<sheet::XSpreadsheet> SAL_CALL ScCellRangeObj::getSpreadsheet() if (pDocSh) return new ScTableSheetObj( pDocSh, aRange.aStart.Tab() ); - DBG_ERROR("Dokument ungueltig"); + OSL_FAIL("Dokument ungueltig"); return NULL; } @@ -5755,7 +5755,7 @@ uno::Reference<sheet::XSheetFilterDescriptor> SAL_CALL ScCellRangeObj::createFil } } - DBG_ERROR("kein Dokument oder kein Bereich"); + OSL_FAIL("kein Dokument oder kein Bereich"); return NULL; } @@ -6496,7 +6496,7 @@ table::CellContentType SAL_CALL ScCellObj::getType() throw(uno::RuntimeException } else { - DBG_ERROR("keine DocShell"); //! Exception oder so? + OSL_FAIL("keine DocShell"); //! Exception oder so? } return eRet; @@ -6531,7 +6531,7 @@ sal_Int32 SAL_CALL ScCellObj::getError() throw(uno::RuntimeException) } else { - DBG_ERROR("keine DocShell"); //! Exception oder so? + OSL_FAIL("keine DocShell"); //! Exception oder so? } return nError; @@ -6596,7 +6596,7 @@ uno::Reference<sheet::XSheetAnnotation> SAL_CALL ScCellObj::getAnnotation() if ( pDocSh ) return new ScAnnotationObj( pDocSh, aCellPos ); - DBG_ERROR("getAnnotation ohne DocShell"); + OSL_FAIL("getAnnotation ohne DocShell"); return NULL; } @@ -6922,7 +6922,7 @@ uno::Reference<table::XTableCharts> SAL_CALL ScTableSheetObj::getCharts() throw( if ( pDocSh ) return new ScChartsObj( pDocSh, GetTab_Impl() ); - DBG_ERROR("kein Dokument"); + OSL_FAIL("kein Dokument"); return NULL; } @@ -6934,7 +6934,7 @@ uno::Reference<sheet::XDataPilotTables> SAL_CALL ScTableSheetObj::getDataPilotTa if ( pDocSh ) return new ScDataPilotTablesObj( pDocSh, GetTab_Impl() ); - DBG_ERROR("kein Dokument"); + OSL_FAIL("kein Dokument"); return NULL; } @@ -6946,7 +6946,7 @@ uno::Reference<sheet::XScenarios> SAL_CALL ScTableSheetObj::getScenarios() throw if ( pDocSh ) return new ScScenariosObj( pDocSh, GetTab_Impl() ); - DBG_ERROR("kein Dokument"); + OSL_FAIL("kein Dokument"); return NULL; } @@ -6959,7 +6959,7 @@ uno::Reference<sheet::XSheetAnnotations> SAL_CALL ScTableSheetObj::getAnnotation if ( pDocSh ) return new ScAnnotationsObj( pDocSh, GetTab_Impl() ); - DBG_ERROR("kein Dokument"); + OSL_FAIL("kein Dokument"); return NULL; } @@ -7198,7 +7198,7 @@ void SAL_CALL ScTableSheetObj::insertCells( const table::CellRangeAddress& rRang case sheet::CellInsertMode_ROWS: eCmd = INS_INSROWS; break; case sheet::CellInsertMode_COLUMNS: eCmd = INS_INSCOLS; break; default: - DBG_ERROR("insertCells: falscher Mode"); + OSL_FAIL("insertCells: falscher Mode"); bDo = FALSE; } @@ -7230,7 +7230,7 @@ void SAL_CALL ScTableSheetObj::removeRange( const table::CellRangeAddress& rRang case sheet::CellDeleteMode_ROWS: eCmd = DEL_DELROWS; break; case sheet::CellDeleteMode_COLUMNS: eCmd = DEL_DELCOLS; break; default: - DBG_ERROR("deleteCells: falscher Mode"); + OSL_FAIL("deleteCells: falscher Mode"); bDo = FALSE; } @@ -7923,7 +7923,7 @@ sal_Bool SAL_CALL ScTableSheetObj::isProtected() throw(uno::RuntimeException) if ( pDocSh ) return pDocSh->GetDocument()->IsTabProtected( GetTab_Impl() ); - DBG_ERROR("keine DocShell"); //! Exception oder so? + OSL_FAIL("keine DocShell"); //! Exception oder so? return FALSE; } diff --git a/sc/source/ui/unoobj/cellvaluebinding.cxx b/sc/source/ui/unoobj/cellvaluebinding.cxx index e12baee56..c0516b33c 100644 --- a/sc/source/ui/unoobj/cellvaluebinding.cxx +++ b/sc/source/ui/unoobj/cellvaluebinding.cxx @@ -307,7 +307,7 @@ namespace calc break; default: - DBG_ERROR( "OCellValueBinding::getValue: unreachable code!" ); + OSL_FAIL( "OCellValueBinding::getValue: unreachable code!" ); // a type other than double and string should never have survived the checkValueType // above } @@ -393,7 +393,7 @@ namespace calc break; default: - DBG_ERROR( "OCellValueBinding::setValue: unreachable code!" ); + OSL_FAIL( "OCellValueBinding::setValue: unreachable code!" ); // a type other than double and string should never have survived the checkValueType // above } @@ -546,7 +546,7 @@ namespace calc } catch( const Exception& ) { - DBG_ERROR( "OCellValueBinding::notifyModified: caught a (non-runtime) exception!" ); + OSL_FAIL( "OCellValueBinding::notifyModified: caught a (non-runtime) exception!" ); } } } @@ -629,7 +629,7 @@ namespace calc } catch( const Exception& ) { - DBG_ERROR( "OCellValueBinding::initialize: caught an exception while retrieving the cell object!" ); + OSL_FAIL( "OCellValueBinding::initialize: caught an exception while retrieving the cell object!" ); } if ( !m_xCell.is() ) diff --git a/sc/source/ui/unoobj/chart2uno.cxx b/sc/source/ui/unoobj/chart2uno.cxx index 573e8ce30..5dd95175d 100644 --- a/sc/source/ui/unoobj/chart2uno.cxx +++ b/sc/source/ui/unoobj/chart2uno.cxx @@ -2425,7 +2425,7 @@ void ScChart2DataSequence::BuildDataCache() if (!m_pTokens.get()) { - DBG_ERROR("m_pTokens == NULL! Something is wrong."); + OSL_FAIL("m_pTokens == NULL! Something is wrong."); return; } @@ -2576,7 +2576,7 @@ sal_Int32 ScChart2DataSequence::FillCacheFromExternalRef(const ScTokenRef& pToke if (p->GetType() != svMatrix) { - DBG_ERROR("Cached array is not a matrix token."); + OSL_FAIL("Cached array is not a matrix token."); continue; } @@ -2678,7 +2678,7 @@ void ScChart2DataSequence::CopyData(const ScChart2DataSequence& r) { if (!m_pDocument) { - DBG_ERROR("document instance is NULL!?"); + OSL_FAIL("document instance is NULL!?"); return; } @@ -2802,7 +2802,7 @@ void ScChart2DataSequence::Notify( SfxBroadcaster& /*rBC*/, const SfxHint& rHint if (!m_pRangeIndices.get() || m_pRangeIndices->empty()) { - DBG_ERROR(" faulty range indices"); + OSL_FAIL(" faulty range indices"); break; } @@ -2811,7 +2811,7 @@ void ScChart2DataSequence::Notify( SfxBroadcaster& /*rBC*/, const SfxHint& rHint size_t nCount = rRanges.size(); if (nCount != m_pRangeIndices->size()) { - DBG_ERROR("range count and range index count differ."); + OSL_FAIL("range count and range index count differ."); break; } diff --git a/sc/source/ui/unoobj/chartuno.cxx b/sc/source/ui/unoobj/chartuno.cxx index cb08e77b4..13278daea 100644 --- a/sc/source/ui/unoobj/chartuno.cxx +++ b/sc/source/ui/unoobj/chartuno.cxx @@ -735,7 +735,7 @@ uno::Sequence<table::CellRangeAddress> SAL_CALL ScChartObj::getRanges() throw(un return aSeq; } - DBG_ERROR("ScChartObj::getRanges: keine Ranges"); + OSL_FAIL("ScChartObj::getRanges: keine Ranges"); return uno::Sequence<table::CellRangeAddress>(); } diff --git a/sc/source/ui/unoobj/cursuno.cxx b/sc/source/ui/unoobj/cursuno.cxx index 0aa46e8db..db3d52cc8 100644 --- a/sc/source/ui/unoobj/cursuno.cxx +++ b/sc/source/ui/unoobj/cursuno.cxx @@ -168,7 +168,7 @@ void SAL_CALL ScCellCursorObj::collapseToCurrentArray() throw(uno::RuntimeExcept // about a exception /*if (!bFound) { - DBG_ERROR("keine Matrix"); + OSL_FAIL("keine Matrix"); //! Exception, oder was? }*/ } @@ -223,7 +223,7 @@ void SAL_CALL ScCellCursorObj::collapseToSize( sal_Int32 nColumns, sal_Int32 nRo SolarMutexGuard aGuard; if ( nColumns <= 0 || nRows <= 0 ) { - DBG_ERROR("leerer Range geht nicht"); + OSL_FAIL("leerer Range geht nicht"); //! und dann? } else diff --git a/sc/source/ui/unoobj/dapiuno.cxx b/sc/source/ui/unoobj/dapiuno.cxx index 2e466a1d7..5cbbb472f 100644 --- a/sc/source/ui/unoobj/dapiuno.cxx +++ b/sc/source/ui/unoobj/dapiuno.cxx @@ -1443,7 +1443,7 @@ void ScDataPilotDescriptor::SetDPObject( ScDPObject* pDPObject ) { delete mpDPObject; mpDPObject = pDPObject; - DBG_ERROR("replace DPObject should not happen"); + OSL_FAIL("replace DPObject should not happen"); } } diff --git a/sc/source/ui/unoobj/datauno.cxx b/sc/source/ui/unoobj/datauno.cxx index 5f15c24c4..082cd4947 100644 --- a/sc/source/ui/unoobj/datauno.cxx +++ b/sc/source/ui/unoobj/datauno.cxx @@ -168,7 +168,7 @@ ScSubTotalFunc ScDataUnoConversion::GeneralToSubTotal( sheet::GeneralFunction eS case sheet::GeneralFunction_VARP: eSubTotal = SUBTOTAL_FUNC_VARP; break; case sheet::GeneralFunction_AUTO: default: - DBG_ERROR("GeneralToSubTotal: falscher enum"); + OSL_FAIL("GeneralToSubTotal: falscher enum"); eSubTotal = SUBTOTAL_FUNC_NONE; } return eSubTotal; @@ -192,7 +192,7 @@ sheet::GeneralFunction ScDataUnoConversion::SubTotalToGeneral( ScSubTotalFunc eS case SUBTOTAL_FUNC_VAR: eGeneral = sheet::GeneralFunction_VAR; break; case SUBTOTAL_FUNC_VARP: eGeneral = sheet::GeneralFunction_VARP; break; default: - DBG_ERROR("SubTotalToGeneral: falscher enum"); + OSL_FAIL("SubTotalToGeneral: falscher enum"); eGeneral = sheet::GeneralFunction_NONE; break; } @@ -300,7 +300,7 @@ void ScImportDescriptor::FillImportParam( ScImportParam& rParam, const uno::Sequ rParam.nType = ScDbQuery; break; default: - DBG_ERROR("falscher Mode"); + OSL_FAIL("falscher Mode"); rParam.bImport = FALSE; } } @@ -421,7 +421,7 @@ void ScSortDescriptor::FillSortParam( ScSortParam& rParam, const uno::Sequence<b INT32 i; if ( nCount > MAXSORT ) { - DBG_ERROR("Zu viele Sortierfelder"); + OSL_FAIL("Zu viele Sortierfelder"); nCount = MAXSORT; } const util::SortField* pFieldArray = aSeq.getConstArray(); @@ -442,7 +442,7 @@ void ScSortDescriptor::FillSortParam( ScSortParam& rParam, const uno::Sequence<b INT32 i; if ( nCount > MAXSORT ) { - DBG_ERROR("Zu viele Sortierfelder"); + OSL_FAIL("Zu viele Sortierfelder"); nCount = MAXSORT; } const table::TableSortField* pFieldArray = aNewSeq.getConstArray(); @@ -609,12 +609,12 @@ ScSubTotalDescriptorBase::~ScSubTotalDescriptorBase() void ScSubTotalDescriptorBase::GetData( ScSubTotalParam& /* rParam */ ) const { - DBG_ERROR("ScSubTotalDescriptorBase::GetData soll nicht gerufen werden"); + OSL_FAIL("ScSubTotalDescriptorBase::GetData soll nicht gerufen werden"); } void ScSubTotalDescriptorBase::PutData( const ScSubTotalParam& /* rParam */ ) { - DBG_ERROR("ScSubTotalDescriptorBase::PutData soll nicht gerufen werden"); + OSL_FAIL("ScSubTotalDescriptorBase::PutData soll nicht gerufen werden"); } // XSubTotalDesctiptor @@ -1153,7 +1153,7 @@ uno::Sequence<sheet::TableFilterField> SAL_CALL ScFilterDescriptorBase::getFilte case SC_TOPPERC: aField.Operator = sheet::FilterOperator_TOP_PERCENT; break; case SC_BOTPERC: aField.Operator = sheet::FilterOperator_BOTTOM_PERCENT; break; default: - DBG_ERROR("Falscher Filter-enum"); + OSL_FAIL("Falscher Filter-enum"); aField.Operator = sheet::FilterOperator_EMPTY; } pAry[i] = aField; @@ -1227,7 +1227,7 @@ throw(uno::RuntimeException) case SC_ENDS_WITH: aField.Operator = sheet::FilterOperator2::ENDS_WITH; break; case SC_DOES_NOT_END_WITH: aField.Operator = sheet::FilterOperator2::DOES_NOT_END_WITH; break; default: - DBG_ERROR("Falscher Filter-enum"); + OSL_FAIL("Falscher Filter-enum"); aField.Operator = sheet::FilterOperator2::EMPTY; } pAry[i] = aField; @@ -1297,7 +1297,7 @@ void SAL_CALL ScFilterDescriptorBase::setFilterFields( } break; default: - DBG_ERROR("Falscher Query-enum"); + OSL_FAIL("Falscher Query-enum"); rEntry.eOp = SC_EQUAL; } } @@ -1377,7 +1377,7 @@ void SAL_CALL ScFilterDescriptorBase::setFilterFields2( } break; default: - DBG_ERROR("Falscher Query-enum"); + OSL_FAIL("Falscher Query-enum"); rEntry.eOp = SC_EQUAL; } } diff --git a/sc/source/ui/unoobj/docuno.cxx b/sc/source/ui/unoobj/docuno.cxx index 6de6f5d5c..3e0521986 100644 --- a/sc/source/ui/unoobj/docuno.cxx +++ b/sc/source/ui/unoobj/docuno.cxx @@ -1343,7 +1343,7 @@ void SAL_CALL ScModelObj::calculate() throw(uno::RuntimeException) pDocShell->DoRecalc(TRUE); else { - DBG_ERROR("keine DocShell"); //! Exception oder so? + OSL_FAIL("keine DocShell"); //! Exception oder so? } } @@ -1354,7 +1354,7 @@ void SAL_CALL ScModelObj::calculateAll() throw(uno::RuntimeException) pDocShell->DoHardRecalc(TRUE); else { - DBG_ERROR("keine DocShell"); //! Exception oder so? + OSL_FAIL("keine DocShell"); //! Exception oder so? } } @@ -1364,7 +1364,7 @@ sal_Bool SAL_CALL ScModelObj::isAutomaticCalculationEnabled() throw(uno::Runtime if (pDocShell) return pDocShell->GetDocument()->GetAutoCalc(); - DBG_ERROR("keine DocShell"); //! Exception oder so? + OSL_FAIL("keine DocShell"); //! Exception oder so? return FALSE; } @@ -1383,7 +1383,7 @@ void SAL_CALL ScModelObj::enableAutomaticCalculation( sal_Bool bEnabled ) } else { - DBG_ERROR("keine DocShell"); //! Exception oder so? + OSL_FAIL("keine DocShell"); //! Exception oder so? } } @@ -1423,7 +1423,7 @@ sal_Bool SAL_CALL ScModelObj::isProtected() throw(uno::RuntimeException) if (pDocShell) return pDocShell->GetDocument()->IsDocProtected(); - DBG_ERROR("keine DocShell"); //! Exception oder so? + OSL_FAIL("keine DocShell"); //! Exception oder so? return FALSE; } @@ -1435,7 +1435,7 @@ uno::Reference<drawing::XDrawPages> SAL_CALL ScModelObj::getDrawPages() throw(un if (pDocShell) return new ScDrawPagesObj(pDocShell); - DBG_ERROR("keine DocShell"); //! Exception oder so? + OSL_FAIL("keine DocShell"); //! Exception oder so? return NULL; } diff --git a/sc/source/ui/unoobj/fielduno.cxx b/sc/source/ui/unoobj/fielduno.cxx index 894880d6b..83526c0f4 100644 --- a/sc/source/ui/unoobj/fielduno.cxx +++ b/sc/source/ui/unoobj/fielduno.cxx @@ -352,14 +352,14 @@ void SAL_CALL ScCellFieldsObj::addContainerListener( const uno::Reference<container::XContainerListener>& /* xListener */ ) throw(uno::RuntimeException) { - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); } void SAL_CALL ScCellFieldsObj::removeContainerListener( const uno::Reference<container::XContainerListener>& /* xListener */ ) throw(uno::RuntimeException) { - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); } // XRefreshable @@ -994,14 +994,14 @@ void SAL_CALL ScHeaderFieldsObj::addContainerListener( const uno::Reference<container::XContainerListener>& /* xListener */ ) throw(uno::RuntimeException) { - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); } void SAL_CALL ScHeaderFieldsObj::removeContainerListener( const uno::Reference<container::XContainerListener>& /* xListener */ ) throw(uno::RuntimeException) { - DBG_ERROR("not implemented"); + OSL_FAIL("not implemented"); } // XRefreshable @@ -1034,6 +1034,10 @@ void SAL_CALL ScHeaderFieldsObj::refresh( ) } catch(uno::RuntimeException&) { +<<<<<<< HEAD +======= +// OSL_FAIL("a object is gone without to remove from Broadcaster"); +>>>>>>> Move DBG_ERROR to OSL_FAIL ++pInterfaces; ++i; } diff --git a/sc/source/ui/unoobj/fmtuno.cxx b/sc/source/ui/unoobj/fmtuno.cxx index 3250d6754..c3c534d0f 100644 --- a/sc/source/ui/unoobj/fmtuno.cxx +++ b/sc/source/ui/unoobj/fmtuno.cxx @@ -382,7 +382,7 @@ void SAL_CALL ScTableConditionalFormat::addNew( } else { - DBG_ERROR("falsche Property"); + OSL_FAIL("falsche Property"); //! Exception... } } diff --git a/sc/source/ui/unoobj/scdetect.cxx b/sc/source/ui/unoobj/scdetect.cxx index 07db5d5f7..5890b11a5 100644 --- a/sc/source/ui/unoobj/scdetect.cxx +++ b/sc/source/ui/unoobj/scdetect.cxx @@ -692,7 +692,7 @@ static BOOL lcl_MayBeDBase( SvStream& rStream ) } else { // Tabellenfehler - DBG_ERROR( "-ScApplication::DetectFilter(): Fehler in Mustertabelle"); + OSL_FAIL( "-ScApplication::DetectFilter(): Fehler in Mustertabelle"); } pSearch++; diff --git a/sc/source/ui/unoobj/servuno.cxx b/sc/source/ui/unoobj/servuno.cxx index 537d42b4f..78b8f6013 100644 --- a/sc/source/ui/unoobj/servuno.cxx +++ b/sc/source/ui/unoobj/servuno.cxx @@ -393,7 +393,7 @@ sal_uInt16 ScServiceProvider::GetProviderType(const String& rServiceName) DBG_ASSERT( aOldNames[i], "ScServiceProvider::GetProviderType: no oldname => crash"); if (rServiceName.EqualsAscii( aOldNames[i] )) { - DBG_ERROR("old service name used"); + OSL_FAIL("old service name used"); return i; } } diff --git a/sc/source/ui/unoobj/shapeuno.cxx b/sc/source/ui/unoobj/shapeuno.cxx index f17b60977..73f039def 100644 --- a/sc/source/ui/unoobj/shapeuno.cxx +++ b/sc/source/ui/unoobj/shapeuno.cxx @@ -577,7 +577,7 @@ void SAL_CALL ScShapeObj::setPropertyValue( } else { - DBG_ERROR("unknown anchor type"); + OSL_FAIL("unknown anchor type"); } } } @@ -646,7 +646,7 @@ void SAL_CALL ScShapeObj::setPropertyValue( } else { - DBG_ERROR("unknown anchor type"); + OSL_FAIL("unknown anchor type"); } } } @@ -1126,7 +1126,7 @@ void lcl_CopyOneProperty( beans::XPropertySet& rDest, beans::XPropertySet& rSour } catch (uno::Exception&) { - DBG_ERROR("Exception in text field"); + OSL_FAIL("Exception in text field"); } } @@ -1357,7 +1357,7 @@ uno::Sequence<sal_Int8> SAL_CALL ScShapeObj::getImplementationId() } if( NULL == pImplementationId ) { - DBG_ERROR( "Could not create an implementation id for a ScXShape!" ); + OSL_FAIL( "Could not create an implementation id for a ScXShape!" ); return uno::Sequence< sal_Int8 > (); } else diff --git a/sc/source/ui/unoobj/styleuno.cxx b/sc/source/ui/unoobj/styleuno.cxx index 9bfff03f6..7fa436f1f 100644 --- a/sc/source/ui/unoobj/styleuno.cxx +++ b/sc/source/ui/unoobj/styleuno.cxx @@ -468,7 +468,7 @@ const ScDisplayNameMap* lcl_GetStyleNameMap( UINT16 nType ) } return aPageMap; } - DBG_ERROR("invalid family"); + OSL_FAIL("invalid family"); return NULL; } @@ -590,7 +590,7 @@ ScStyleFamilyObj*ScStyleFamiliesObj::GetObjectByType_Impl(UINT16 nType) const else if ( nType == SFX_STYLE_FAMILY_PAGE ) return new ScStyleFamilyObj( pDocShell, SFX_STYLE_FAMILY_PAGE ); } - DBG_ERROR("getStyleFamilyByType: keine DocShell oder falscher Typ"); + OSL_FAIL("getStyleFamilyByType: keine DocShell oder falscher Typ"); return NULL; } @@ -1377,7 +1377,7 @@ beans::PropertyState SAL_CALL ScStyleObj::getPropertyState( const rtl::OUString& eRet = beans::PropertyState_AMBIGUOUS_VALUE; // kann eigentlich nicht sein... else { - DBG_ERROR("unbekannter ItemState"); + OSL_FAIL("unbekannter ItemState"); } } } diff --git a/sc/source/ui/unoobj/targuno.cxx b/sc/source/ui/unoobj/targuno.cxx index d98a1c4eb..bdfacb325 100644 --- a/sc/source/ui/unoobj/targuno.cxx +++ b/sc/source/ui/unoobj/targuno.cxx @@ -193,7 +193,7 @@ uno::Reference< container::XNameAccess > SAL_CALL ScLinkTargetTypeObj::getLinks xCollection.set(new ScDatabaseRangesObj(pDocShell)); break; default: - DBG_ERROR("invalid type"); + OSL_FAIL("invalid type"); } } diff --git a/sc/source/ui/unoobj/viewuno.cxx b/sc/source/ui/unoobj/viewuno.cxx index 96299c80a..43c54c15a 100644 --- a/sc/source/ui/unoobj/viewuno.cxx +++ b/sc/source/ui/unoobj/viewuno.cxx @@ -213,7 +213,7 @@ sal_Int32 SAL_CALL ScViewPaneBase::getFirstVisibleColumn() throw(uno::RuntimeExc return pViewData->GetPosX( eWhichH ); } - DBG_ERROR("keine View ?!?"); //! Exception? + OSL_FAIL("keine View ?!?"); //! Exception? return 0; } @@ -247,7 +247,7 @@ sal_Int32 SAL_CALL ScViewPaneBase::getFirstVisibleRow() throw(uno::RuntimeExcept return pViewData->GetPosY( eWhichV ); } - DBG_ERROR("keine View ?!?"); //! Exception? + OSL_FAIL("keine View ?!?"); //! Exception? return 0; } diff --git a/sc/source/ui/view/cellsh.cxx b/sc/source/ui/view/cellsh.cxx index 44af8ad53..34f34c306 100644 --- a/sc/source/ui/view/cellsh.cxx +++ b/sc/source/ui/view/cellsh.cxx @@ -868,7 +868,7 @@ void ScCellShell::GetState(SfxItemSet &rSet) break; case FID_INPUTLINE_STATUS: - DBG_ERROR( "Old update method. Use ScTabViewShell::UpdateInputHandler()." ); + OSL_FAIL( "Old update method. Use ScTabViewShell::UpdateInputHandler()." ); break; case SID_SCENARIOS: // Szenarios: diff --git a/sc/source/ui/view/cellsh1.cxx b/sc/source/ui/view/cellsh1.cxx index 8b47d837c..eeedb6a6e 100644 --- a/sc/source/ui/view/cellsh1.cxx +++ b/sc/source/ui/view/cellsh1.cxx @@ -648,7 +648,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq ) const SvNumberformat* pPrivEntry = pFormatter->GetEntry( nPrivFormat ); if (!pPrivEntry) { - DBG_ERROR("Zahlformat nicht gefunden !!!"); + OSL_FAIL("Zahlformat nicht gefunden !!!"); } else { @@ -921,7 +921,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq ) } else { - DBG_ERROR( "Richtung nicht eindeutig fuer AutoFill" ); + OSL_FAIL( "Richtung nicht eindeutig fuer AutoFill" ); } } } @@ -1977,7 +1977,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq ) } else { - DBG_ERROR("NULL"); + OSL_FAIL("NULL"); } } } @@ -2073,7 +2073,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq ) // default: - DBG_ERROR("falscher Slot bei ExecuteEdit"); + OSL_FAIL("falscher Slot bei ExecuteEdit"); break; } } diff --git a/sc/source/ui/view/cellsh2.cxx b/sc/source/ui/view/cellsh2.cxx index 6773f0216..05ce4150d 100644 --- a/sc/source/ui/view/cellsh2.cxx +++ b/sc/source/ui/view/cellsh2.cxx @@ -325,7 +325,7 @@ void ScCellShell::ExecuteDB( SfxRequest& rReq ) case SID_SBA_BRW_INSERT: { - DBG_ERROR( "Deprecated Slot" ); + OSL_FAIL( "Deprecated Slot" ); } break; @@ -615,7 +615,7 @@ void ScCellShell::ExecuteDB( SfxRequest& rReq ) const SfxItemSet* pArgs = rReq.GetArgs(); if ( pArgs ) { - DBG_ERROR("SID_FILTER with arguments?"); + OSL_FAIL("SID_FILTER with arguments?"); pTabViewShell->Query( ((const ScQueryItem&) pArgs->Get( SCITEM_QUERYDATA )).GetQueryData(), NULL, TRUE ); rReq.Done(); @@ -636,7 +636,7 @@ void ScCellShell::ExecuteDB( SfxRequest& rReq ) const SfxItemSet* pArgs = rReq.GetArgs(); if ( pArgs ) { - DBG_ERROR("SID_SPECIAL_FILTER with arguments?"); + OSL_FAIL("SID_SPECIAL_FILTER with arguments?"); pTabViewShell->Query( ((const ScQueryItem&) pArgs->Get( SCITEM_QUERYDATA )).GetQueryData(), NULL, TRUE ); rReq.Done(); @@ -770,7 +770,7 @@ void ScCellShell::ExecuteDB( SfxRequest& rReq ) } else { - DBG_ERROR("NULL"); + OSL_FAIL("NULL"); } } else @@ -838,7 +838,7 @@ void ScCellShell::ExecuteDB( SfxRequest& rReq ) const SfxItemSet* pArgs = rReq.GetArgs(); if ( pArgs ) { - DBG_ERROR("spaeter..."); + OSL_FAIL("spaeter..."); } else { diff --git a/sc/source/ui/view/cellsh3.cxx b/sc/source/ui/view/cellsh3.cxx index 316e9de5e..9c35882f6 100644 --- a/sc/source/ui/view/cellsh3.cxx +++ b/sc/source/ui/view/cellsh3.cxx @@ -900,7 +900,7 @@ void ScCellShell::Execute( SfxRequest& rReq ) // ---------------------------------------------------------------- case FID_INPUTLINE_STATUS: - DBG_ERROR("Execute von InputLine-Status"); + OSL_FAIL("Execute von InputLine-Status"); break; case SID_STATUS_DOCPOS: @@ -911,11 +911,11 @@ void ScCellShell::Execute( SfxRequest& rReq ) case SID_MARKAREA: // called from Basic at the hidden view to select a range in the visible view - DBG_ERROR("old slot SID_MARKAREA"); + OSL_FAIL("old slot SID_MARKAREA"); break; default: - DBG_ERROR("Unbekannter Slot bei ScCellShell::Execute"); + OSL_FAIL("Unbekannter Slot bei ScCellShell::Execute"); break; } } diff --git a/sc/source/ui/view/cellsh4.cxx b/sc/source/ui/view/cellsh4.cxx index 894bee330..73ab4f11c 100644 --- a/sc/source/ui/view/cellsh4.cxx +++ b/sc/source/ui/view/cellsh4.cxx @@ -200,7 +200,7 @@ void ScCellShell::ExecuteCursor( SfxRequest& rReq ) break; default: - DBG_ERROR("Unbekannte Message bei ViewShell (Cursor)"); + OSL_FAIL("Unbekannte Message bei ViewShell (Cursor)"); return; } @@ -370,7 +370,7 @@ void ScCellShell::ExecuteMove( SfxRequest& rReq ) break; default: - DBG_ERROR("Unbekannte Message bei ViewShell (Cursor)"); + OSL_FAIL("Unbekannte Message bei ViewShell (Cursor)"); return; } @@ -387,7 +387,7 @@ void ScCellShell::ExecutePageSel( SfxRequest& rReq ) case SID_CURSORTOPOFFILE_SEL: rReq.SetSlot( SID_CURSORTOPOFFILE ); break; case SID_CURSORENDOFFILE_SEL: rReq.SetSlot( SID_CURSORENDOFFILE ); break; default: - DBG_ERROR("Unbekannte Message bei ViewShell (ExecutePageSel)"); + OSL_FAIL("Unbekannte Message bei ViewShell (ExecutePageSel)"); return; } rReq.AppendItem( SfxBoolItem(FN_PARAM_2, TRUE) ); @@ -442,7 +442,7 @@ void ScCellShell::ExecutePage( SfxRequest& rReq ) break; default: - DBG_ERROR("Unbekannte Message bei ViewShell (ExecutePage)"); + OSL_FAIL("Unbekannte Message bei ViewShell (ExecutePage)"); return; } diff --git a/sc/source/ui/view/dbfunc.cxx b/sc/source/ui/view/dbfunc.cxx index b959cf529..7eff9d789 100644 --- a/sc/source/ui/view/dbfunc.cxx +++ b/sc/source/ui/view/dbfunc.cxx @@ -262,7 +262,7 @@ void ScDBFunc::UISort( const ScSortParam& rSortParam, BOOL bRecord ) rSortParam.nCol2, rSortParam.nRow2 ); if (!pDBData) { - DBG_ERROR( "Sort: keine DBData" ); + OSL_FAIL( "Sort: keine DBData" ); return; } diff --git a/sc/source/ui/view/dbfunc3.cxx b/sc/source/ui/view/dbfunc3.cxx index efe0f989c..d717ee028 100644 --- a/sc/source/ui/view/dbfunc3.cxx +++ b/sc/source/ui/view/dbfunc3.cxx @@ -413,7 +413,7 @@ void ScDBFunc::DoSubTotals( const ScSubTotalParam& rParam, BOOL bRecord, rParam.nCol2, rParam.nRow2 ); if (!pDBData) { - DBG_ERROR( "SubTotals: keine DBData" ); + OSL_FAIL( "SubTotals: keine DBData" ); return; } @@ -1004,7 +1004,7 @@ void ScDBFunc::DateGroupDataPilot( const ScDPNumGroupInfo& rInfo, sal_Int32 nPar if ( pExistingGroup && pExistingGroup->GetGroupDimName() == aGroupDimName ) { // still get the same group dimension? - DBG_ERROR("couldn't remove group dimension"); + OSL_FAIL("couldn't remove group dimension"); pExistingGroup = NULL; // avoid endless loop } } diff --git a/sc/source/ui/view/drawview.cxx b/sc/source/ui/view/drawview.cxx index 96e82981c..fbb95bbf6 100644 --- a/sc/source/ui/view/drawview.cxx +++ b/sc/source/ui/view/drawview.cxx @@ -285,7 +285,7 @@ void ScDrawView::UpdateWorkArea() } else { - DBG_ERROR("Page nicht gefunden"); + OSL_FAIL("Page nicht gefunden"); } } @@ -488,7 +488,7 @@ void ScDrawView::MarkListHasChanged() pViewSh->SetVerbs( xObj->getSupportedVerbs() ); else { - DBG_ERROR("SdrOle2Obj ohne ObjRef"); + OSL_FAIL("SdrOle2Obj ohne ObjRef"); pViewSh->SetVerbs( 0 ); } } diff --git a/sc/source/ui/view/formatsh.cxx b/sc/source/ui/view/formatsh.cxx index 69ff3e7c2..2c9d6197c 100644 --- a/sc/source/ui/view/formatsh.cxx +++ b/sc/source/ui/view/formatsh.cxx @@ -904,7 +904,7 @@ void ScFormatShell::ExecuteStyle( SfxRequest& rReq ) } else { - DBG_ERROR( "Unknown slot (ScViewShell::ExecuteStyle)" ); + OSL_FAIL( "Unknown slot (ScViewShell::ExecuteStyle)" ); } } @@ -1045,7 +1045,7 @@ void ScFormatShell::ExecuteNumFormat( SfxRequest& rReq ) break; default: - DBG_ERROR("falscher Slot bei ExecuteEdit"); + OSL_FAIL("falscher Slot bei ExecuteEdit"); break; } } @@ -1127,7 +1127,7 @@ void ScFormatShell::ExecuteAlignment( SfxRequest& rReq ) pTabViewShell->ApplyAttr( SvxVerJustifyItem( (SvxCellVerJustify)((const SvxVerJustifyItem*)pItem)->GetValue(), ATTR_VER_JUSTIFY ) ); break; default: - DBG_ERROR( "ExecuteAlignment: invalid slot" ); + OSL_FAIL( "ExecuteAlignment: invalid slot" ); return; } } diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx index f514fe6f6..b4c97dbc9 100644 --- a/sc/source/ui/view/gridwin.cxx +++ b/sc/source/ui/view/gridwin.cxx @@ -470,7 +470,7 @@ ScGridWindow::ScGridWindow( Window* pParent, ScViewData* pData, ScSplitPos eWhic eVWhich = SC_SPLIT_BOTTOM; break; default: - DBG_ERROR("GridWindow: falsche Position"); + OSL_FAIL("GridWindow: falsche Position"); } SetBackground(); @@ -1310,7 +1310,7 @@ void ScGridWindow::ExecFilter( ULONG nSel, } else { - DBG_ERROR("Wo ist der Datenbankbereich?"); + OSL_FAIL("Wo ist der Datenbankbereich?"); } } @@ -4148,7 +4148,7 @@ sal_Int8 ScGridWindow::ExecuteDrop( const ExecuteDropEvent& rEvt ) } else { - DBG_ERROR("drop with link: no sheet nor area"); + OSL_FAIL("drop with link: no sheet nor area"); bOk = FALSE; } } diff --git a/sc/source/ui/view/gridwin2.cxx b/sc/source/ui/view/gridwin2.cxx index 63c94d8a9..105d2418d 100644 --- a/sc/source/ui/view/gridwin2.cxx +++ b/sc/source/ui/view/gridwin2.cxx @@ -247,7 +247,7 @@ void ScGridWindow::DoPushButton( SCCOL nCol, SCROW nRow, const MouseEvent& rMEvt } else { - DBG_ERROR("Da is ja garnix"); + OSL_FAIL("Da is ja garnix"); } } diff --git a/sc/source/ui/view/gridwin4.cxx b/sc/source/ui/view/gridwin4.cxx index 041d9fda5..deba38ff5 100644 --- a/sc/source/ui/view/gridwin4.cxx +++ b/sc/source/ui/view/gridwin4.cxx @@ -1179,7 +1179,7 @@ void ScGridWindow::DrawButtons( SCCOL nX1, SCROW /*nY1*/, SCCOL nX2, SCROW /*nY2 else { // can also be part of DataPilot table - // DBG_ERROR("Auto-Filter-Button ohne DBData"); + // OSL_FAIL("Auto-Filter-Button ohne DBData"); } } @@ -1325,7 +1325,7 @@ BOOL ScGridWindow::IsAutoFilterActive( SCCOL nCol, SCROW nRow, SCTAB nTab ) pDBData->GetQueryParam( aQueryParam ); else { - DBG_ERROR("Auto-Filter-Button ohne DBData"); + OSL_FAIL("Auto-Filter-Button ohne DBData"); } BOOL bSimpleQuery = TRUE; diff --git a/sc/source/ui/view/output2.cxx b/sc/source/ui/view/output2.cxx index 0a3590b0d..eb8256564 100644 --- a/sc/source/ui/view/output2.cxx +++ b/sc/source/ui/view/output2.cxx @@ -376,7 +376,7 @@ void ScDrawStringsVars::SetPattern( const ScPatternAttr* pNew, const SfxItemSet* bRotated = FALSE; break; default: - DBG_ERROR("Falscher SvxCellOrientation Wert"); + OSL_FAIL("Falscher SvxCellOrientation Wert"); nRot = 0; bRotated = FALSE; break; @@ -2670,7 +2670,7 @@ void ScOutputData::DrawEdit(BOOL bPixelToLogic) } else { - DBG_ERROR("pData == 0"); + OSL_FAIL("pData == 0"); } } else @@ -2698,7 +2698,7 @@ void ScOutputData::DrawEdit(BOOL bPixelToLogic) } else { - DBG_ERROR("pCell == NULL"); + OSL_FAIL("pCell == NULL"); } pEngine->SetUpdateMode( TRUE ); // after SetText, before CalcTextWidth/GetTextHeight @@ -3438,7 +3438,7 @@ void ScOutputData::DrawRotated(BOOL bPixelToLogic) pEngine->SetText(*pData); else { - DBG_ERROR("pData == 0"); + OSL_FAIL("pData == 0"); } } else @@ -3466,7 +3466,7 @@ void ScOutputData::DrawRotated(BOOL bPixelToLogic) } else { - DBG_ERROR("pCell == NULL"); + OSL_FAIL("pCell == NULL"); } pEngine->SetUpdateMode( TRUE ); // after SetText, before CalcTextWidth/GetTextHeight diff --git a/sc/source/ui/view/preview.cxx b/sc/source/ui/view/preview.cxx index 0058ee896..43acb84d8 100644 --- a/sc/source/ui/view/preview.cxx +++ b/sc/source/ui/view/preview.cxx @@ -842,7 +842,7 @@ Size lcl_GetDocPageSize( ScDocument* pDoc, SCTAB nTab ) } else { - DBG_ERROR( "PageStyle not found" ); + OSL_FAIL( "PageStyle not found" ); return Size(); } } diff --git a/sc/source/ui/view/prevwsh.cxx b/sc/source/ui/view/prevwsh.cxx index fc5c92361..608bd3d79 100644 --- a/sc/source/ui/view/prevwsh.cxx +++ b/sc/source/ui/view/prevwsh.cxx @@ -235,7 +235,7 @@ Size ScPreviewShell::GetOptimalSizePixel() const } else { - DBG_ERROR( "TabViewShell not found :-/" ); + OSL_FAIL( "TabViewShell not found :-/" ); } return aOptSize; @@ -1204,7 +1204,7 @@ void ScPreviewShell::RemoveAccessibilityObject( SfxListener& rObject ) rObject.EndListening( *pAccessibilityBroadcaster ); else { - DBG_ERROR("kein Accessibility-Broadcaster?"); + OSL_FAIL("kein Accessibility-Broadcaster?"); } } diff --git a/sc/source/ui/view/printfun.cxx b/sc/source/ui/view/printfun.cxx index 5ad67a203..c83ef1624 100644 --- a/sc/source/ui/view/printfun.cxx +++ b/sc/source/ui/view/printfun.cxx @@ -132,7 +132,7 @@ void ScPageRowEntry::SetPagesX(size_t nNew) { if (pHidden) { - DBG_ERROR("SetPagesX nicht nach SetHidden"); + OSL_FAIL("SetPagesX nicht nach SetHidden"); delete[] pHidden; pHidden = NULL; } @@ -214,7 +214,7 @@ void ScPrintFunc::Construct( const ScPrintOptions* pOptions ) pParamSet = &pStyleSheet->GetItemSet(); else { - DBG_ERROR("Seitenvorlage nicht gefunden" ); + OSL_FAIL("Seitenvorlage nicht gefunden" ); pParamSet = NULL; } @@ -881,7 +881,7 @@ void ScPrintFunc::InitParam( const ScPrintOptions* pOptions ) aPageSize = ((const SvxSizeItem&) pParamSet->Get(ATTR_PAGE_SIZE)).GetSize(); if ( !aPageSize.Width() || !aPageSize.Height() ) { - DBG_ERROR("PageSize Null ?!?!?"); + OSL_FAIL("PageSize Null ?!?!?"); aPageSize = SvxPaperInfo::GetPaperSize( PAPER_A4 ); } @@ -2013,7 +2013,7 @@ long ScPrintFunc::PrintNotes( long nPageNo, long nNoteStart, BOOL bDoPrint, ScPr if ( pPrinter && bDoPrint ) { - DBG_ERROR( "StartPage does not exist anymore" ); + OSL_FAIL( "StartPage does not exist anymore" ); } if ( bDoPrint || pLocationData ) @@ -2036,7 +2036,7 @@ long ScPrintFunc::PrintNotes( long nPageNo, long nNoteStart, BOOL bDoPrint, ScPr if ( pPrinter && bDoPrint ) { - DBG_ERROR( "EndPage does not exist anymore" ); + OSL_FAIL( "EndPage does not exist anymore" ); } return nCount; @@ -2101,7 +2101,7 @@ void ScPrintFunc::PrintPage( long nPageNo, SCCOL nX1, SCROW nY1, SCCOL nX2, SCRO if ( pPrinter && bDoPrint ) { - DBG_ERROR( "StartPage does not exist anymore" ); + OSL_FAIL( "StartPage does not exist anymore" ); } // Kopf- und Fusszeilen (ohne Zentrierung) @@ -2382,7 +2382,7 @@ void ScPrintFunc::PrintPage( long nPageNo, SCCOL nX1, SCROW nY1, SCCOL nX2, SCRO if ( pPrinter && bDoPrint ) { - DBG_ERROR( "EndPage does not exist anymore" ); + OSL_FAIL( "EndPage does not exist anymore" ); } aLastSourceRange = ScRange( nX1, nY1, nPrintTab, nX2, nY2, nPrintTab ); diff --git a/sc/source/ui/view/tabcont.cxx b/sc/source/ui/view/tabcont.cxx index 8953f232c..221bf2c34 100644 --- a/sc/source/ui/view/tabcont.cxx +++ b/sc/source/ui/view/tabcont.cxx @@ -505,7 +505,7 @@ USHORT lcl_DocShellNr( ScDocument* pDoc ) pShell = SfxObjectShell::GetNext( *pShell ); } - DBG_ERROR("Dokument nicht gefunden"); + OSL_FAIL("Dokument nicht gefunden"); return 0; } @@ -602,7 +602,7 @@ long ScTabControl::AllowRenaming() // if the error message from this TabControl is currently visible, // don't end edit mode now, to avoid problems when returning to // the other call (showing the error) - this should not happen - DBG_ERROR("ScTabControl::AllowRenaming: nested calls"); + OSL_FAIL("ScTabControl::AllowRenaming: nested calls"); nRet = TABBAR_RENAMING_NO; } else if ( Application::IsInModalMode() ) diff --git a/sc/source/ui/view/tabview.cxx b/sc/source/ui/view/tabview.cxx index ea2b2633e..eb1719adb 100644 --- a/sc/source/ui/view/tabview.cxx +++ b/sc/source/ui/view/tabview.cxx @@ -2127,7 +2127,7 @@ void ScTabView::SnapSplitPos( Point& rScreenPosPixel ) Window* pWin = pGridWin[ePos]; if (!pWin) { - DBG_ERROR("Window NULL"); + OSL_FAIL("Window NULL"); return; } diff --git a/sc/source/ui/view/tabview2.cxx b/sc/source/ui/view/tabview2.cxx index ce9800cde..7daedcfd3 100644 --- a/sc/source/ui/view/tabview2.cxx +++ b/sc/source/ui/view/tabview2.cxx @@ -214,7 +214,7 @@ void ScTabView::MarkCursor( SCCOL nCurX, SCROW nCurY, SCTAB nCurZ, if (!bIsBlockMode) { - DBG_ERROR( "MarkCursor nicht im BlockMode" ); + OSL_FAIL( "MarkCursor nicht im BlockMode" ); InitBlockMode( nCurX, nCurY, nCurZ, FALSE, bCols, bRows ); } @@ -1189,7 +1189,7 @@ USHORT ScTabView::CalcZoom( SvxZoomType eType, USHORT nOldZoom ) break; default: - DBG_ERROR("Unknown Zoom-Revision"); + OSL_FAIL("Unknown Zoom-Revision"); nZoom = 0; } diff --git a/sc/source/ui/view/tabview3.cxx b/sc/source/ui/view/tabview3.cxx index 127ba9e78..44b793529 100644 --- a/sc/source/ui/view/tabview3.cxx +++ b/sc/source/ui/view/tabview3.cxx @@ -797,7 +797,7 @@ void ScTabView::AlignToCursor( SCsCOL nCurX, SCsROW nCurY, ScFollowMode eMode, case SC_FOLLOW_NONE: break; default: - DBG_ERROR("Falscher Cursormodus"); + OSL_FAIL("Falscher Cursormodus"); break; } @@ -1431,7 +1431,7 @@ void ScTabView::SetTabNo( SCTAB nTab, BOOL bNew, BOOL bExtendSelection ) { if ( !ValidTab(nTab) ) { - DBG_ERROR("SetTabNo: falsche Tabelle"); + OSL_FAIL("SetTabNo: falsche Tabelle"); return; } @@ -1482,7 +1482,7 @@ void ScTabView::SetTabNo( SCTAB nTab, BOOL bNew, BOOL bExtendSelection ) --nTab; else { - DBG_ERROR("keine sichtbare Tabelle"); + OSL_FAIL("keine sichtbare Tabelle"); pDoc->SetVisible( 0, TRUE ); } } diff --git a/sc/source/ui/view/tabvwsh3.cxx b/sc/source/ui/view/tabvwsh3.cxx index 3e855a93b..4462b7521 100644 --- a/sc/source/ui/view/tabvwsh3.cxx +++ b/sc/source/ui/view/tabvwsh3.cxx @@ -529,7 +529,7 @@ void ScTabViewShell::Execute( SfxRequest& rReq ) // View aufgerufen, um auf der sichtbaren View zu markieren/umzuschalten: case SID_TABLE_ACTIVATE: - DBG_ERROR("old slot SID_TABLE_ACTIVATE"); + OSL_FAIL("old slot SID_TABLE_ACTIVATE"); break; case SID_REPAINT: @@ -1150,7 +1150,7 @@ void ScTabViewShell::Execute( SfxRequest& rReq ) break; default: - DBG_ERROR("Unbekannter Slot bei ScTabViewShell::Execute"); + OSL_FAIL("Unbekannter Slot bei ScTabViewShell::Execute"); break; } } diff --git a/sc/source/ui/view/tabvwsh4.cxx b/sc/source/ui/view/tabvwsh4.cxx index 3cea85fee..504a0507a 100644 --- a/sc/source/ui/view/tabvwsh4.cxx +++ b/sc/source/ui/view/tabvwsh4.cxx @@ -984,7 +984,7 @@ void ScTabViewShell::SetCurSubShell(ObjectSelectionType eOST, BOOL bForce) } break; default: - DBG_ERROR("Falsche Shell angefordert"); + OSL_FAIL("Falsche Shell angefordert"); break; } @@ -1074,7 +1074,7 @@ void ScTabViewShell::SetDrawTextUndo( SfxUndoManager* pNewUndoMgr ) } else { - DBG_ERROR("SetDrawTextUndo ohne DrawTextShell"); + OSL_FAIL("SetDrawTextUndo ohne DrawTextShell"); } } @@ -1996,7 +1996,7 @@ void ScTabViewShell::ExecTbx( SfxRequest& rReq ) nInsObjCtrlState = ((const SfxUInt16Item*)pItem)->GetValue(); break; default: - DBG_ERROR("Slot im Wald"); + OSL_FAIL("Slot im Wald"); } GetViewFrame()->GetBindings().Invalidate( nSlot ); } diff --git a/sc/source/ui/view/tabvwsh5.cxx b/sc/source/ui/view/tabvwsh5.cxx index bb87b55ec..05c361903 100644 --- a/sc/source/ui/view/tabvwsh5.cxx +++ b/sc/source/ui/view/tabvwsh5.cxx @@ -240,7 +240,7 @@ void ScTabViewShell::Notify( SfxBroadcaster& rBC, const SfxHint& rHint ) case SC_TAB_HIDDEN: break; default: - DBG_ERROR("unbekannter ScTablesHint"); + OSL_FAIL("unbekannter ScTablesHint"); } // hier keine Abfrage auf IsActive() mehr, weil die Aktion von Basic ausgehen diff --git a/sc/source/ui/view/tabvwshb.cxx b/sc/source/ui/view/tabvwshb.cxx index eba271bcd..0f422b0b8 100644 --- a/sc/source/ui/view/tabvwshb.cxx +++ b/sc/source/ui/view/tabvwshb.cxx @@ -200,7 +200,7 @@ BOOL ScTabViewShell::ActivateObject( SdrOle2Obj* pObj, long nVerb ) } catch( const uno::Exception & ) { - DBG_ERROR( "Exception caught while querying chart" ); + OSL_FAIL( "Exception caught while querying chart" ); } } } @@ -240,7 +240,7 @@ ErrCode ScTabViewShell::DoVerb(long nVerb) } else { - DBG_ERROR("kein Objekt fuer Verb gefunden"); + OSL_FAIL("kein Objekt fuer Verb gefunden"); } return nErr; diff --git a/sc/source/ui/view/tabvwshc.cxx b/sc/source/ui/view/tabvwshc.cxx index 7d79c148b..07e20c4db 100644 --- a/sc/source/ui/view/tabvwshc.cxx +++ b/sc/source/ui/view/tabvwshc.cxx @@ -312,7 +312,7 @@ SfxModelessDialog* ScTabViewShell::CreateRefDialog( default: - DBG_ERROR( "ScTabViewShell::CreateRefDialog: unbekannte ID" ); + OSL_FAIL( "ScTabViewShell::CreateRefDialog: unbekannte ID" ); break; } diff --git a/sc/source/ui/view/tabvwshe.cxx b/sc/source/ui/view/tabvwshe.cxx index 2d6def3df..9617b818d 100644 --- a/sc/source/ui/view/tabvwshe.cxx +++ b/sc/source/ui/view/tabvwshe.cxx @@ -275,7 +275,7 @@ void ScTabViewShell::ExecSearch( SfxRequest& rReq ) } else { - DBG_ERROR("SID_SEARCH_ITEM ohne Parameter"); + OSL_FAIL("SID_SEARCH_ITEM ohne Parameter"); } break; case FID_SEARCH: diff --git a/sc/source/ui/view/tabvwshf.cxx b/sc/source/ui/view/tabvwshf.cxx index feff6233b..f214e50f2 100644 --- a/sc/source/ui/view/tabvwshf.cxx +++ b/sc/source/ui/view/tabvwshf.cxx @@ -823,7 +823,7 @@ void ScTabViewShell::ExecuteTable( SfxRequest& rReq ) break; default: - DBG_ERROR("Unbekannte Message bei ViewShell"); + OSL_FAIL("Unbekannte Message bei ViewShell"); break; } } diff --git a/sc/source/ui/view/tabvwshh.cxx b/sc/source/ui/view/tabvwshh.cxx index e536781a8..416406b23 100644 --- a/sc/source/ui/view/tabvwshh.cxx +++ b/sc/source/ui/view/tabvwshh.cxx @@ -81,7 +81,7 @@ void ScTabViewShell::ExecuteObject( SfxRequest& rReq ) ScTabViewShell* pVisibleSh = this; if ( nSlotId == SID_OLE_SELECT || nSlotId == SID_OLE_ACTIVATE || nSlotId == SID_OLE_DEACTIVATE ) { - DBG_ERROR("old slot SID_OLE..."); + OSL_FAIL("old slot SID_OLE..."); } switch (nSlotId) @@ -258,7 +258,7 @@ void ScTabViewShell::RemoveAccessibilityObject( SfxListener& rObject ) } else { - DBG_ERROR("kein Accessibility-Broadcaster?"); + OSL_FAIL("kein Accessibility-Broadcaster?"); } } diff --git a/sc/source/ui/view/viewdata.cxx b/sc/source/ui/view/viewdata.cxx index 57ca05aca..af2c533f5 100644 --- a/sc/source/ui/view/viewdata.cxx +++ b/sc/source/ui/view/viewdata.cxx @@ -430,7 +430,7 @@ ScDocument* ScViewData::GetDocument() const else if (pDocShell) return pDocShell->GetDocument(); - DBG_ERROR("kein Document an ViewData"); + OSL_FAIL("kein Document an ViewData"); return NULL; } @@ -496,7 +496,7 @@ void ScViewData::CopyTab( SCTAB nSrcTab, SCTAB nDestTab ) if (nDestTab > MAXTAB) { - DBG_ERROR("Zuviele Tabellen"); + OSL_FAIL("Zuviele Tabellen"); return; } @@ -915,7 +915,7 @@ void ScViewData::SetEditEngine( ScSplitPos eWhich, if (pEditView[eWhich]->GetWindow() != pWin) { pEditView[eWhich]->SetWindow(pWin); - DBG_ERROR("EditView Window geaendert"); + OSL_FAIL("EditView Window geaendert"); } } else @@ -1433,7 +1433,7 @@ void ScViewData::SetTabNo( SCTAB nNewTab ) { if (!ValidTab(nNewTab)) { - DBG_ERROR("falsche Tabellennummer"); + OSL_FAIL("falsche Tabellennummer"); return; } @@ -1815,7 +1815,7 @@ BOOL ScViewData::GetPosFromPixel( long nClickX, long nClickY, ScSplitPos eWhich, if ( ( bHOver && pMerge->GetColMerge() <= 1 ) || ( bVOver && pMerge->GetRowMerge() <= 1 ) ) { - DBG_ERROR("Merge-Fehler gefunden"); + OSL_FAIL("Merge-Fehler gefunden"); pDoc->RemoveFlagsTab( 0,0, MAXCOL,MAXROW, nTabNo, SC_MF_HOR | SC_MF_VER ); SCCOL nEndCol = MAXCOL; @@ -2234,7 +2234,7 @@ void ScViewData::ReadUserData(const String& rData) { // #45208# beim Reload in der Seitenansicht sind evtl. die Preview-UserData // stehengelassen worden. Den Zoom von der Preview will man hier nicht... - DBG_ERROR("ReadUserData: das sind nicht meine Daten"); + OSL_FAIL("ReadUserData: das sind nicht meine Daten"); return; } @@ -2331,7 +2331,7 @@ void ScViewData::ReadUserData(const String& rData) { // dann wieder auf Default (unten links) pTabData[nPos]->eWhichActive = SC_SPLIT_BOTTOMLEFT; - DBG_ERROR("SplitPos musste korrigiert werden"); + OSL_FAIL("SplitPos musste korrigiert werden"); } } ++nPos; diff --git a/sc/source/ui/view/viewfun2.cxx b/sc/source/ui/view/viewfun2.cxx index a0d227773..f1ce624d9 100644 --- a/sc/source/ui/view/viewfun2.cxx +++ b/sc/source/ui/view/viewfun2.cxx @@ -2501,7 +2501,7 @@ void ScViewFunc::MoveTable( USHORT nDestDocNo, SCTAB nDestTab, BOOL bCopy, const if (!pDestShell) { - DBG_ERROR("Dest-Doc nicht gefunden !!!"); + OSL_FAIL("Dest-Doc nicht gefunden !!!"); return; } diff --git a/sc/source/ui/view/viewfun3.cxx b/sc/source/ui/view/viewfun3.cxx index f0e6621f7..55f60d171 100644 --- a/sc/source/ui/view/viewfun3.cxx +++ b/sc/source/ui/view/viewfun3.cxx @@ -951,7 +951,7 @@ BOOL ScViewFunc::PasteFromClip( USHORT nFlags, ScDocument* pClipDoc, { if (!pClipDoc) { - DBG_ERROR("PasteFromClip: pClipDoc=0 not allowed"); + OSL_FAIL("PasteFromClip: pClipDoc=0 not allowed"); return FALSE; } diff --git a/sc/source/ui/view/viewfun4.cxx b/sc/source/ui/view/viewfun4.cxx index df0920fbf..bb2c9a69c 100644 --- a/sc/source/ui/view/viewfun4.cxx +++ b/sc/source/ui/view/viewfun4.cxx @@ -402,7 +402,7 @@ void ScViewFunc::DoThesaurus( BOOL bRecord ) } else { - DBG_ERROR("DoThesaurus: Keine String oder Editzelle"); + OSL_FAIL("DoThesaurus: Keine String oder Editzelle"); } pEditView = GetViewData()->GetEditView(GetViewData()->GetActivePart());; if (pEditSel) diff --git a/sc/source/ui/view/viewfun5.cxx b/sc/source/ui/view/viewfun5.cxx index 5376d6c78..9a8ed54a5 100644 --- a/sc/source/ui/view/viewfun5.cxx +++ b/sc/source/ui/view/viewfun5.cxx @@ -207,7 +207,7 @@ BOOL ScViewFunc::PasteDataFormat( ULONG nFormatId, } else { - DBG_ERROR("Error in CreateAndLoad"); + OSL_FAIL("Error in CreateAndLoad"); } } } @@ -280,7 +280,7 @@ BOOL ScViewFunc::PasteDataFormat( ULONG nFormatId, } else { - DBG_ERROR("Error creating external OLE object"); + OSL_FAIL("Error creating external OLE object"); } } //TODO/LATER: if format is not available, create picture @@ -562,7 +562,7 @@ BOOL ScViewFunc::PasteDataFormat( ULONG nFormatId, } else { - DBG_ERROR("no dimension"); //! possible? + OSL_FAIL("no dimension"); //! possible? SCCOL nFirstCol, nLastCol; SCROW nFirstRow, nLastRow; if ( pInsDoc->GetDataStart( nSrcTab, nFirstCol, nFirstRow ) ) @@ -634,7 +634,7 @@ ByteString lcl_GetSubString( sal_Char* pData, long nStart, long nDataSize ) { if ( nDataSize <= nStart /* || pData[nDataSize] != 0 */ ) { - DBG_ERROR("DDE Data: invalid data"); + OSL_FAIL("DDE Data: invalid data"); return ByteString(); } return ByteString( pData + nStart ); @@ -650,7 +650,7 @@ BOOL ScViewFunc::PasteDDE( const uno::Reference<datatransfer::XTransferable>& rx uno::Sequence<sal_Int8> aSequence; if ( !aDataHelper.GetSequence( SOT_FORMATSTR_ID_LINK, aSequence ) ) { - DBG_ERROR("DDE Data not found."); + OSL_FAIL("DDE Data not found."); return FALSE; } diff --git a/sc/source/ui/view/viewfun7.cxx b/sc/source/ui/view/viewfun7.cxx index 3da741061..63f4fb006 100644 --- a/sc/source/ui/view/viewfun7.cxx +++ b/sc/source/ui/view/viewfun7.cxx @@ -307,7 +307,7 @@ BOOL ScViewFunc::PasteObject( const Point& rPos, const uno::Reference < embed::X if( aSize.Height() == 0 || aSize.Width() == 0 ) { - DBG_ERROR("SvObjectDescriptor::GetSize == 0"); + OSL_FAIL("SvObjectDescriptor::GetSize == 0"); aSize.Width() = 5000; aSize.Height() = 5000; aSize = OutputDevice::LogicToLogic( aSize, aMap100, aMapObj ); diff --git a/sc/source/ui/view/viewfunc.cxx b/sc/source/ui/view/viewfunc.cxx index 7ef09be91..b0be5ca20 100644 --- a/sc/source/ui/view/viewfunc.cxx +++ b/sc/source/ui/view/viewfunc.cxx @@ -2775,7 +2775,7 @@ void ScViewFunc::ChangeNumFmtDecimals( BOOL bIncrement ) const SvNumberformat* pOldEntry = pFormatter->GetEntry( nOldFormat ); if (!pOldEntry) { - DBG_ERROR("Zahlformat nicht gefunden !!!"); + OSL_FAIL("Zahlformat nicht gefunden !!!"); return; } |