Skip to content

Commit

Permalink
adding notification window to let the user know the file has been upd…
Browse files Browse the repository at this point in the history
…ated
  • Loading branch information
sotorrio1 committed Sep 12, 2024
1 parent 799a82a commit 7be5f4f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
11 changes: 11 additions & 0 deletions foqus_lib/gui/flowsheet/nodePanel.py
Original file line number Diff line number Diff line change
Expand Up @@ -942,3 +942,14 @@ def updateConfigFile(self):
# Write the modified content back to the file
with open(self.configFile_edit.text(), "w", encoding="utf-8") as file:
file.write(content)

msgBox = QMessageBox()
msgBox.setWindowTitle("Aspen Consumer Configuration File")
dirname = os.path.dirname(self.configFile_edit.text())
msgBox.setText(
"The Aspen Consumer configuration file has been successfully updated.\n"
"\nPlease make sure your changes are correct before loading it into Aspen.\n"
"\nA backup of the old version has been saved in the directory below:\n"
"\n" + dirname
)
msgBox.exec_()
4 changes: 2 additions & 2 deletions foqus_lib/gui/flowsheet/nodePanel_UI.ui
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@
<item>
<widget class="QToolBox" name="toolBox">
<property name="currentIndex">
<number>3</number>
<number>0</number>
</property>
<widget class="QWidget" name="page">
<property name="geometry">
Expand Down Expand Up @@ -925,7 +925,7 @@
<x>0</x>
<y>0</y>
<width>3370</width>
<height>367</height>
<height>879</height>
</rect>
</property>
<attribute name="label">
Expand Down

0 comments on commit 7be5f4f

Please sign in to comment.