]> SALOME platform Git repositories - modules/smesh.git/commitdiff
Salome HOME
enable to publish in TUI
authorazakir <abdoulbari.zakir@csgroup.eu>
Tue, 19 Jan 2021 09:30:07 +0000 (10:30 +0100)
committerazakir <abdoulbari.zakir@csgroup.eu>
Tue, 19 Jan 2021 09:30:07 +0000 (10:30 +0100)
src/SMESH/MG_ADAPT.cxx
src/SMESHGUI/SMESHGUI_MG_ADAPTDRIVER.cxx
src/SMESH_I/MG_ADAPT_i.cxx

index c3cba43acfec0b376d8337b0409091989eb73d92..09a06ef867fb3146e6c08388306cd2a5d84061f2 100644 (file)
@@ -1253,7 +1253,7 @@ void MgAdapt::restorefams(MEDCoupling::MEDFileMesh* fileMesh) const
 
     for (; fIt!=famVec.end(); ++fIt)
     {  
-               try  // safety : FAMILY could be lost P2-->P1
+               try  //
         {
                        std::string givenFamNameFromMeshGemConverter = fileMesh->getFamilyNameGivenId( std::abs(fIt->_famId) );
             fileMesh->changeFamilyId(std::abs(fIt->_famId), fIt->_famId);
index 0025f57510662454394c90cfebfc262c2536c11f..85a719b40f7e2f491adf2df048abc5884063027c 100644 (file)
@@ -360,9 +360,6 @@ bool SMESHGUI_MG_ADAPTDRIVER::clickOnApply()
     SMESHGUI_MgAdaptDlg::clickOnApply();
 
     bool ok = execute();
-    //~SMESHGUI_MG_AdaptComputeDlg_QThread atest(getModel());
-    //~atest.start();
-    //~atest.quit();
     if (getModel()->getPublish()) this->createMeshInObjectBrowser();
 
     return ok;
index 04ff3daaa58bd41cd8bc4c7b0df07d6e60ffaafb..51160b1dfe6b9c5cfba64b4f0c616f8b0af950ae 100644 (file)
@@ -405,6 +405,12 @@ CORBA::Long MG_ADAPT_i::compute()
         std::cerr<<e.what();
         ret = -1;
     }
+    if(ret!=-1 && myMgAdapt->getPublish())
+    {
+               SMESH_Gen_i* smeshGen_i = SMESH_Gen_i::GetSMESHGen();
+               SMESH::DriverMED_ReadStatus theStatus;
+               smeshGen_i->CreateMeshesFromMED(myMgAdapt->getMedFileOut().c_str(), theStatus);
+       }
        //~errStr =  err.c_str();
        return ret;
 }