]> SALOME platform Git repositories - modules/geom.git/commitdiff
Salome HOME
Fix for the bug IPAL22807:"TC6.4.0: input objects are not highlighted in 3D viewer"
authorana <ana@opencascade.com>
Tue, 6 Mar 2012 15:16:18 +0000 (15:16 +0000)
committerana <ana@opencascade.com>
Tue, 6 Mar 2012 15:16:18 +0000 (15:16 +0000)
src/PrimitiveGUI/PrimitiveGUI_BoxDlg.cxx

index 207a66339d1e98df28227ec1555f64bf4fe99dd7..6bbc7b0f4feafd5850015f8ed0ddff0b62559d29 100644 (file)
@@ -251,24 +251,24 @@ void PrimitiveGUI_BoxDlg::SelectionIntoArgument()
     QString aName = GEOMBase::GetName( aSelectedObject.get() );
 
     myEditCurrentArgument->setText(aName);
-
-    // clear selection
-    disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);
-    myGeomGUI->getApp()->selectionMgr()->clearSelected();
-    connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
-           this, SLOT(SelectionIntoArgument()));
-    
     if (myEditCurrentArgument == GroupPoints->LineEdit1) {
       myPoint1 = aSelectedObject;
       if (myPoint1 && !myPoint2)
-       GroupPoints->PushButton2->click();
+        GroupPoints->PushButton2->click();
     }
     else if (myEditCurrentArgument == GroupPoints->LineEdit2) {
       myPoint2 = aSelectedObject;
       if (myPoint2 && !myPoint1)
-       GroupPoints->PushButton1->click();
+        GroupPoints->PushButton1->click();
+    }
+    if ((myPoint1 && !myPoint2) || (myPoint2 && !myPoint1)) {
+      // clear selection
+      disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);
+      myGeomGUI->getApp()->selectionMgr()->clearSelected();
+      connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
+        this, SLOT(SelectionIntoArgument()));
     }
-    
   }
   displayPreview(true);
 }