From 443c7bdbe27452aeb57348eb298fc4e9e0b584ed Mon Sep 17 00:00:00 2001 From: apo Date: Tue, 18 Apr 2006 08:35:31 +0000 Subject: [PATCH] Fix on Bug12140 Not sufficient resoring GUI state --- src/VISU_I/VISU_DumpPython.cc | 21 ++++++++-- src/VISU_I/VISU_Result_i.cc | 76 +++++++++++++---------------------- 2 files changed, 46 insertions(+), 51 deletions(-) diff --git a/src/VISU_I/VISU_DumpPython.cc b/src/VISU_I/VISU_DumpPython.cc index d85247b9..cb2d5b52 100644 --- a/src/VISU_I/VISU_DumpPython.cc +++ b/src/VISU_I/VISU_DumpPython.cc @@ -55,7 +55,8 @@ using namespace std; -namespace VISU{ +namespace VISU +{ static std::string PREFIX(" "); typedef std::map TName2EntryMap; @@ -530,14 +531,28 @@ namespace VISU{ if(anId == Result_i::eImportFile || anId == Result_i::eCopyAndImportFile){ switch(anId){ case Result_i::eImportFile: - theStr<IsGroupsDone()<<")"<< + endl; + + theStr<IsFieldsDone()<<","<< + aServant->IsMinMaxDone()<<")"<< + endl; + + theStr<myGroupsEntry = - CreateAttributes(theStudy, - aMesh->myEntry, - "", - "", - "", - true); - } + if(theIsBuildGroups){ + aMesh->myGroupsEntry = + CreateAttributes(theStudy, + aMesh->myEntry, + "", + "", + "", + true); + } - if(theIsBuildFields){ - aMesh->myFieldsEntry = - CreateAttributes(theStudy, - aMesh->myEntry, - "", - "", - "", - true); - } + if(theIsBuildFields){ + aMesh->myFieldsEntry = + CreateAttributes(theStudy, + aMesh->myEntry, + "", + "", + "", + true); } - + //Import entities TMeshOnEntityMap::const_iterator aMeshOnEntityMapIter = aMeshOnEntityMap.begin(); for(; aMeshOnEntityMapIter != aMeshOnEntityMap.end(); aMeshOnEntityMapIter++){ @@ -558,20 +556,11 @@ namespace VISU aComment.sprintf("myComment=GROUPS;myMeshName=%s", aMeshName.c_str()); - if(theIsAtOnce) - aMesh->myGroupsEntry = - CreateAttributes(theStudy, - aMesh->myEntry, - "", - "Groups", - aComment.latin1(), - true); - else - UpdateAttributes(theStudy, - aMesh->myGroupsEntry, - "", - "Groups", - aComment.latin1()); + UpdateAttributes(theStudy, + aMesh->myGroupsEntry, + "", + "Groups", + aComment.latin1()); TGroupMap::const_iterator aGroupMapIter = aGroupMap.begin(); for(; aGroupMapIter != aGroupMap.end(); aGroupMapIter++){ @@ -649,20 +638,11 @@ namespace VISU aComment.sprintf("myComment=FIELDS;myMeshName=%s", aMeshName.c_str()); - if(theIsAtOnce) - aMesh->myFieldsEntry = - CreateAttributes(theStudy, - aMesh->myEntry, - "", - "Fields", - aComment.latin1(), - true); - else - UpdateAttributes(theStudy, - aMesh->myFieldsEntry, - "", - "Fields", - aComment.latin1()); + UpdateAttributes(theStudy, + aMesh->myFieldsEntry, + "", + "Fields", + aComment.latin1()); anIsFieldsEntryUpdated = true; } -- 2.39.2