diff options
author | Chris Sherlock <chris.sherlock79@gmail.com> | 2017-05-07 17:03:35 +1000 |
---|---|---|
committer | Chris Sherlock <chris.sherlock79@gmail.com> | 2017-05-07 17:03:35 +1000 |
commit | 97eb00c75e173d4c8d0b483a7941ad3d2f23783e (patch) | |
tree | 7974a8b9423c56982646366b0859dfb2a1a88d50 /sfx2/source/sidebar | |
parent | d0a99cc2ed76be220f7e868e332ba19f6e48a440 (diff) |
revert OSL_ASSERT changes
Change-Id: I365d140446bd2a62cf8256acbfdd53fe72987380
Diffstat (limited to 'sfx2/source/sidebar')
-rw-r--r-- | sfx2/source/sidebar/DeckLayouter.cxx | 8 | ||||
-rw-r--r-- | sfx2/source/sidebar/DeckTitleBar.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/sidebar/PanelTitleBar.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/sidebar/SidebarController.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/sidebar/SidebarDockingWindow.cxx | 4 | ||||
-rw-r--r-- | sfx2/source/sidebar/TabBar.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/sidebar/Theme.cxx | 16 | ||||
-rw-r--r-- | sfx2/source/sidebar/TitleBar.cxx | 2 |
8 files changed, 19 insertions, 19 deletions
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); |