Salome HOME
debug IPAL9411: redefine virtual methods createEmptyStudy and activateModule
[modules/gui.git] / src / CAM / CAM_Application.cxx
index f8ca14f3b13b36336438e7ea4f1dc52ea9f6a8da..d13c53ef5f85fca528ab2b5cc740e1185b53a79f 100755 (executable)
@@ -396,3 +396,18 @@ void CAM_Application::contextMenuPopup( const QString& type, QPopupMenu* thePopu
   if ( activeModule() ) 
     activeModule()->contextMenuPopup( type, thePopup, title );
 }
+
+void CAM_Application::createEmptyStudy()
+{
+  SUIT_Study* study = activeStudy();
+
+  STD_Application::createEmptyStudy();
+
+  SUIT_Study* newStudy = activeStudy();
+  if ( study != newStudy ) 
+  {
+    CAM_Study* camStudy = dynamic_cast<CAM_Study*>( newStudy );
+    for ( ModuleListIterator it( myModules ); it.current(); ++it )
+      camStudy->insertDataModel( it.current()->dataModel() );
+  }
+}