Salome HOME
PAL13330( When mesh generation does not success, trace where )
authoreap <eap@opencascade.com>
Tue, 10 Apr 2007 14:11:29 +0000 (14:11 +0000)
committereap <eap@opencascade.com>
Tue, 10 Apr 2007 14:11:29 +0000 (14:11 +0000)
-  void ModifiedMesh (_PTR(SObject) theSObject, bool theIsRight);
+  void ModifiedMesh (_PTR(SObject) theSObject, bool theIsNot, bool isEmptyMesh=false);
+      aPixmap->SetPixMap("ICON_SMESH_TREE_MESH_PARTIAL");

src/SMESHGUI/SMESHGUI_Utils.cxx
src/SMESHGUI/SMESHGUI_Utils.h

index 8eff141c8eedc495de079a517dc60cedfcc7d325..6ef3fddaba7a997dc382efafca8821f0239269cd 100644 (file)
@@ -254,7 +254,7 @@ namespace SMESH{
     return theSObject->GetFather();
   }
 
-  void ModifiedMesh (_PTR(SObject) theSObject, bool theIsRight)
+  void ModifiedMesh (_PTR(SObject) theSObject, bool theIsNotModif, bool isEmptyMesh)
   {
     _PTR(Study) aStudy = GetActiveStudyDocument();
     if (aStudy->GetProperties()->IsLocked())
@@ -264,10 +264,12 @@ namespace SMESH{
     _PTR(GenericAttribute) anAttr =
       aBuilder->FindOrCreateAttribute(theSObject,"AttributePixMap");
     _PTR(AttributePixMap) aPixmap = anAttr;
-    if (theIsRight) {
+    if (theIsNotModif) {
       aPixmap->SetPixMap("ICON_SMESH_TREE_MESH");
-    } else {
+    } else if ( isEmptyMesh ) {
       aPixmap->SetPixMap("ICON_SMESH_TREE_MESH_WARN");
+    } else {
+      aPixmap->SetPixMap("ICON_SMESH_TREE_MESH_PARTIAL");
     }
 
     _PTR(ChildIterator) anIter = aStudy->NewChildIterator(theSObject);
@@ -279,11 +281,13 @@ namespace SMESH{
          _PTR(SObject) aSObj1 = anIter1->Value();
          anAttr = aBuilder->FindOrCreateAttribute(aSObj1, "AttributePixMap");
          aPixmap = anAttr;
-         if (theIsRight) {
-           aPixmap->SetPixMap("ICON_SMESH_TREE_MESH");
-         } else {
-           aPixmap->SetPixMap("ICON_SMESH_TREE_MESH_WARN");
-         }
+          if (theIsNotModif) {
+            aPixmap->SetPixMap("ICON_SMESH_TREE_MESH");
+          } else if ( isEmptyMesh ) {
+            aPixmap->SetPixMap("ICON_SMESH_TREE_MESH_WARN");
+          } else {
+            aPixmap->SetPixMap("ICON_SMESH_TREE_MESH_PARTIAL");
+          }
        }
       }
     }
index 7f549cb2b7763aca144ce1bce45efae38487f6c2..241731b66a3aa1ebbc730fac776e26566569db19 100644 (file)
@@ -124,7 +124,7 @@ namespace SMESH {
 
   _PTR(SObject) GetMeshOrSubmesh (_PTR(SObject) theSObject);
 
-  void ModifiedMesh (_PTR(SObject) theSObject, bool theIsRight);
+  void ModifiedMesh (_PTR(SObject) theSObject, bool theIsNot, bool isEmptyMesh=false);
 
   void ShowHelpFile (QString theHelpFileName);
 }