summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Graphics.py6
-rw-r--r--Streams.py1
-rw-r--r--Undo.datbin45270 -> 49977 bytes
-rw-r--r--UnitOperations.py1
-rw-r--r--mainApp.py1
5 files changed, 6 insertions, 3 deletions
diff --git a/Graphics.py b/Graphics.py
index f6b17b5..a653d7d 100644
--- a/Graphics.py
+++ b/Graphics.py
@@ -420,19 +420,19 @@ class NodeItem(QtWidgets.QGraphicsItem):
self.nin = self.obj.no_of_inputs
self.nop = self.obj.no_of_outputs
- if self.obj.type == 'Mixer':
+ if self.obj.type == 'Mixer' and not self.obj.saved:
text, ok = QInputDialog.getText(self.container.graphicsView, 'Mixer', 'Enter number of input:')
if ok and text:
self.nin = int(text)
self.obj.no_of_inputs = self.nin
self.obj.variables['NI']['value'] = self.nin
- elif self.obj.type == 'Splitter':
+ elif self.obj.type == 'Splitter' and not self.obj.saved:
text, ok = QInputDialog.getText(self.container.graphicsView, 'Splitter', 'Enter number of output:')
if ok and text:
self.nop = int(text)
self.obj.no_of_outputs = self.nop
self.obj.variables['No']['value'] = self.nop
- elif self.obj.type == 'DistillationColumn':
+ elif self.obj.type == 'DistillationColumn'and not self.obj.saved:
text, ok = QInputDialog.getText(self.container.graphicsView, 'DistillationColumn', 'Enter number of input:')
if ok and text:
self.nin = int(text)
diff --git a/Streams.py b/Streams.py
index ac89830..ed8021d 100644
--- a/Streams.py
+++ b/Streams.py
@@ -28,6 +28,7 @@ class MaterialStream():
self.start_dict = {}
self.eqn_dict = {}
self.modes_list = ["PT","PH","PVF","TVF","PS"]
+ self.saved = False
self.variables = {
'P' : {'name':'Pressure', 'value':101325, 'unit':'Pa'},
diff --git a/Undo.dat b/Undo.dat
index 0997787..8dfd251 100644
--- a/Undo.dat
+++ b/Undo.dat
Binary files differ
diff --git a/UnitOperations.py b/UnitOperations.py
index c868730..1a96e59 100644
--- a/UnitOperations.py
+++ b/UnitOperations.py
@@ -30,6 +30,7 @@ class UnitOperation():
self.multidict = []
self.thermo_pack_req = False
self.thermo_package = 'RaoultsLaw'
+ self.saved = False
def param_getter(self,mode=None):
params = {}
diff --git a/mainApp.py b/mainApp.py
index ea64132..29db874 100644
--- a/mainApp.py
+++ b/mainApp.py
@@ -299,6 +299,7 @@ class MainApp(QMainWindow,ui):
data = []
for i in self.container.unit_operations:
data.append(i)
+ i.saved = True
print(i.pos)
data.append(compound_selected)
print(data)