diff options
Diffstat (limited to 'chart2')
9 files changed, 17 insertions, 49 deletions
diff --git a/chart2/source/controller/accessibility/AccessibleBase.cxx b/chart2/source/controller/accessibility/AccessibleBase.cxx index 587a82773f28..7fba2be47ffb 100644 --- a/chart2/source/controller/accessibility/AccessibleBase.cxx +++ b/chart2/source/controller/accessibility/AccessibleBase.cxx @@ -126,13 +126,7 @@ bool AccessibleBase::NotifyEvent( EventType eEventType, const AccessibleUniqueId case OBJECT_CHANGE: { BroadcastAccEvent( AccessibleEventId::VISIBLE_DATA_CHANGED, aEmpty, aEmpty ); -#if OSL_DEBUG_LEVEL > 1 - OSL_TRACE( - OUStringToOString( - OUString( "Visible data event sent by: " ) + - getAccessibleName(), - RTL_TEXTENCODING_ASCII_US ).getStr() ); -#endif + SAL_INFO("chart2.accessibility", "Visible data event sent by: " << getAccessibleName()); } break; @@ -144,13 +138,8 @@ bool AccessibleBase::NotifyEvent( EventType eEventType, const AccessibleUniqueId AddState( AccessibleStateType::FOCUSED ); aSelected <<= AccessibleStateType::FOCUSED; BroadcastAccEvent( AccessibleEventId::STATE_CHANGED, aSelected, aEmpty, true ); -#if OSL_DEBUG_LEVEL > 1 - OSL_TRACE( - OUStringToOString( - OUString( "Selection acquired by: " ) + - getAccessibleName(), - RTL_TEXTENCODING_ASCII_US ).getStr() ); -#endif + + SAL_INFO("chart2.accessibility", "Selection acquired by: " << getAccessibleName()); } break; @@ -162,13 +151,7 @@ bool AccessibleBase::NotifyEvent( EventType eEventType, const AccessibleUniqueId AddState( AccessibleStateType::FOCUSED ); aSelected <<= AccessibleStateType::FOCUSED; BroadcastAccEvent( AccessibleEventId::STATE_CHANGED, aEmpty, aSelected, true ); -#if OSL_DEBUG_LEVEL > 1 - OSL_TRACE( - OUStringToOString( - OUString( "Selection lost by: " ) + - getAccessibleName(), - RTL_TEXTENCODING_ASCII_US ).getStr() ); -#endif + SAL_INFO("chart2.accessibility", "Selection lost by: " << getAccessibleName()); } break; diff --git a/chart2/source/controller/dialogs/DataBrowserModel.cxx b/chart2/source/controller/dialogs/DataBrowserModel.cxx index b16c6ccf941c..8ec2ca364ccf 100644 --- a/chart2/source/controller/dialogs/DataBrowserModel.cxx +++ b/chart2/source/controller/dialogs/DataBrowserModel.cxx @@ -51,10 +51,6 @@ #include <algorithm> -#if OSL_DEBUG_LEVEL > 1 -#include <cstdio> -#endif - using namespace ::com::sun::star; using ::com::sun::star::uno::Reference; diff --git a/chart2/source/controller/main/ChartController.cxx b/chart2/source/controller/main/ChartController.cxx index 000756966574..b2fd6771779c 100644 --- a/chart2/source/controller/main/ChartController.cxx +++ b/chart2/source/controller/main/ChartController.cxx @@ -202,11 +202,7 @@ void ChartController::TheModel::tryTermination() //since we have indicated to give up the ownership with parameter true in close call //the one who has thrown the CloseVetoException is the new owner -#if OSL_DEBUG_LEVEL > 1 - OSL_ENSURE( !m_bOwnership, - "INFO: a well known owner has caught a CloseVetoException after calling close(true)" ); -#endif - + SAL_WARN_IF( m_bOwnership, "chart2.main", "a well known owner has caught a CloseVetoException after calling close(true)"); m_bOwnership = false; return; } diff --git a/chart2/source/model/main/BaseCoordinateSystem.cxx b/chart2/source/model/main/BaseCoordinateSystem.cxx index cbd9f7d44261..6eb5caea9390 100644 --- a/chart2/source/model/main/BaseCoordinateSystem.cxx +++ b/chart2/source/model/main/BaseCoordinateSystem.cxx @@ -30,9 +30,6 @@ #include <algorithm> #include <iterator> -#if OSL_DEBUG_LEVEL > 1 -#include <rtl/math.hxx> -#endif #include <com/sun/star/beans/PropertyAttribute.hpp> using namespace ::com::sun::star; diff --git a/chart2/source/model/template/BubbleDataInterpreter.cxx b/chart2/source/model/template/BubbleDataInterpreter.cxx index 2465041abc65..910430ad8cff 100644 --- a/chart2/source/model/template/BubbleDataInterpreter.cxx +++ b/chart2/source/model/template/BubbleDataInterpreter.cxx @@ -250,11 +250,11 @@ chart2::InterpretedData SAL_CALL BubbleDataInterpreter::reinterpretDataSeries( Sequence< Reference< data::XLabeledDataSequence > > aSeqs( xSeriesSource->getDataSequences()); if( aSeqs.getLength() != aNewSequences.getLength() ) { -#if OSL_DEBUG_LEVEL > 1 +#if OSL_DEBUG_LEVEL > 0 sal_Int32 j=0; for( ; j<aSeqs.getLength(); ++j ) { - OSL_ENSURE( aSeqs[j] == xValuesY || aSeqs[j] == xValuesX || aSeqs[j] == xValuesSize, "All sequences should be used" ); + assert( (aSeqs[j] == xValuesY || aSeqs[j] == xValuesX || aSeqs[j] == xValuesSize) && "All sequences should be used" ); } #endif Reference< data::XDataSink > xSink( xSeriesSource, uno::UNO_QUERY_THROW ); diff --git a/chart2/source/model/template/DataInterpreter.cxx b/chart2/source/model/template/DataInterpreter.cxx index 25a1c8b40661..d8ea1c46ce85 100644 --- a/chart2/source/model/template/DataInterpreter.cxx +++ b/chart2/source/model/template/DataInterpreter.cxx @@ -40,7 +40,7 @@ using namespace ::chart::ContainerHelper; using ::com::sun::star::uno::Reference; using ::com::sun::star::uno::Sequence; -#if OSL_DEBUG_LEVEL > 1 +#ifdef DEBUG_CHART2_TEMPLATE namespace { void lcl_ShowDataSource( const Reference< data::XDataSource > & xSource ); @@ -68,7 +68,7 @@ InterpretedData SAL_CALL DataInterpreter::interpretDataSource( if( ! xSource.is()) return InterpretedData(); -#if OSL_DEBUG_LEVEL > 1 +#ifdef DEBUG_CHART2_TEMPLATE lcl_ShowDataSource( xSource ); #endif @@ -172,11 +172,11 @@ InterpretedData SAL_CALL DataInterpreter::reinterpretDataSeries( Sequence< Reference< data::XLabeledDataSequence > > aSeqs( xSeriesSource->getDataSequences()); if( aSeqs.getLength() != aNewSequences.getLength() ) { -#if OSL_DEBUG_LEVEL > 1 +#ifdef DEBUG_CHART2_TEMPLATE sal_Int32 j=0; for( ; j<aSeqs.getLength(); ++j ) { - OSL_ENSURE( aSeqs[j] == xValuesY, "All sequences should be used" ); + assert( aSeqs[j] == xValuesY && "All sequences should be used" ); } #endif Reference< data::XDataSink > xSink( xSeriesSource, uno::UNO_QUERY_THROW ); @@ -413,7 +413,7 @@ css::uno::Sequence< OUString > SAL_CALL DataInterpreter::getSupportedServiceName } // namespace chart -#if OSL_DEBUG_LEVEL > 1 +#ifdef DEBUG_CHART2_TEMPLATE namespace { diff --git a/chart2/source/model/template/XYDataInterpreter.cxx b/chart2/source/model/template/XYDataInterpreter.cxx index a30a4459e4fa..e291eafefd16 100644 --- a/chart2/source/model/template/XYDataInterpreter.cxx +++ b/chart2/source/model/template/XYDataInterpreter.cxx @@ -211,11 +211,11 @@ chart2::InterpretedData SAL_CALL XYDataInterpreter::reinterpretDataSeries( Sequence< Reference< data::XLabeledDataSequence > > aSeqs( xSeriesSource->getDataSequences()); if( aSeqs.getLength() != aNewSequences.getLength() ) { -#if OSL_DEBUG_LEVEL > 1 +#ifdef DBG_UTIL sal_Int32 j=0; for( ; j<aSeqs.getLength(); ++j ) { - OSL_ENSURE( aSeqs[j] == xValuesY || aSeqs[j] == xValuesX, "All sequences should be used" ); + SAL_WARN_IF((aSeqs[j] == xValuesY || aSeqs[j] == xValuesX), "chart2.template", "All sequences should be used" ); } #endif Reference< data::XDataSink > xSink( xSeriesSource, uno::UNO_QUERY_THROW ); diff --git a/chart2/source/tools/InternalData.cxx b/chart2/source/tools/InternalData.cxx index a13424010cd1..b6cb49fefb34 100644 --- a/chart2/source/tools/InternalData.cxx +++ b/chart2/source/tools/InternalData.cxx @@ -22,7 +22,7 @@ #include "Strings.hrc" #include <rtl/math.hxx> -#if OSL_DEBUG_LEVEL > 1 +#ifdef DEBUG_CHART2_TOOLS #define DEBUG_INTERNAL_DATA 1 #endif diff --git a/chart2/source/tools/WrappedPropertySet.cxx b/chart2/source/tools/WrappedPropertySet.cxx index 06b98987555b..2fe07d70f739 100644 --- a/chart2/source/tools/WrappedPropertySet.cxx +++ b/chart2/source/tools/WrappedPropertySet.cxx @@ -105,9 +105,7 @@ void SAL_CALL WrappedPropertySet::setPropertyValue( const OUString& rPropertyNam xInnerPropertySet->setPropertyValue( rPropertyName, rValue ); else { -#if OSL_DEBUG_LEVEL > 1 - OSL_FAIL("found no inner property set to map to"); -#endif + SAL_WARN("chart2.tools", "found no inner property set to map to"); } } catch( const beans::UnknownPropertyException& ) @@ -154,9 +152,7 @@ Any SAL_CALL WrappedPropertySet::getPropertyValue( const OUString& rPropertyName aRet = xInnerPropertySet->getPropertyValue( rPropertyName ); else { -#if OSL_DEBUG_LEVEL > 1 - OSL_FAIL("found no inner property set to map to"); -#endif + SAL_WARN("chart2.tools", "found no inner property set to map to"); } } catch( const beans::UnknownPropertyException& ) |