From d643725ec82636f82c909d37b1517479ad572ea7 Mon Sep 17 00:00:00 2001
From: brenda-br
Date: Tue, 7 Feb 2023 22:42:03 +0530
Subject: Fix #51 Change cursor when simulation
---
Container.py | 10 ++++++++++
icons/simulating.png | Bin 0 -> 6777 bytes
2 files changed, 10 insertions(+)
create mode 100644 icons/simulating.png
diff --git a/Container.py b/Container.py
index 6b59b37..71787e5 100644
--- a/Container.py
+++ b/Container.py
@@ -143,10 +143,20 @@ class Container():
self.result=self.flowsheet.result_data
elif mode=='EQN':
+ self.graphicsView.setInteractive(False)
+ c_pix = QPixmap('Icons/simulating.png')
+ cursor_scaled_pix = c_pix.scaled(QSize(30, 30), Qt.KeepAspectRatio)
+ s_cursor = QCursor(cursor_scaled_pix, -1, -1)
+ QApplication.instance().setOverrideCursor(s_cursor)
+
self.msg.append("["+str(self.current_time())+"] Simulating in equation mode ... ")
self.flowsheet.simulate_EQN()
self.result=self.flowsheet.result_data
+ self.graphicsView.setInteractive(True)
+ s_cursor = cursor = QCursor( Qt.ArrowCursor )
+ QApplication.instance().setOverrideCursor(s_cursor)
+
if(len(self.result)== 4):
#self.msg_browser()
self.msg.append("["+str(self.current_time())+"] Simulation Successful.")
diff --git a/icons/simulating.png b/icons/simulating.png
new file mode 100644
index 0000000..b8ff48f
Binary files /dev/null and b/icons/simulating.png differ
--
cgit