##// END OF EJS Templates
GUI - External plotter: Read items while queue is not empty
Miguel Valdez -
r710:22cee43073ff
parent child
Show More
@@ -4751,15 +4751,15 class BasicWindow(QMainWindow, Ui_BasicWindow):
4751 self.threadStarted = False
4751 self.threadStarted = False
4752 self.controllerThread.stop()
4752 self.controllerThread.stop()
4753
4753
4754 while self.controllerThread.isRunning():
4754 while not self.plotManager.isEmpty():
4755 self.plotManager.run()
4755 self.plotManager.run()
4756 sleep(0.5)
4757
4756
4758 if self.plotManager is not None:
4757 self.plotManager.close()
4759 self.plotManager.stop()
4758 self.plotManager = None
4760 self.plotManager.close()
4761 self.plotManager = None
4762
4759
4760 while self.controllerThread.isRunning():
4761 sleep(0.5)
4762
4763 self._disable_stop_button()
4763 self._disable_stop_button()
4764 self._enable_play_button()
4764 self._enable_play_button()
4765
4765
@@ -113,10 +113,12 class PlotManager():
113 plotter = self.plotInstanceDict[plot_id]
113 plotter = self.plotInstanceDict[plot_id]
114 plotter.run(dataPlot, plot_id, **kwargs)
114 plotter.run(dataPlot, plot_id, **kwargs)
115
115
116
117
118 self.__lock.release()
116 self.__lock.release()
119
117
118 def isEmpty(self):
119
120 return self.__queue.empty()
121
120 def stop(self):
122 def stop(self):
121
123
122 self.__lock.acquire()
124 self.__lock.acquire()
General Comments 0
You need to be logged in to leave comments. Login now