-// Copyright (C) 2014-2019 CEA/DEN, EDF R&D
+// Copyright (C) 2014-2021 CEA/DEN, EDF R&D
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
#include <ModelAPI_Session.h>
#include <ModelAPI_AttributeString.h>
+#include <ModelAPI_AttributeBoolean.h>
#include <ExchangePlugin_Dump.h>
#include <LightApp_Study.h>
LightApp_Study* aStudy = dynamic_cast<LightApp_Study*>( myModule->application()->activeStudy() );
QString aNewTmpDir = aStudy->GetTmpDir("", false).c_str();
- bool isDone = true;
QDir aDir(aTmpDir);
QStringList aFiles = aDir.entryList(QDir::Files);
QStringList::const_iterator anIt = aFiles.begin(), aLast = aFiles.end();
bool SHAPERGUI_DataModel::save(QStringList& theFiles)
{
- // Pyblish to study before saving of the data model
+ // Publish to study before saving of the data model
myModule->publishToStudy();
LightApp_DataModel::save( theFiles );
bool SHAPERGUI_DataModel::close()
{
- myModule->publishToStudy();
myModule->workshop()->closeDocument();
return LightApp_DataModel::close();
}
if (aAttr.get())
aAttr->setValue(".py");
+#ifdef HAVE_SALOME
+ aFeature->boolean(ExchangePlugin_Dump::EXPORT_VARIABLES_ID())->setValue(true);
+#endif
+
ModelAPI_Session::get()->finishOperation();
if (QFile::exists(aFileName.c_str())) {
return false;
QTextStream aOut(&aOutFile);
- aOut << aTrace.toStdString().c_str() << "\n";
+ aOut << aTrace << "\n";
aOut.flush();
aOutFile.close();
}
return false;
}
-