summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-10-19 12:22:03 +0200
committerNoel Grandin <noel@peralex.com>2015-10-19 13:08:29 +0200
commitc8479bdc5b007ca5ffe1d553be3d90fb03424526 (patch)
treef927ba8085da8c9dc46d1cda669fbac8af724abf /vcl
parent39e63bfac528d8c5c002ee8fef4a1e5d7181b826 (diff)
convert DBG_ASSERTWARNING to SAL_WARN_IF
I know the comment in debug.hxx said to use SAL_INFO, but SAL_WARN makes much more sense. Change-Id: I3d81f9db89ef8cebe1e4f2983941d69b4c7e6b7d
Diffstat (limited to 'vcl')
-rw-r--r--vcl/source/control/prgsbar.cxx2
-rw-r--r--vcl/source/gdi/jobset.cxx4
-rw-r--r--vcl/source/outdev/map.cxx6
-rw-r--r--vcl/source/outdev/text.cxx2
-rw-r--r--vcl/source/window/mouse.cxx2
-rw-r--r--vcl/source/window/status.cxx2
-rw-r--r--vcl/source/window/winproc.cxx2
7 files changed, 10 insertions, 10 deletions
diff --git a/vcl/source/control/prgsbar.cxx b/vcl/source/control/prgsbar.cxx
index 2e1dce50bea0..c13c14ed0be5 100644
--- a/vcl/source/control/prgsbar.cxx
+++ b/vcl/source/control/prgsbar.cxx
@@ -164,7 +164,7 @@ void ProgressBar::Resize()
void ProgressBar::SetValue( sal_uInt16 nNewPercent )
{
- DBG_ASSERTWARNING( nNewPercent <= 100, "StatusBar::SetProgressValue(): nPercent > 100" );
+ SAL_WARN_IF( nNewPercent > 100, "vcl", "StatusBar::SetProgressValue(): nPercent > 100" );
if ( nNewPercent < mnPercent )
{
diff --git a/vcl/source/gdi/jobset.cxx b/vcl/source/gdi/jobset.cxx
index 4d9b49949e99..62049b5a823c 100644
--- a/vcl/source/gdi/jobset.cxx
+++ b/vcl/source/gdi/jobset.cxx
@@ -217,7 +217,7 @@ bool JobSetup::operator==( const JobSetup& rJobSetup ) const
SvStream& ReadJobSetup( SvStream& rIStream, JobSetup& rJobSetup )
{
- DBG_ASSERTWARNING( rIStream.GetVersion(), "JobSetup::>> - Solar-Version not set on rOStream" );
+ SAL_WARN_IF( !rIStream.GetVersion(), "vcl", "JobSetup::>> - Solar-Version not set on rOStream" );
{
sal_uInt16 nLen = 0;
@@ -311,7 +311,7 @@ SvStream& ReadJobSetup( SvStream& rIStream, JobSetup& rJobSetup )
SvStream& WriteJobSetup( SvStream& rOStream, const JobSetup& rJobSetup )
{
- DBG_ASSERTWARNING( rOStream.GetVersion(), "JobSetup::<< - Solar-Version not set on rOStream" );
+ SAL_WARN_IF( !rOStream.GetVersion(), "vcl", "JobSetup::<< - Solar-Version not set on rOStream" );
// We do not have a new FileFormat at this point in time
// #define JOBSET_FILEFORMAT2 3780
diff --git a/vcl/source/outdev/map.cxx b/vcl/source/outdev/map.cxx
index 96d96e43ec02..4e84033789fc 100644
--- a/vcl/source/outdev/map.cxx
+++ b/vcl/source/outdev/map.cxx
@@ -708,7 +708,7 @@ void OutputDevice::SetMapMode( const MapMode& rNewMapMode )
mpMetaFile->AddAction( new MetaMapModeAction( rNewMapMode ) );
#ifdef DBG_UTIL
if ( GetOutDevType() != OUTDEV_PRINTER )
- DBG_ASSERTWARNING( bRelMap, "Please record only relative MapModes!" );
+ SAL_WARN_IF( !bRelMap, "vcl", "Please record only relative MapModes!" );
#endif
}
@@ -1516,9 +1516,9 @@ static void verifyUnitSourceDest( MapUnit eUnitSource, MapUnit eUnitDest )
&& eUnitDest != MAP_APPFONT
&& eUnitDest != MAP_RELATIVE,
"Destination MapUnit nicht erlaubt" );
- DBG_ASSERTWARNING( eUnitSource != MAP_PIXEL,
+ SAL_WARN_IF( eUnitSource == MAP_PIXEL, "vcl",
"MAP_PIXEL mit 72dpi angenaehert" );
- DBG_ASSERTWARNING( eUnitDest != MAP_PIXEL,
+ SAL_WARN_IF( eUnitDest == MAP_PIXEL, "vcl",
"MAP_PIXEL mit 72dpi angenaehert" );
}
diff --git a/vcl/source/outdev/text.cxx b/vcl/source/outdev/text.cxx
index d8757e057dd3..d03f3cb106c8 100644
--- a/vcl/source/outdev/text.cxx
+++ b/vcl/source/outdev/text.cxx
@@ -496,7 +496,7 @@ long OutputDevice::ImplGetTextLines( ImplMultiTextLineInfo& rLineInfo,
long nWidth, const OUString& rStr,
DrawTextFlags nStyle, const vcl::ITextLayout& _rLayout )
{
- DBG_ASSERTWARNING( nWidth >= 0, "ImplGetTextLines: nWidth <= 0!" );
+ SAL_WARN_IF( nWidth <= 0, "vcl", "ImplGetTextLines: nWidth <= 0!" );
if ( nWidth <= 0 )
nWidth = 1;
diff --git a/vcl/source/window/mouse.cxx b/vcl/source/window/mouse.cxx
index d0556a98ed75..ad6c460d6d91 100644
--- a/vcl/source/window/mouse.cxx
+++ b/vcl/source/window/mouse.cxx
@@ -468,7 +468,7 @@ void Window::ReleaseMouse()
ImplSVData* pSVData = ImplGetSVData();
- DBG_ASSERTWARNING( pSVData->maWinData.mpCaptureWin.get() == this,
+ SAL_WARN_IF( pSVData->maWinData.mpCaptureWin.get() != this, "vcl",
"Window::ReleaseMouse(): window doesn't have the mouse capture" );
if ( pSVData->maWinData.mpCaptureWin.get() == this )
diff --git a/vcl/source/window/status.cxx b/vcl/source/window/status.cxx
index 472c837361e2..c4a349012faf 100644
--- a/vcl/source/window/status.cxx
+++ b/vcl/source/window/status.cxx
@@ -1374,7 +1374,7 @@ void StatusBar::StartProgressMode( const OUString& rText )
void StatusBar::SetProgressValue( sal_uInt16 nNewPercent )
{
DBG_ASSERT( mbProgressMode, "StatusBar::SetProgressValue(): no progrss mode" );
- DBG_ASSERTWARNING( nNewPercent <= 100, "StatusBar::SetProgressValue(): nPercent > 100" );
+ SAL_WARN_IF( nNewPercent > 100, "vcl", "StatusBar::SetProgressValue(): nPercent > 100" );
if ( mbProgressMode
&& IsReallyVisible()
diff --git a/vcl/source/window/winproc.cxx b/vcl/source/window/winproc.cxx
index 16696ec38694..33aa9fbb9cf2 100644
--- a/vcl/source/window/winproc.cxx
+++ b/vcl/source/window/winproc.cxx
@@ -859,7 +859,7 @@ static vcl::Window* ImplGetKeyInputWindow( vcl::Window* pWindow )
// system this is often the case when a Lookup Choice Window has
// the focus - because this windows send the KeyInput directly to
// the window without resetting the focus
- DBG_ASSERTWARNING( pChild == pSVData->maWinData.mpFocusWin,
+ SAL_WARN_IF( pChild != pSVData->maWinData.mpFocusWin, "vcl",
"ImplHandleKey: Keyboard-Input is sent to a frame without focus" );
// no keyinput to disabled windows