diff --git a/gui/fitCommands/calc/module/localChangeStates.py b/gui/fitCommands/calc/module/localChangeStates.py index 265616544..edc2ce2d4 100644 --- a/gui/fitCommands/calc/module/localChangeStates.py +++ b/gui/fitCommands/calc/module/localChangeStates.py @@ -61,3 +61,12 @@ class CalcChangeLocalModuleStatesCommand(wx.Command): mod.state = state restoreCheckedStates(fit, self.savedStateCheckChanges, ignoreModPoss=self.savedStates) return True + + @property + def recalcNeeded(self): + if self.savedStateCheckChanges is None: + return True + for container in self.savedStateCheckChanges: + if len(container) > 0: + return True + return False diff --git a/gui/fitCommands/gui/localModule/changeStates.py b/gui/fitCommands/gui/localModule/changeStates.py index 482e89bcb..5f966d451 100644 --- a/gui/fitCommands/gui/localModule/changeStates.py +++ b/gui/fitCommands/gui/localModule/changeStates.py @@ -28,7 +28,8 @@ class GuiChangeLocalModuleStatesCommand(wx.Command): success = self.internalHistory.submit(cmd) eos.db.flush() sFit = Fit.getInstance() - sFit.recalc(self.fitID) + if cmd.recalcNeeded: + sFit.recalc(self.fitID) self.savedRemovedDummies = sFit.fill(self.fitID) eos.db.commit() wx.PostEvent(gui.mainFrame.MainFrame.getInstance(), GE.FitChanged(fitIDs=(self.fitID,)))