diff --git a/main/astrodatagui/AstrodataGUI.py b/main/astrodatagui/AstrodataGUI.py index f079be2..bf783e6 100644 --- a/main/astrodatagui/AstrodataGUI.py +++ b/main/astrodatagui/AstrodataGUI.py @@ -363,13 +363,12 @@ class AstrodataGUI(QtWidgets.QMainWindow): self.flaredetectorPreview.setPeriodogramState(periodogramEnabled, method, view) def btCountAllFlaresClickedDone(self, allFlaresDictList): - self.calcAllFlaresThread = None self.btCountAllFlares.setEnabled(True) self.AllFlaresWindow = FlareSummaryPlotGUI(allFlaresDictList) self.AllFlaresWindow.show() def btCountAllFlaresClicked(self): - if(self.calcAllFlaresThread is None): + if(self.calcAllFlaresThread is None or self.calcAllFlaresThread.isFinished()): self.btCountAllFlares.setEnabled(False) allStarsDictList = pd.DataFrame(columns=["StarName", "SpType",