diff --git a/docs/source/release/v5.1.0/indirect_geometry.rst b/docs/source/release/v5.1.0/indirect_geometry.rst index 84690c899f4471820ccbe59a877cacb4e3eb6361..0c13806c356007a9ec1929e03b5623f2420963b8 100644 --- a/docs/source/release/v5.1.0/indirect_geometry.rst +++ b/docs/source/release/v5.1.0/indirect_geometry.rst @@ -5,8 +5,9 @@ Indirect Geometry Changes .. contents:: Table of Contents :local: -.. warning:: **Developers:** Sort changes under appropriate heading - putting new features at the top of the section, followed by - improvements, followed by bug fixes. +Improvements +############ + +- An issue with IndirectDataReduction causing it to slow down processing when open has been resolved. :ref:`Release 5.1.0 <v5.1.0>` \ No newline at end of file diff --git a/qt/widgets/plotting/src/Mpl/ContourPreviewPlot.cpp b/qt/widgets/plotting/src/Mpl/ContourPreviewPlot.cpp index ab7ddad5de5dc56f94ffa33e6d52aa543f8b568f..857d592ca689277d07c726e37d0145ea43c91ba4 100644 --- a/qt/widgets/plotting/src/Mpl/ContourPreviewPlot.cpp +++ b/qt/widgets/plotting/src/Mpl/ContourPreviewPlot.cpp @@ -68,11 +68,15 @@ void ContourPreviewPlot::onWorkspaceRemoved( if (auto workspace = boost::dynamic_pointer_cast<MatrixWorkspace>(nf->object())) { // If the artist has already been removed, ignore. + bool workspaceRemoved = false; try { - m_canvas->gca<MantidAxes>().removeWorkspaceArtists(workspace); + workspaceRemoved = + m_canvas->gca<MantidAxes>().removeWorkspaceArtists(workspace); } catch (Mantid::PythonInterface::PythonException &) { } - m_canvas->draw(); + if (workspaceRemoved) { + m_canvas->draw(); + } } } @@ -86,8 +90,9 @@ void ContourPreviewPlot::onWorkspaceReplaced( boost::dynamic_pointer_cast<MatrixWorkspace>(nf->oldObject())) { if (auto newWorkspace = boost::dynamic_pointer_cast<MatrixWorkspace>(nf->newObject())) { - m_canvas->gca<MantidAxes>().replaceWorkspaceArtists(newWorkspace); - m_canvas->draw(); + if (m_canvas->gca<MantidAxes>().replaceWorkspaceArtists(newWorkspace)) { + m_canvas->draw(); + } } } }