Skip to content

Commit

Permalink
refs #18950 Empty cache for deadTimes, firstGoodData and startTime
Browse files Browse the repository at this point in the history
  • Loading branch information
AnthonyLim23 committed Feb 23, 2017
1 parent a2b5275 commit 67ea45d
Show file tree
Hide file tree
Showing 3 changed files with 471 additions and 466 deletions.
Expand Up @@ -95,6 +95,8 @@ class MANTIDQT_CUSTOMINTERFACES_DLL MuonAnalysisDataLoader {
/// Load dead times from file
Mantid::API::Workspace_sptr
loadDeadTimesFromFile(const std::string &filename) const;
//empty the cache
void emptyCache();

protected:
/// Set properties of algorithm from options
Expand Down
4 changes: 3 additions & 1 deletion MantidQt/CustomInterfaces/src/Muon/MuonAnalysis.cpp
Expand Up @@ -2694,7 +2694,7 @@ void MuonAnalysis::doSetToolbarsHidden(bool hidden) {
*/
void MuonAnalysis::onDeadTimeTypeChanged(int choice) {
m_deadTimesChanged = true;

m_dataLoader.emptyCache();
if (choice == 0 || choice == 1) // if choice == none || choice == from file
{
m_uiForm.mwRunDeadTimeFile->setVisible(false);
Expand Down Expand Up @@ -2757,6 +2757,7 @@ void MuonAnalysis::deadTimeFileSelected() {
* from the form
*/
void MuonAnalysis::setTimeZeroState(int checkBoxState) {
m_dataLoader.emptyCache();
if (checkBoxState == -1)
checkBoxState = m_uiForm.timeZeroAuto->checkState();

Expand All @@ -2778,6 +2779,7 @@ void MuonAnalysis::setTimeZeroState(int checkBoxState) {
* from the form
*/
void MuonAnalysis::setFirstGoodDataState(int checkBoxState) {
m_dataLoader.emptyCache();
if (checkBoxState == -1)
checkBoxState = m_uiForm.firstGoodDataAuto->checkState();

Expand Down

0 comments on commit 67ea45d

Please sign in to comment.