]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Issue #963 Constraint is blinking during movement
authornds <nds@opencascade.com>
Thu, 17 Sep 2015 13:02:35 +0000 (16:02 +0300)
committernds <nds@opencascade.com>
Thu, 17 Sep 2015 13:12:01 +0000 (16:12 +0300)
It is necessary to check the previous state of the enable flag. SALOME unconditionally call ClearSelection by the enable selection state change if the new state is false.

src/NewGeom/NewGeom_SalomeViewer.cpp

index 67d2946cb64d58c7fa62d7a9b841a2578190a19b..87a81a6255780fc97ec1548b806cd78a067b3bdf 100644 (file)
@@ -244,7 +244,8 @@ void NewGeom_SalomeViewer::onActivated(SUIT_ViewManager* theMgr)
 void NewGeom_SalomeViewer::enableSelection(bool isEnabled)
 {
   if (mySelector)
-    mySelector->viewer()->enableSelection(isEnabled);
+    if (mySelector->viewer()->isSelectionEnabled() != isEnabled)
+      mySelector->viewer()->enableSelection(isEnabled);
   // The enableSelection() in SALOME 7.5 cause of forced Viewer update(we have blinking)
   // After this is corrected, the first row should be recommented, the last - removed
     //mySelector->viewer()->setInteractionStyle(isEnabled ? SUIT_ViewModel::STANDARD