diff options
author | Berk Gureken <berkgureken@gmail.com> | 2016-02-01 12:07:06 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2016-02-04 12:54:23 +0000 |
commit | 9108dc39525fb1d881d5b4a634039a25ef2d2d25 (patch) | |
tree | 8e77cba1ae24fa8fb2515b3f620da0e16cb91a02 /framework | |
parent | 1ee9765beffa7cebcc891227d741eeb0cc74eb55 (diff) |
tdf#43157 Cleanup DBG_ASSERT for fpicker and framework
Change-Id: I1b79a39a9d709184cc72a905647f73dbf85eef27
Signed-off-by: Berk Gureken <berkgureken@gmail.com>
Reviewed-on: https://gerrit.libreoffice.org/21991
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>
Diffstat (limited to 'framework')
4 files changed, 12 insertions, 12 deletions
diff --git a/framework/source/fwi/helper/mischelper.cxx b/framework/source/fwi/helper/mischelper.cxx index f8a1f753aafc..665b74290fca 100644 --- a/framework/source/fwi/helper/mischelper.cxx +++ b/framework/source/fwi/helper/mischelper.cxx @@ -53,7 +53,7 @@ uno::Reference< linguistic2::XLanguageGuessing > LanguageGuessingHelper::GetGues } catch (const uno::Exception &) { - DBG_ASSERT( false, "failed to get language guessing component" ); + SAL_WARN( "framework.fwi", "failed to get language guessing component" ); } } return m_xLanguageGuesser; diff --git a/framework/source/uiconfiguration/windowstateconfiguration.cxx b/framework/source/uiconfiguration/windowstateconfiguration.cxx index 71ddcfa9d427..9412302e06bb 100644 --- a/framework/source/uiconfiguration/windowstateconfiguration.cxx +++ b/framework/source/uiconfiguration/windowstateconfiguration.cxx @@ -592,7 +592,7 @@ Any ConfigurationAccess_WindowState::impl_getSequenceFromStruct( const WindowSta case PROPERTY_DOCKSIZE: aPropSeq[nIndex].Value = makeAny( rWinStateInfo.aDockSize ); break; default: - DBG_ASSERT( false, "Wrong value for ConfigurationAccess_WindowState. Who has forgotten to add this new property!" ); + assert( false && "Wrong value for ConfigurationAccess_WindowState. Who has forgotten to add this new property!" ); } } } @@ -772,7 +772,7 @@ Any ConfigurationAccess_WindowState::impl_insertCacheAndReturnSequence( const OU break; default: - DBG_ASSERT( false, "Wrong value for ConfigurationAccess_WindowState. Who has forgotten to add this new property!" ); + assert( false && "Wrong value for ConfigurationAccess_WindowState. Who has forgotten to add this new property!" ); } if ( bAddToSeq ) @@ -844,7 +844,7 @@ ConfigurationAccess_WindowState::WindowStateInfo& ConfigurationAccess_WindowStat case PROPERTY_CONTEXTACTIVE: aWindowStateInfo.bContextActive = bValue; break; default: - DBG_ASSERT( false, "Unknown boolean property in WindowState found!" ); + SAL_WARN( "framework.uiconfiguration", "Unknown boolean property in WindowState found!" ); } } } @@ -956,7 +956,7 @@ ConfigurationAccess_WindowState::WindowStateInfo& ConfigurationAccess_WindowStat break; default: - DBG_ASSERT( false, "Wrong value for ConfigurationAccess_WindowState. Who has forgotten to add this new property!" ); + assert( false && "Wrong value for ConfigurationAccess_WindowState. Who has forgotten to add this new property!" ); } } catch( const css::container::NoSuchElementException& ) @@ -1145,7 +1145,7 @@ void ConfigurationAccess_WindowState::impl_fillStructFromSequence( WindowStateIn break; default: - DBG_ASSERT( false, "Wrong value for ConfigurationAccess_WindowState. Who has forgotten to add this new property!" ); + assert( false && "Wrong value for ConfigurationAccess_WindowState. Who has forgotten to add this new property!" ); } break; @@ -1226,7 +1226,7 @@ void ConfigurationAccess_WindowState::impl_putPropertiesFromStruct( const Window case PROPERTY_STYLE: xPropSet->setPropertyValue( m_aPropArray[i], makeAny( sal_Int32( rWinStateInfo.nStyle )) ); break; default: - DBG_ASSERT( false, "Wrong value for ConfigurationAccess_WindowState. Who has forgotten to add this new property!" ); + assert( false && "Wrong value for ConfigurationAccess_WindowState. Who has forgotten to add this new property!" ); } } catch( const Exception& ) diff --git a/framework/source/uielement/langselectionstatusbarcontroller.cxx b/framework/source/uielement/langselectionstatusbarcontroller.cxx index 723aee1e3c8c..5133e4483b84 100644 --- a/framework/source/uielement/langselectionstatusbarcontroller.cxx +++ b/framework/source/uielement/langselectionstatusbarcontroller.cxx @@ -158,8 +158,8 @@ throw (css::uno::RuntimeException, std::exception) rStr != sAsterisk && !rStr.isEmpty()) // 'no language found' from language guessing { - DBG_ASSERT( MID_LANG_SEL_1 <= nItemId && nItemId <= MID_LANG_SEL_9, - "nItemId outside of expected range!" ); + SAL_WARN_IF( MID_LANG_SEL_1 > nItemId || nItemId > MID_LANG_SEL_9, + "framework.uielement", "nItemId outside of expected range!" ); xPopupMenu->insertItem( nItemId, rStr, 0, nItemId ); if ( rStr == m_aCurLang ) { @@ -186,8 +186,8 @@ throw (css::uno::RuntimeException, std::exception) rStr != sAsterisk && !rStr.isEmpty()) // 'no language found' from language guessing { - DBG_ASSERT( MID_LANG_PARA_1 <= nItemId && nItemId <= MID_LANG_PARA_9, - "nItemId outside of expected range!" ); + SAL_WARN_IF( MID_LANG_PARA_1 > nItemId || nItemId > MID_LANG_PARA_9, + "framework.uielement", "nItemId outside of expected range!" ); subPopupMenu->insertItem( nItemId, rStr, 0, nItemId ); aLangMap[nItemId] = rStr; ++nItemId; diff --git a/framework/source/uielement/menubarmanager.cxx b/framework/source/uielement/menubarmanager.cxx index a1ac05c8111f..cd4492f40fae 100644 --- a/framework/source/uielement/menubarmanager.cxx +++ b/framework/source/uielement/menubarmanager.cxx @@ -226,7 +226,7 @@ MenuBarManager::~MenuBarManager() m_xDeferedItemContainer.clear(); m_aAsyncSettingsTimer.Stop(); - DBG_ASSERT( OWeakObject::m_refCount == 0, "Who wants to delete an object with refcount > 0!" ); + SAL_WARN_IF( OWeakObject::m_refCount != 0, "framework.uielement", "Who wants to delete an object with refcount > 0!" ); } void MenuBarManager::Destroy() |