summaryrefslogtreecommitdiff
path: root/sfx2/source
diff options
context:
space:
mode:
authorChris Sherlock <chris.sherlock79@gmail.com>2017-05-07 17:03:35 +1000
committerChris Sherlock <chris.sherlock79@gmail.com>2017-05-07 17:03:35 +1000
commit97eb00c75e173d4c8d0b483a7941ad3d2f23783e (patch)
tree7974a8b9423c56982646366b0859dfb2a1a88d50 /sfx2/source
parentd0a99cc2ed76be220f7e868e332ba19f6e48a440 (diff)
revert OSL_ASSERT changes
Change-Id: I365d140446bd2a62cf8256acbfdd53fe72987380
Diffstat (limited to 'sfx2/source')
-rw-r--r--sfx2/source/appl/appuno.cxx2
-rw-r--r--sfx2/source/appl/shutdownicon.cxx2
-rw-r--r--sfx2/source/dialog/mailmodel.cxx6
-rw-r--r--sfx2/source/dialog/templdlg.cxx2
-rw-r--r--sfx2/source/sidebar/DeckLayouter.cxx8
-rw-r--r--sfx2/source/sidebar/DeckTitleBar.cxx2
-rw-r--r--sfx2/source/sidebar/PanelTitleBar.cxx2
-rw-r--r--sfx2/source/sidebar/SidebarController.cxx2
-rw-r--r--sfx2/source/sidebar/SidebarDockingWindow.cxx4
-rw-r--r--sfx2/source/sidebar/TabBar.cxx2
-rw-r--r--sfx2/source/sidebar/Theme.cxx16
-rw-r--r--sfx2/source/sidebar/TitleBar.cxx2
-rw-r--r--sfx2/source/toolbox/tbxitem.cxx4
-rw-r--r--sfx2/source/view/viewsh.cxx4
14 files changed, 29 insertions, 29 deletions
diff --git a/sfx2/source/appl/appuno.cxx b/sfx2/source/appl/appuno.cxx
index ac5a16aa92c2..d7bc5ff8d7b9 100644
--- a/sfx2/source/appl/appuno.cxx
+++ b/sfx2/source/appl/appuno.cxx
@@ -296,7 +296,7 @@ void TransformParameters( sal_uInt16 nSlotId, const uno::Sequence<beans::Propert
return;
}
- assert(nCount > 0);
+ OSL_ASSERT(nCount > 0);
#ifdef DBG_UTIL
// detect parameters that don't match to any formal argument or one of its members
diff --git a/sfx2/source/appl/shutdownicon.cxx b/sfx2/source/appl/shutdownicon.cxx
index 82e68a9e4af5..f6a537ec72bb 100644
--- a/sfx2/source/appl/shutdownicon.cxx
+++ b/sfx2/source/appl/shutdownicon.cxx
@@ -535,7 +535,7 @@ void ShutdownIcon::terminateDesktop()
ShutdownIcon* ShutdownIcon::getInstance()
{
- assert( pShutdownIcon );
+ OSL_ASSERT( pShutdownIcon );
return pShutdownIcon;
}
diff --git a/sfx2/source/dialog/mailmodel.cxx b/sfx2/source/dialog/mailmodel.cxx
index 385a6552030b..ac01c0fc6e6f 100644
--- a/sfx2/source/dialog/mailmodel.cxx
+++ b/sfx2/source/dialog/mailmodel.cxx
@@ -305,7 +305,7 @@ SfxMailModel::SaveResult SfxMailModel::SaveDocumentAsFormat(
bool bPrivateProtocol = ( aFileObj.GetProtocol() == INetProtocol::PrivSoffice );
bHasLocation = !aLocation.isEmpty() && !bPrivateProtocol;
- assert( !bPrivateProtocol );
+ OSL_ASSERT( !bPrivateProtocol );
}
if ( !rType.isEmpty() )
bStoreTo = true;
@@ -464,8 +464,8 @@ SfxMailModel::SaveResult SfxMailModel::SaveDocumentAsFormat(
if ( aFileName.isEmpty() )
return eRet;
- assert( !aFilterName.isEmpty() );
- assert( !aFileName.isEmpty() );
+ OSL_ASSERT( !aFilterName.isEmpty() );
+ OSL_ASSERT( !aFileName.isEmpty() );
// Creates a temporary directory to store a predefined file into it.
// This makes it possible to store the file for "send document as e-mail"
diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx
index 5fb7e5c78050..b2a323aa6fe7 100644
--- a/sfx2/source/dialog/templdlg.cxx
+++ b/sfx2/source/dialog/templdlg.cxx
@@ -341,7 +341,7 @@ SfxTemplatePanelControl::SfxTemplatePanelControl(SfxBindings* pBindings, vcl::Wi
, pImpl(new SfxTemplateDialog_Impl(pBindings, this))
, mpBindings(pBindings)
{
- assert(mpBindings!=nullptr);
+ OSL_ASSERT(mpBindings!=nullptr);
SetStyle(GetStyle() & ~WB_DOCKABLE);
}
diff --git a/sfx2/source/sidebar/DeckLayouter.cxx b/sfx2/source/sidebar/DeckLayouter.cxx
index 1721fd1b405e..5a37474148c5 100644
--- a/sfx2/source/sidebar/DeckLayouter.cxx
+++ b/sfx2/source/sidebar/DeckLayouter.cxx
@@ -302,7 +302,7 @@ sal_Int32 PlacePanels (
nPanelHeight = iItem->maLayoutSize.Preferred;
break;
default:
- assert(false);
+ OSL_ASSERT(false);
break;
}
@@ -453,7 +453,7 @@ void DistributeHeights (
if (nRemainingHeightToDistribute == 0)
return;
- assert(nRemainingHeightToDistribute > 0);
+ OSL_ASSERT(nRemainingHeightToDistribute > 0);
// It is possible that not all of the height could be distributed
// because of Maximum heights being smaller than expected.
@@ -480,7 +480,7 @@ void DistributeHeights (
}
}
- assert(nRemainingHeightToDistribute==0);
+ OSL_ASSERT(nRemainingHeightToDistribute==0);
}
tools::Rectangle PlaceDeckTitle (
@@ -542,7 +542,7 @@ void SetupVerticalScrollBar(
const sal_Int32 nContentHeight,
const sal_Int32 nVisibleHeight)
{
- assert(nContentHeight > nVisibleHeight);
+ OSL_ASSERT(nContentHeight > nVisibleHeight);
rVerticalScrollBar.SetRangeMin(0);
rVerticalScrollBar.SetRangeMax(nContentHeight-1);
diff --git a/sfx2/source/sidebar/DeckTitleBar.cxx b/sfx2/source/sidebar/DeckTitleBar.cxx
index 2f67fb100117..fe4d0b2aae6e 100644
--- a/sfx2/source/sidebar/DeckTitleBar.cxx
+++ b/sfx2/source/sidebar/DeckTitleBar.cxx
@@ -44,7 +44,7 @@ DeckTitleBar::DeckTitleBar (const OUString& rsTitle,
, maCloserAction(rCloserAction)
, mbIsCloserVisible(false)
{
- assert(pParentWindow != nullptr);
+ OSL_ASSERT(pParentWindow != nullptr);
if (maCloserAction)
SetCloserVisible(true);
diff --git a/sfx2/source/sidebar/PanelTitleBar.cxx b/sfx2/source/sidebar/PanelTitleBar.cxx
index e46f001f3459..fcb5e8f0ff6a 100644
--- a/sfx2/source/sidebar/PanelTitleBar.cxx
+++ b/sfx2/source/sidebar/PanelTitleBar.cxx
@@ -49,7 +49,7 @@ PanelTitleBar::PanelTitleBar(const OUString& rsTitle,
mxFrame(),
msMoreOptionsCommand()
{
- assert(mpPanel != nullptr);
+ OSL_ASSERT(mpPanel != nullptr);
#ifdef DEBUG
SetText(OUString("PanelTitleBar"));
diff --git a/sfx2/source/sidebar/SidebarController.cxx b/sfx2/source/sidebar/SidebarController.cxx
index f3b83bda9d1c..b21be2dfbc05 100644
--- a/sfx2/source/sidebar/SidebarController.cxx
+++ b/sfx2/source/sidebar/SidebarController.cxx
@@ -336,7 +336,7 @@ void SidebarController::NotifyResize()
{
if (!mpTabBar)
{
- assert(mpTabBar!=nullptr);
+ OSL_ASSERT(mpTabBar!=nullptr);
return;
}
diff --git a/sfx2/source/sidebar/SidebarDockingWindow.cxx b/sfx2/source/sidebar/SidebarDockingWindow.cxx
index e350f1e52166..84a2834e5a34 100644
--- a/sfx2/source/sidebar/SidebarDockingWindow.cxx
+++ b/sfx2/source/sidebar/SidebarDockingWindow.cxx
@@ -37,8 +37,8 @@ SidebarDockingWindow::SidebarDockingWindow(SfxBindings* pSfxBindings, SidebarChi
// Get the XFrame from the bindings.
if (pSfxBindings==nullptr || pSfxBindings->GetDispatcher()==nullptr)
{
- assert(pSfxBindings!=nullptr);
- assert(pSfxBindings->GetDispatcher()!=nullptr);
+ OSL_ASSERT(pSfxBindings!=nullptr);
+ OSL_ASSERT(pSfxBindings->GetDispatcher()!=nullptr);
}
else
{
diff --git a/sfx2/source/sidebar/TabBar.cxx b/sfx2/source/sidebar/TabBar.cxx
index 4e6830f8c6f6..7d4ee1419ef0 100644
--- a/sfx2/source/sidebar/TabBar.cxx
+++ b/sfx2/source/sidebar/TabBar.cxx
@@ -122,7 +122,7 @@ void TabBar::SetDecks(const ResourceManager::DeckContextDescriptorContainer& rDe
std::shared_ptr<DeckDescriptor> xDescriptor = pParentSidebarController->GetResourceManager()->GetDeckDescriptor(iDeck->msId);
if (xDescriptor == nullptr)
{
- assert(xDescriptor!=nullptr);
+ OSL_ASSERT(xDescriptor!=nullptr);
continue;
}
diff --git a/sfx2/source/sidebar/Theme.cxx b/sfx2/source/sidebar/Theme.cxx
index db73bc21e273..2b29083f5bd9 100644
--- a/sfx2/source/sidebar/Theme.cxx
+++ b/sfx2/source/sidebar/Theme.cxx
@@ -61,7 +61,7 @@ Theme::~Theme()
Image Theme::GetImage (const ThemeItem eItem)
{
const PropertyType eType (GetPropertyType(eItem));
- assert(eType==PT_Image);
+ OSL_ASSERT(eType==PT_Image);
const sal_Int32 nIndex (GetIndex(eItem, eType));
const Theme& rTheme (GetCurrentTheme());
return rTheme.maImages[nIndex];
@@ -70,7 +70,7 @@ Image Theme::GetImage (const ThemeItem eItem)
Color Theme::GetColor (const ThemeItem eItem)
{
const PropertyType eType (GetPropertyType(eItem));
- assert(eType==PT_Color || eType==PT_Paint);
+ OSL_ASSERT(eType==PT_Color || eType==PT_Paint);
const sal_Int32 nIndex (GetIndex(eItem, eType));
const Theme& rTheme (GetCurrentTheme());
if (eType == PT_Color)
@@ -84,7 +84,7 @@ Color Theme::GetColor (const ThemeItem eItem)
const Paint& Theme::GetPaint (const ThemeItem eItem)
{
const PropertyType eType (GetPropertyType(eItem));
- assert(eType==PT_Paint);
+ OSL_ASSERT(eType==PT_Paint);
const sal_Int32 nIndex (GetIndex(eItem, eType));
const Theme& rTheme (GetCurrentTheme());
return rTheme.maPaints[nIndex];
@@ -98,7 +98,7 @@ const Wallpaper Theme::GetWallpaper (const ThemeItem eItem)
sal_Int32 Theme::GetInteger (const ThemeItem eItem)
{
const PropertyType eType (GetPropertyType(eItem));
- assert(eType==PT_Integer);
+ OSL_ASSERT(eType==PT_Integer);
const sal_Int32 nIndex (GetIndex(eItem, eType));
const Theme& rTheme (GetCurrentTheme());
return rTheme.maIntegers[nIndex];
@@ -107,7 +107,7 @@ sal_Int32 Theme::GetInteger (const ThemeItem eItem)
bool Theme::GetBoolean (const ThemeItem eItem)
{
const PropertyType eType (GetPropertyType(eItem));
- assert(eType==PT_Boolean);
+ OSL_ASSERT(eType==PT_Boolean);
const sal_Int32 nIndex (GetIndex(eItem, eType));
const Theme& rTheme (GetCurrentTheme());
return rTheme.maBooleans[nIndex];
@@ -337,7 +337,7 @@ void Theme::UpdateTheme()
catch(beans::UnknownPropertyException& rException)
{
SAL_WARN("sfx", "unknown property: " << rException.Message);
- assert(false);
+ OSL_ASSERT(false);
}
}
@@ -884,7 +884,7 @@ sal_Int32 Theme::GetIndex (const ThemeItem eItem, const PropertyType eType)
return eItem - Bool_Rect_-1;
default:
- assert(false);
+ OSL_ASSERT(false);
return 0;
}
}
@@ -1049,7 +1049,7 @@ void Theme::ProcessNewValue (
break;
}
case PT_Invalid:
- assert(eType != PT_Invalid);
+ OSL_ASSERT(eType != PT_Invalid);
throw RuntimeException();
}
}
diff --git a/sfx2/source/sidebar/TitleBar.cxx b/sfx2/source/sidebar/TitleBar.cxx
index e03f382bc246..22433123cd4c 100644
--- a/sfx2/source/sidebar/TitleBar.cxx
+++ b/sfx2/source/sidebar/TitleBar.cxx
@@ -167,7 +167,7 @@ void TitleBar::PaintFocus(vcl::RenderContext& rRenderContext, const tools::Recta
IMPL_LINK(TitleBar, SelectionHandler, ToolBox*, pToolBox, void)
{
(void)pToolBox;
- assert(maToolBox.get()==pToolBox);
+ OSL_ASSERT(maToolBox.get()==pToolBox);
const sal_uInt16 nItemId (maToolBox->GetHighlightItemId());
HandleToolBoxItemClick(nItemId);
diff --git a/sfx2/source/toolbox/tbxitem.cxx b/sfx2/source/toolbox/tbxitem.cxx
index 74ee50a7f3e8..5aed453f2392 100644
--- a/sfx2/source/toolbox/tbxitem.cxx
+++ b/sfx2/source/toolbox/tbxitem.cxx
@@ -104,7 +104,7 @@ SFX_IMPL_TOOLBOX_CONTROL_ARG(SfxToolBoxControl, SfxStringItem, true);
static vcl::Window* GetTopMostParentSystemWindow( vcl::Window* pWindow )
{
- assert( pWindow );
+ OSL_ASSERT( pWindow );
if ( pWindow )
{
// ->manually search topmost system window
@@ -118,7 +118,7 @@ static vcl::Window* GetTopMostParentSystemWindow( vcl::Window* pWindow )
pWindow = pWindow->GetParent();
}
pWindow = pTopMostSysWin;
- assert( pWindow );
+ OSL_ASSERT( pWindow );
return pWindow;
}
diff --git a/sfx2/source/view/viewsh.cxx b/sfx2/source/view/viewsh.cxx
index c73877ff5b57..dfb636d2e3a9 100644
--- a/sfx2/source/view/viewsh.cxx
+++ b/sfx2/source/view/viewsh.cxx
@@ -633,8 +633,8 @@ void SfxViewShell::ExecMisc_Impl( SfxRequest &rReq )
aFileName = aFObj.getName( INetURLObject::LAST_SEGMENT, true, INetURLObject::DecodeMechanism::NONE );
}
- assert( !aFilterName.isEmpty() );
- assert( !aFileName.isEmpty() );
+ OSL_ASSERT( !aFilterName.isEmpty() );
+ OSL_ASSERT( !aFileName.isEmpty() );
// Creates a temporary directory to store our predefined file into it.
::utl::TempFile aTempDir( nullptr, true );