diff --git a/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/EnggDiffraction/EnggDiffFittingPresenter.h b/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/EnggDiffraction/EnggDiffFittingPresenter.h index ce8d445135e731e9c46d906991d13b67e624411a..59ce59d1a4b0a1306ecc5a93e9712a3544c80a3f 100644 --- a/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/EnggDiffraction/EnggDiffFittingPresenter.h +++ b/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/EnggDiffraction/EnggDiffFittingPresenter.h @@ -203,6 +203,9 @@ private: // input run number - used for output file name std::vector<std::string> g_multi_run; + // Holds the previous user input so we can short circuit further checks + std::string m_previousInput; + /// true if the last fitting completed successfully bool m_fittingFinishedOK; diff --git a/MantidQt/CustomInterfaces/src/EnggDiffraction/EnggDiffFittingPresenter.cpp b/MantidQt/CustomInterfaces/src/EnggDiffraction/EnggDiffFittingPresenter.cpp index 365999ae826873066c0c298af583ec48fdaa0854..615a1baa1ac8e4a05ce8d2d6501935d5643fbb69 100644 --- a/MantidQt/CustomInterfaces/src/EnggDiffraction/EnggDiffFittingPresenter.cpp +++ b/MantidQt/CustomInterfaces/src/EnggDiffraction/EnggDiffFittingPresenter.cpp @@ -198,6 +198,17 @@ void EnggDiffFittingPresenter::fittingRunNoChanged() { // receive the run number from the text-field auto strFocusedFile = m_view->getFittingRunNo(); + if (m_previousInput == strFocusedFile) { + // Short circuit the checks and skip any warnings + // or errors as the user has not changed anything + // just clicked the box. Additionally this resolves an + // issue where QT will return the cursor and produce a new + // warning when the current warning is closed + return; + } else { + m_previousInput = strFocusedFile; + } + // file name Poco::Path selectedfPath(strFocusedFile); Poco::Path bankDir;