Salome HOME
Fix for the issue #2753 : error when dump/load script
[modules/shaper.git] / src / SHAPERGUI / SHAPERGUI_SalomeViewer.cpp
index 37148b5a3b9025ec68fcd0aa1d7d04a55c093ddf..58cb99b4ccb86062964ea8fd29032f541d3de0e7 100644 (file)
@@ -376,6 +376,8 @@ void SHAPERGUI_SalomeViewer::fitAll()
 void SHAPERGUI_SalomeViewer::eraseAll()
 {
   Handle(AIS_InteractiveContext) aContext = AISContext();
+  if (aContext.IsNull())
+    return;
   AIS_ListOfInteractive aList;
   aContext->DisplayedObjects(aList);
   AIS_ListIteratorOfListOfInteractive aLIt;