]> SALOME platform Git repositories - modules/smesh.git/commitdiff
Salome HOME
Update for bug IPAL19574.
authorskl <skl@opencascade.com>
Thu, 19 Jun 2008 05:35:18 +0000 (05:35 +0000)
committerskl <skl@opencascade.com>
Thu, 19 Jun 2008 05:35:18 +0000 (05:35 +0000)
src/SMESHGUI/SMESHGUI_GroupDlg.cxx

index 07f9587fb1bf0ca0cafbbeda66c067cf27c11590..4c254fa74e77a68bb3c2962bddb50513036e3e7d 100644 (file)
@@ -1159,15 +1159,22 @@ void SMESHGUI_GroupDlg::onObjectSelectionChanged()
          aString = tr("SMESH_GROUP_SELECTED").arg(aNbSel);
        else if(myCurrentLineEdit == myGeomGroupLine)
          aString = tr("%1 Objects").arg(aNbSel);
-      } else {
+      }
+      else {
        aString = aList.First()->getName();
       }
     }
 
     myCurrentLineEdit->setText(aString);
-    myOldName = myName->text();
-    myName->setText(aString);
     myCurrentLineEdit->home(false);
+    // 07.06.2008 skl for IPAL19574:
+    // change name of group only if it is empty
+    QString tmp = myName->text();
+    tmp.stripWhiteSpace();
+    if(tmp.isEmpty()) {
+      myOldName = myName->text();
+      myName->setText(aString);
+    }
 
     updateButtons();