Skip to content

Commit

Permalink
Merge pull request #156 from abiyfantaye/master
Browse files Browse the repository at this point in the history
Made all CFD events use OpenFOAM-10
  • Loading branch information
fmckenna authored May 29, 2024
2 parents b921d34 + c6e2348 commit eb56d4e
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 7 deletions.
2 changes: 1 addition & 1 deletion EVENTS/EmptyDomainCFD/EmptyDomainCFD.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ bool EmptyDomainCFD::initialize()
// openFoamVersion->addItem("7");
// openFoamVersion->addItem("9");
openFoamVersion->addItem("10");
openFoamVersion->setCurrentIndex(1);
openFoamVersion->setCurrentIndex(0);
openFoamVersion->setMinimumWidth(50);
openFoamVersion->setDisabled(true);

Expand Down
18 changes: 14 additions & 4 deletions EVENTS/IsolatedBuildingCFD/IsolatedBuildingCFD.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -184,10 +184,10 @@ bool IsolatedBuildingCFD::initialize()
QLabel *openFoamVersionLabel = new QLabel("Version of OpenFOAM Distribution: ");

openFoamVersion = new QComboBox ();
openFoamVersion->addItem("7");
openFoamVersion->addItem("9");
// openFoamVersion->addItem("7");
// openFoamVersion->addItem("9");
openFoamVersion->addItem("10");
openFoamVersion->setCurrentIndex(2);
openFoamVersion->setCurrentIndex(0);
openFoamVersion->setMinimumWidth(50);


Expand Down Expand Up @@ -696,7 +696,17 @@ bool IsolatedBuildingCFD::inputFromJSON(QJsonObject &jsonObject)
caseDirectoryPathWidget->setText(jsonObject["caseDirectoryPath"].toString());
}

openFoamVersion->setCurrentText(jsonObject["OpenFoamVersion"].toString());

QString foamVersion = jsonObject["OpenFoamVersion"].toString();

//Check if it's version 10 other wise switch to 10
//the backend application running on TACC uses OpenFOAM-10 for now
if(foamVersion != "10")
{
foamVersion = "10";
}

openFoamVersion->setCurrentText(foamVersion);

geometry->inputFromJSON(jsonObject);
snappyHexMesh->inputFromJSON(jsonObject);
Expand Down
4 changes: 2 additions & 2 deletions EVENTS/WindEventSelection.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -190,8 +190,8 @@ WindEventSelection::WindEventSelection(RandomVariablesContainer *theRandomVariab
connect(eventSelection,SIGNAL(currentTextChanged(QString)),this,SLOT(eventSelectionChanged(QString)));

// status and error messaging
//connect(theIsolatedBuildingCFD, SIGNAL(errorMessage(QString)), this,SLOT(sendErrorMessage(QString)));
//connect(theEmptyDomainCFD, SIGNAL(errorMessage(QString)), this,SLOT(sendErrorMessage(QString)));
connect(theIsolatedBuildingCFD, SIGNAL(errorMessage(QString)), this,SLOT(sendErrorMessage(QString)));
connect(theSurroundedBuildingCFD, SIGNAL(errorMessage(QString)), this,SLOT(sendErrorMessage(QString)));
}

WindEventSelection::~WindEventSelection()
Expand Down

0 comments on commit eb56d4e

Please sign in to comment.