From 31bcd65bd2f238e9fc2dfc1ccb5bc7e20d40d342 Mon Sep 17 00:00:00 2001 From: DUC ANH HOANG Date: Fri, 21 Oct 2022 15:04:51 +0200 Subject: [PATCH] porting to medreader evolution --- src/MEDCalc/cmp/MEDPresentation.cxx | 4 ++-- src/MEDCalc/tui/medpresentation.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/MEDCalc/cmp/MEDPresentation.cxx b/src/MEDCalc/cmp/MEDPresentation.cxx index 20ddfeb39..e3b8f77f0 100644 --- a/src/MEDCalc/cmp/MEDPresentation.cxx +++ b/src/MEDCalc/cmp/MEDPresentation.cxx @@ -435,14 +435,14 @@ MEDPresentation::createSource() } std::ostringstream oss; - oss << _srcObjVar << " = pvs.MEDReader(FileName=r'" << _fileName << "');"; + oss << _srcObjVar << " = pvs.MEDReader(FileNames=r'" << _fileName << "');"; pushAndExecPyLine(oss.str()); oss.str(""); oss << "medcalc.SelectSourceField(" << _srcObjVar << ", '" << _meshName << "', '" << _fieldName << "', '" << typ << "');"; pushAndExecPyLine(oss.str()); oss.str(""); // Generate complete vector fields: fields with 2 components will copied into _vector and // have a third null component added. - oss << _srcObjVar << ".GenerateVectors = 1;"; + oss << _srcObjVar << ".VectorsProperty = 1;"; pushAndExecPyLine(oss.str()); oss.str(""); // Make sure this is set so we stick to time steps: diff --git a/src/MEDCalc/tui/medpresentation.py b/src/MEDCalc/tui/medpresentation.py index 78755654c..3378ed586 100644 --- a/src/MEDCalc/tui/medpresentation.py +++ b/src/MEDCalc/tui/medpresentation.py @@ -441,7 +441,7 @@ def SelectSourceField(obj, meshName, fieldName, discretisation): arr = t.split("/") arr = arr[:-1] + arr[-1].split("@@][@@") if arr[1] == meshName and arr[3] == fieldName and arr[4] == discretisation: - obj.AllArrays = [t] + obj.FieldsStatus = [t] return raise Exception("Field not found") -- 2.39.2