Salome HOME
PAL9878 - selection lost after some operations
[modules/smesh.git] / src / SMESHGUI / SMESHGUI_CreatePatternDlg.cxx
index 6b1f20e1287f6a4d3fcc29085ff6ff2aab22c77c..d2146e01e5c39b2baa6997dc32d551afe780a0d2 100755 (executable)
@@ -42,8 +42,8 @@
 #include "SUIT_FileDlg.h"\r
 \r
 #include "SalomeApp_Study.h"\r
-#include "SalomeApp_DataOwner.h"\r
-#include "SalomeApp_SelectionMgr.h"\r
+#include "LightApp_DataOwner.h"\r
+#include "LightApp_SelectionMgr.h"\r
 #include "SalomeApp_Tools.h"\r
 \r
 #include "SALOMEDS_SObject.hxx"\r
@@ -290,7 +290,7 @@ void SMESHGUI_CreatePatternDlg::SetMesh (SMESH::SMESH_Mesh_ptr thePtr)
     _PTR(SObject) aSobj = SMESH::FindSObject(myMesh.in());\r
     //Handle(SALOME_InteractiveObject) anIObj =\r
     //  new SALOME_InteractiveObject(aSobj->GetID().c_str(), "SMESH");\r
-    SUIT_DataOwnerPtr anIObj (new SalomeApp_DataOwner(aSobj->GetID().c_str()));\r
+    SUIT_DataOwnerPtr anIObj (new LightApp_DataOwner(aSobj->GetID().c_str()));\r
 \r
     isValidMesh = mySelectionMgr->isOk(anIObj);\r
   }\r
@@ -389,7 +389,8 @@ void SMESHGUI_CreatePatternDlg::onSave()
       //SUIT_Application::getDesktop()->setSelectionModes(ActorSelection);\r
       if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))\r
        aViewWindow->SetSelectionMode(ActorSelection);\r
-      disconnect(mySelectionMgr, 0, this, 0);\r
+      //disconnect(mySelectionMgr, 0, this, 0);\r
+      disconnect(mySelectionMgr, SIGNAL(currentSelectionChanged()), this, SLOT(onSelectionDone()));\r
       disconnect(mySMESHGUI, 0, this, 0);\r
       mySMESHGUI->ResetState();\r
       accept();\r