Salome HOME
PAL13330( When mesh generation does not success, trace where )
authoreap <eap@opencascade.com>
Thu, 12 Apr 2007 15:37:34 +0000 (15:37 +0000)
committereap <eap@opencascade.com>
Thu, 12 Apr 2007 15:37:34 +0000 (15:37 +0000)
-              SMESH::ModifiedMesh(aMeshSO, false);
+              SMESH::ModifiedMesh(aMeshSO, false, aMesh->NbNodes()==0);

src/SMESHGUI/SMESHGUI.cxx
src/SMESHGUI/SMESHGUI_Hypotheses.cxx
src/SMESHGUI/SMESHGUI_HypothesesUtils.cxx
src/SMESHGUI/SMESHGUI_Swig.cxx
src/SMESHGUI/SMESHGUI_Swig.hxx

index b002b987a162922d807b0b0b1cd207d8f754502b..67032b6d6200dbbdad99e36553260e000e9b886b 100644 (file)
@@ -868,7 +868,7 @@ using namespace std;
 
             _PTR(SObject) aMeshSO = SMESH::FindSObject(aMesh);
             if (aMeshSO)
-              SMESH::ModifiedMesh(aMeshSO, false);
+              SMESH::ModifiedMesh(aMeshSO, false, aMesh->NbNodes()==0);
           }
           else {
             IObject = new SALOME_InteractiveObject
index b6542903a68acc4a9c405fbdfdc76ffa819ffcaa..858fa53e8d6ac9ac9e3de7e9d359e63f0ded5c25 100644 (file)
@@ -119,7 +119,7 @@ void SMESHGUI_GenericHypothesisCreator::edit( SMESH::SMESH_Hypothesis_ptr h, QWi
       if( !aSubMesh->_is_nil() )
        aMesh = aSubMesh->GetFather();
       _PTR(SObject) meshSO = SMESH::FindSObject( aMesh );
-      SMESH::ModifiedMesh( meshSO, false);
+      SMESH::ModifiedMesh( meshSO, false, aMesh->NbNodes()==0);
     }
   SMESHGUI::GetSMESHGUI()->updateObjBrowser( true, 0 );
 }
index cc4db51a80841b5ae1615b4f985d24e56b553b3f..8f40e2b85a59da7a0d28f61dc1e0ce79b4e48334 100644 (file)
@@ -410,7 +410,7 @@ namespace SMESH{
        if (res < SMESH::HYP_UNKNOWN_FATAL) {
          _PTR(SObject) aSH = SMESH::FindSObject(aHyp);
          if (SM && aSH) {
-           SMESH::ModifiedMesh(SM, false);
+           SMESH::ModifiedMesh(SM, false, aMesh->NbNodes()==0);
          }
        }
        if (res > SMESH::HYP_OK) {
@@ -445,7 +445,7 @@ namespace SMESH{
          if (res < SMESH::HYP_UNKNOWN_FATAL)  {
             _PTR(SObject) meshSO = SMESH::FindSObject(aMesh);
             if (meshSO)
-              SMESH::ModifiedMesh(meshSO, false);
+              SMESH::ModifiedMesh(meshSO, false, aMesh->NbNodes()==0);
          }
          if (res > SMESH::HYP_OK) {
            wc.suspend();
@@ -531,7 +531,7 @@ namespace SMESH{
            if (res < SMESH::HYP_UNKNOWN_FATAL) {
               _PTR(SObject) meshSO = SMESH::FindSObject(aMesh);
               if (meshSO)
-                SMESH::ModifiedMesh(meshSO, false);
+                SMESH::ModifiedMesh(meshSO, false, aMesh->NbNodes()==0);
             }
            if (res > SMESH::HYP_OK) {
              wc.suspend();
index c1912cab2ad4e4c9c0a5c93c4f57cb85c63c1b40..fec084979966469eae52d41301a8133ccc11c300 100644 (file)
@@ -633,20 +633,23 @@ SMESH_Swig::SetName(const char* theEntry,
 //================================================================================
 
 void SMESH_Swig::SetMeshIcon(const char* theMeshEntry, 
-                            const bool theIsComputed)
+                            const bool theIsComputed,
+                             const bool isEmpty)
 {
   class TEvent: public SALOME_Event
   {
     SALOMEDS::Study_var myStudy;
     std::string myMeshEntry;
-    bool myIsComputed;
+    bool myIsComputed, myIsEmpty;
   public:
     TEvent(const SALOMEDS::Study_var& theStudy,
           const std::string& theMeshEntry,
-          const bool theIsComputed):
+          const bool theIsComputed,
+           const bool isEmpty):
       myStudy(theStudy),
       myMeshEntry(theMeshEntry),
-      myIsComputed(theIsComputed)
+      myIsComputed(theIsComputed),
+      myIsEmpty(isEmpty)
     {}
 
     virtual
@@ -656,11 +659,12 @@ void SMESH_Swig::SetMeshIcon(const char* theMeshEntry,
       SALOMEDS::SObject_var aMeshSO = myStudy->FindObjectID(myMeshEntry.c_str());
       if(!aMeshSO->_is_nil())
        if(_PTR(SObject) aMesh = ClientFactory::SObject(aMeshSO))
-         SMESH::ModifiedMesh(aMesh,myIsComputed);
+         SMESH::ModifiedMesh(aMesh,myIsComputed,myIsEmpty);
     }
   };
 
   ProcessVoidEvent(new TEvent(myStudy,
                              theMeshEntry,
-                             theIsComputed));
+                             theIsComputed,
+                              isEmpty));
 }
index 433f3c862d770c674c703186938f2ad2b86f1d56..c67876090a8be0bde48432801a1f1a1f0cd9a87a 100644 (file)
@@ -66,7 +66,7 @@ public:
     * \param Mesh_Entry - entry of a mesh
     * \param isComputed - is mesh computed or not
    */
-  void SetMeshIcon(const char* Mesh_Entry, const bool isComputed);
+  void SetMeshIcon(const char* Mesh_Entry, const bool isComputed, const bool isEmpty);
 
 private:
   SALOMEDS::Study_var        myStudy;