From 49f10e92dc1a9bd563f4a8620f6e6019e5d6a683 Mon Sep 17 00:00:00 2001 From: Takeshi Abe Date: Wed, 4 Jan 2017 18:20:11 +0900 Subject: starmath: SmGraphicWindow requires non-null pViewShell Change-Id: Ic1e0f3f7aefb801cdda4709c3d43794ad9a21b02 Reviewed-on: https://gerrit.libreoffice.org/32722 Reviewed-by: Michael Stahl Tested-by: Michael Stahl --- starmath/source/view.cxx | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'starmath/source') diff --git a/starmath/source/view.cxx b/starmath/source/view.cxx index e04640009092..0311b1b09ad3 100644 --- a/starmath/source/view.cxx +++ b/starmath/source/view.cxx @@ -99,6 +99,7 @@ SmGraphicWindow::SmGraphicWindow(SmViewShell* pShell) , pViewShell(pShell) , nZoom(100) { + assert(pViewShell); // docking windows are usually hidden (often already done in the // resource) and will be shown by the sfx framework. Hide(); @@ -370,8 +371,6 @@ const SmNode * SmGraphicWindow::SetCursorPos(sal_uInt16 nRow, sal_uInt16 nCol) void SmGraphicWindow::Paint(vcl::RenderContext& rRenderContext, const Rectangle&) { - SAL_WARN_IF(!pViewShell, "starmath", "view shell missing"); - ApplyColorConfigValues(SM_MOD()->GetColorConfig()); SmDocShell& rDoc = *pViewShell->GetDoc(); @@ -547,7 +546,6 @@ void SmGraphicWindow::Command(const CommandEvent& rCEvt) Point aPos(5, 5); if (rCEvt.IsMouseEvent()) aPos = rCEvt.GetMousePosPixel(); - SAL_WARN_IF( !pViewShell, "starmath", "view shell missing" ); // added for replaceability of context menus SfxDispatcher::ExecutePopup( this, &aPos ); -- cgit