diff --git a/qt/scientific_interfaces/Indirect/IndirectFitAnalysisTab.cpp b/qt/scientific_interfaces/Indirect/IndirectFitAnalysisTab.cpp index a2424312ff4c1447fc55316cc2ab1694c434cc12..966f1c8e435f4e4e9287091120ce28236ca13444 100644 --- a/qt/scientific_interfaces/Indirect/IndirectFitAnalysisTab.cpp +++ b/qt/scientific_interfaces/Indirect/IndirectFitAnalysisTab.cpp @@ -114,10 +114,6 @@ void IndirectFitAnalysisTab::setup() { SLOT(updateResultOptions())); connect(m_fitPropertyBrowser, SIGNAL(functionChanged()), this, SLOT(updateParameterValues())); - connect(m_plotPresenter.get(), SIGNAL(selectedFitDataChanged(std::size_t)), - this, SLOT(updateParameterValues())); - connect(m_plotPresenter.get(), SIGNAL(plotSpectrumChanged(std::size_t)), this, - SLOT(updateParameterValues())); connect(m_plotPresenter.get(), SIGNAL(fitSingleSpectrum(std::size_t, std::size_t)), this, @@ -183,14 +179,20 @@ void IndirectFitAnalysisTab::connectFitBrowserAndPlotPresenter() { SLOT(setBrowserWorkspaceIndex(std::size_t))); connect(m_plotPresenter.get(), SIGNAL(selectedFitDataChanged(std::size_t)), this, SLOT(setBrowserWorkspace(std::size_t))); - connect(m_plotPresenter.get(), SIGNAL(plotSpectrumChanged(std::size_t)), this, - SLOT(setBrowserWorkspaceIndex(std::size_t))); connect(m_fitPropertyBrowser, SIGNAL(functionChanged()), this, SLOT(updateAttributeValues())); connect(m_plotPresenter.get(), SIGNAL(selectedFitDataChanged(std::size_t)), this, SLOT(updateAttributeValues())); - connect(m_plotPresenter.get(), SIGNAL(plotSpectrumChanged(std::size_t)), this, - SLOT(updateAttributeValues())); + connect(m_plotPresenter.get(), SIGNAL(selectedFitDataChanged(std::size_t)), + this, SLOT(updateParameterValues())); + connect(m_plotPresenter.get(), SIGNAL(plotSpectrumChanged(std::size_t)), this, + SLOT(setBrowserWorkspaceIndex(std::size_t))); + // Update attributes before parameters as the parameters may depend on the + // attribute values + connect(m_plotPresenter.get(), SIGNAL(plotSpectrumChanged(std::size_t)), this, + SLOT(updateAttributeValues())); + connect(m_plotPresenter.get(), SIGNAL(plotSpectrumChanged(std::size_t)), this, + SLOT(updateParameterValues())); connect(m_fitPropertyBrowser, SIGNAL(startXChanged(double)), m_plotPresenter.get(), SLOT(setStartX(double))); diff --git a/qt/scientific_interfaces/Indirect/IndirectFitPlotView.cpp b/qt/scientific_interfaces/Indirect/IndirectFitPlotView.cpp index e19a82fd2bbf1a6735449d70fd944d8e91351ecf..b6efef16288202d384650e553cb48a424b424550 100644 --- a/qt/scientific_interfaces/Indirect/IndirectFitPlotView.cpp +++ b/qt/scientific_interfaces/Indirect/IndirectFitPlotView.cpp @@ -107,7 +107,8 @@ void IndirectFitPlotView::setMaximumSpectrum(int maximum) { } void IndirectFitPlotView::setPlotSpectrum(int spectrum) { - m_plotForm->spPlotSpectrum->setValue(spectrum); + //MantidQt::API::SignalBlocker<QObject> blocker(m_plotForm->spPlotSpectrum); + //m_plotForm->spPlotSpectrum->setValue(spectrum); } void IndirectFitPlotView::setBackgroundLevel(double value) {