Skip to content

Commit

Permalink
Re #6931 Forgot about TimeMin and TimeMax, they should also be static
Browse files Browse the repository at this point in the history
  • Loading branch information
raquelalvarezbanos committed Apr 23, 2015
1 parent 8d324bd commit 7805a1d
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
Expand Up @@ -150,6 +150,10 @@ class DLLExport PlotAsymmetryByLogValue : public API::Algorithm {
static std::string g_logFunc;
// Type of computation: integral or differential
static std::string g_stype;
// Minimum time for the analysis
static double g_minTime;
// Maximum time for the analysis
static double g_maxTime;
};

} // namespace Algorithm
Expand Down
11 changes: 10 additions & 1 deletion Code/Mantid/Framework/Algorithms/src/PlotAsymmetryByLogValue.cpp
Expand Up @@ -102,6 +102,8 @@ std::string PlotAsymmetryByLogValue::g_dtcFile;
std::string PlotAsymmetryByLogValue::g_filenameBase;
std::string PlotAsymmetryByLogValue::g_filenameExt;
int PlotAsymmetryByLogValue::g_filenameZeros = 0;
double PlotAsymmetryByLogValue::g_minTime = EMPTY_DBL();
double PlotAsymmetryByLogValue::g_maxTime = EMPTY_DBL();

/** Initialisation method. Declares properties to be used in algorithm.
*
Expand Down Expand Up @@ -242,6 +244,9 @@ void PlotAsymmetryByLogValue::checkProperties (size_t &is, size_t &ie) {
// Get green and red periods
int red = getProperty("Red");
int green = getProperty("Green");
// Get time min and time max
double minTime = getProperty("TimeMin");
double maxTime = getProperty("TimeMax");
// Get type of dead-time corrections
std::string dtcType = getPropertyValue("DeadTimeCorrType");
std::string dtcFile = getPropertyValue("DeadTimeCorrFile");
Expand Down Expand Up @@ -275,7 +280,9 @@ void PlotAsymmetryByLogValue::checkProperties (size_t &is, size_t &ie) {
g_dtcFile != dtcFile ||
g_filenameBase != filenameBase ||
g_filenameExt != filenameExt ||
g_filenameZeros != filenameZeros) {
g_filenameZeros != filenameZeros ||
g_minTime != minTime ||
g_maxTime != maxTime) {

// If so, clear previous results
clearResultsFromTo(isOld,ieOld);
Expand Down Expand Up @@ -320,6 +327,8 @@ void PlotAsymmetryByLogValue::checkProperties (size_t &is, size_t &ie) {
g_filenameBase = filenameBase;
g_filenameExt = filenameExt;
g_filenameZeros = filenameZeros;
g_minTime = minTime;
g_maxTime = maxTime;

}

Expand Down

0 comments on commit 7805a1d

Please sign in to comment.