Skip to content

Commit

Permalink
Re #5426. Small change to padSpectra() for use with live data.
Browse files Browse the repository at this point in the history
  • Loading branch information
RussellTaylor committed May 31, 2012
1 parent c030935 commit 3851132
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Code/Mantid/Framework/DataHandling/src/LoadInstrument.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ namespace Mantid
// We will parse the XML using the InstrumentDefinitionParser
InstrumentDefinitionParser parser;

// Is the XML is passed in via the InstrumentXML property, use that.
// If the XML is passed in via the InstrumentXML property, use that.
const Property * const InstrumentXML = getProperty("InstrumentXML");
if ( ! InstrumentXML->isDefault() )
{
Expand Down
8 changes: 8 additions & 0 deletions Code/Mantid/Framework/DataObjects/src/EventWorkspace.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -543,6 +543,14 @@ namespace DataObjects
//Save it in the list
data[wi] = newel;
}

// Put on a default set of X vectors, with one bin of 0 & extremely close to zero
MantidVecPtr xVals;
MantidVec & x = xVals.access();
x.resize(2,0.0);
// Move the rhs very,very slightly just incase something doesn't like them being the same
x[1] = std::numeric_limits<double>::min();
this->setAllX(xVals);

//Clearing the MRU list is a good idea too.
this->clearMRU();
Expand Down

0 comments on commit 3851132

Please sign in to comment.