Salome HOME
Join modifications from branch OCC_development_for_3_2_0a2
[modules/smesh.git] / src / SMESHGUI / SMESHGUI_TranslationDlg.cxx
index 6ea4bbf29ab2ab2730ae5ac089f59966caed990c..a4e006c4f29e748c68774c5d442a58b1005c3cf6 100644 (file)
@@ -293,13 +293,10 @@ SMESHGUI_TranslationDlg::SMESHGUI_TranslationDlg( SMESHGUI* theModule, const cha
   connect(LineEditElements, SIGNAL(textChanged(const QString&)),    SLOT(onTextChange(const QString&)));
   connect(CheckBoxMesh,     SIGNAL(toggled(bool)),                  SLOT(onSelectMesh(bool)));
 
-  /* Move widget on the botton right corner of main widget */
-  int x, y;
-  mySMESHGUI->DefineDlgPosition(this, x, y);
-  this->move(x, y);
   this->show(); /* displays Dialog */
 
   ConstructorsClicked(0);
+  SelectionIntoArgument();
   resize(0,0); // ??
 }
 
@@ -447,10 +444,10 @@ void SMESHGUI_TranslationDlg::ClickOnApply()
     } catch (...) {
     }
 
-    mySelectionMgr->clearSelected();
     SMESH::UpdateView();
     Init(false);
     ConstructorsClicked(GetConstructorId());
+    SelectionIntoArgument();
   }
 }
 
@@ -472,7 +469,7 @@ void SMESHGUI_TranslationDlg::ClickOnCancel()
 {
   disconnect(mySelectionMgr, 0, this, 0);
   mySelectionMgr->clearFilters();
-  mySelectionMgr->clearSelected();
+  //mySelectionMgr->clearSelected();
   SMESH::SetPointRepresentation(false);
   if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))
     aViewWindow->SetSelectionMode( ActorSelection );
@@ -624,7 +621,7 @@ void SMESHGUI_TranslationDlg::SelectionIntoArgument()
         aNbUnits = anElementsIds->length();
       }
     } else {
-      aNbUnits = SMESH::GetNameOfSelectedElements(mySelector, myActor->getIO(), aString);
+      aNbUnits = SMESH::GetNameOfSelectedElements(mySelector, IO, aString);
       myElementsId = aString;
     }