Skip to content
Snippets Groups Projects
Commit acf27445 authored by Karsten Rink's avatar Karsten Rink
Browse files

The OGS file converter is now called as an external application from the Tools menu

parent 054213ac
No related branches found
No related tags found
No related merge requests found
......@@ -1022,6 +1022,18 @@ void MainWindow::exportBoreholesToGMS(std::string listName,
GMSInterface::writeBoreholesToGMS(stations, fileName);
}
void MainWindow::callFileConverter() const
{
if (system(NULL) != 0) // command processor available
{
std::string call_command("OGSFileConverter");
system(call_command.c_str());
}
else
OGSError::box("Error executing OGS File Converter", "Error");
}
void MainWindow::callGMSH(std::vector<std::string> & selectedGeometries,
unsigned param1, double param2, double param3, double param4,
bool delete_geo_file)
......
......@@ -61,6 +61,8 @@ protected slots:
void open(int i = 0);
/// Function calls for saving files.
void save();
/// Calls the OGSFileConverter as an external tool
void callFileConverter() const;
/// Function calls for generating GMSH files from the GUI
void callGMSH(std::vector<std::string> & selectedGeometries,
unsigned param1,
......
......@@ -652,6 +652,22 @@
</hint>
</hints>
</connection>
<connection>
<sender>actionFile_Converter</sender>
<signal>triggered()</signal>
<receiver>MainWindowClass</receiver>
<slot>callFileConverter()</slot>
<hints>
<hint type="sourcelabel">
<x>-1</x>
<y>-1</y>
</hint>
<hint type="destinationlabel">
<x>400</x>
<y>372</y>
</hint>
</hints>
</connection>
</connections>
<slots>
<slot>open()</slot>
......@@ -666,5 +682,6 @@
<slot>showLicense()</slot>
<slot>showMergeGeometriesDialog()</slot>
<slot>showMeshElementRemovalDialog()</slot>
<slot>callFileConverter()</slot>
</slots>
</ui>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment