Skip to content

Commit

Permalink
Refs #4500 make rebinner workspace name public
Browse files Browse the repository at this point in the history
  • Loading branch information
Janik Zikovsky committed Jan 13, 2012
1 parent 73a5cd5 commit a3af70e
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Code/Mantid/MantidQt/SliceViewer/src/SliceViewer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1383,7 +1383,7 @@ void SliceViewer::openFromXML(const QString & xml)
if (wsName.empty()) throw std::runtime_error("SliceViewer::openFromXML(): Empty MDWorkspaceName found!");

// Look for the rebinned workspace with a custom name:
std::string histoName = "__" + wsName + "_mdhisto";
std::string histoName = wsName + "_mdhisto";
// Use the rebinned workspace if available.
if (AnalysisDataService::Instance().doesExist(histoName))
this->setWorkspace(QString::fromStdString(histoName));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -150,13 +150,13 @@ def test_openFromXML_4D(self):
def test_openFromXML_3D_binned(self):
sv = self.sv
self.setUpXML()
BinMD(InputWorkspace="TOPAZ_3680", OutputWorkspace="__TOPAZ_3680_mdhisto",
BinMD(InputWorkspace="TOPAZ_3680", OutputWorkspace="TOPAZ_3680_mdhisto",
AxisAligned=1, AlignedDimX="Q_lab_x,0,10,20", AlignedDimY="Q_lab_y,0,10,20", AlignedDimZ="Q_lab_z,0,10,20")
# Read the XML and set the view
sv.openFromXML(self.xml_3d)
# Check the settings
# Automatically grabbed the histo version
self.assertEqual(sv.getWorkspaceName(), "__TOPAZ_3680_mdhisto")
self.assertEqual(sv.getWorkspaceName(), "TOPAZ_3680_mdhisto")
self.assertEqual(sv.getDimX(), 1)
self.assertEqual(sv.getDimY(), 2)
self.assertAlmostEqual( sv.getSlicePoint(0), 4.84211, 3)
Expand Down
2 changes: 1 addition & 1 deletion Code/Mantid/Vates/VatesAPI/src/MDEWRebinningPresenter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ namespace Mantid
{
std::string wsName = m_serializer.getWorkspaceName();
// Create a private output workspace name
std::string outWsName = "__" + wsName + "_mdhisto";
std::string outWsName = wsName + "_mdhisto";

using namespace Mantid::API;
if(RecalculateAll == m_request->action())
Expand Down

0 comments on commit a3af70e

Please sign in to comment.