From 678a36a5d17ef1d2b2b3fd95a76de80d9c85d12d Mon Sep 17 00:00:00 2001 From: Edward Brown <edward.brown@stfc.ac.uk> Date: Tue, 5 Sep 2017 10:43:14 +0100 Subject: [PATCH] Re #20302: Renamed DataProcessorProcessCommand to ProcessCommand. --- qt/python/CMakeLists.txt | 2 +- qt/python/mantidqt.sip | 10 +++++----- qt/widgets/common/CMakeLists.txt | 2 +- .../Common/DataProcessorUI/PauseCommand.h | 2 +- ...ataProcessorProcessCommand.h => ProcessCommand.h} | 12 ++++++------ .../DataProcessorTwoLevelTreeManager.cpp | 4 ++-- .../src/DataProcessorUI/OneLevelTreeManager.cpp | 4 ++-- .../common/test/DataProcessorUI/CommandsTest.h | 4 ++-- .../DataProcessorTwoLevelTreeManagerTest.h | 4 ++-- .../test/DataProcessorUI/OneLevelTreeManagerTest.h | 4 ++-- .../ui/dataprocessorinterface/data_processor_gui.py | 2 +- scripts/Interface/ui/poldi/poldi_gui.py | 2 +- .../ui/sans_isis/sans_data_processor_gui.py | 2 +- 13 files changed, 27 insertions(+), 27 deletions(-) rename qt/widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/{DataProcessorProcessCommand.h => ProcessCommand.h} (85%) diff --git a/qt/python/CMakeLists.txt b/qt/python/CMakeLists.txt index c4b94efac9b..8a6674339f0 100644 --- a/qt/python/CMakeLists.txt +++ b/qt/python/CMakeLists.txt @@ -53,7 +53,7 @@ set ( SIP_HDRS ../widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/PasteSelectedCommand.h ../widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/PlotGroupCommand.h ../widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/PlotRowCommand.h - ../widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/DataProcessorProcessCommand.h + ../widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/ProcessCommand.h ../widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/DataProcessorSaveTableCommand.h ../widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/DataProcessorSaveTableAsCommand.h ../widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/DataProcessorSeparatorCommand.h diff --git a/qt/python/mantidqt.sip b/qt/python/mantidqt.sip index 6f46471b818..bfa904b67e1 100644 --- a/qt/python/mantidqt.sip +++ b/qt/python/mantidqt.sip @@ -1904,13 +1904,13 @@ PlotRowCommand(); PlotRowCommand(const MantidQt::MantidWidgets::DataProcessor::PlotRowCommand &); }; -class DataProcessorProcessCommand +class ProcessCommand { %TypeHeaderCode -#include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorProcessCommand.h" +#include "MantidQtWidgets/Common/DataProcessorUI/ProcessCommand.h" %End public: -DataProcessorProcessCommand(const MantidQt::MantidWidgets::DataProcessor::QDataProcessorWidget &); +ProcessCommand(const MantidQt::MantidWidgets::DataProcessor::QDataProcessorWidget &); void execute(); QString name(); QString icon(); @@ -1919,8 +1919,8 @@ QString whatsthis(); QString shortcut(); private: -DataProcessorProcessCommand(); -DataProcessorProcessCommand(const MantidQt::MantidWidgets::DataProcessor::DataProcessorProcessCommand &); +ProcessCommand(); +ProcessCommand(const MantidQt::MantidWidgets::DataProcessor::ProcessCommand &); }; class DataProcessorSaveTableCommand diff --git a/qt/widgets/common/CMakeLists.txt b/qt/widgets/common/CMakeLists.txt index 21a03933b08..309e35cb667 100644 --- a/qt/widgets/common/CMakeLists.txt +++ b/qt/widgets/common/CMakeLists.txt @@ -331,7 +331,7 @@ set ( INC_FILES inc/MantidQtWidgets/Common/DataProcessorUI/DataProcessorPreprocessingAlgorithm.h inc/MantidQtWidgets/Common/DataProcessorUI/DataProcessorPreprocessMap.h inc/MantidQtWidgets/Common/DataProcessorUI/DataProcessorPresenter.h - inc/MantidQtWidgets/Common/DataProcessorUI/DataProcessorProcessCommand.h + inc/MantidQtWidgets/Common/DataProcessorUI/ProcessCommand.h inc/MantidQtWidgets/Common/DataProcessorUI/DataProcessorProcessingAlgorithm.h inc/MantidQtWidgets/Common/DataProcessorUI/DataProcessorProcessingAlgorithmBase.h inc/MantidQtWidgets/Common/DataProcessorUI/DataProcessorSaveTableAsCommand.h diff --git a/qt/widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/PauseCommand.h b/qt/widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/PauseCommand.h index 870319fed0c..09f36210dcc 100644 --- a/qt/widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/PauseCommand.h +++ b/qt/widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/PauseCommand.h @@ -8,7 +8,7 @@ namespace MantidWidgets { namespace DataProcessor { /** @class PauseCommand -DataProcessorProcessCommand defines the action "Pause" +ProcessCommand defines the action "Pause" Copyright © 2011-16 ISIS Rutherford Appleton Laboratory, NScD Oak Ridge National Laboratory & European Spallation Source diff --git a/qt/widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/DataProcessorProcessCommand.h b/qt/widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/ProcessCommand.h similarity index 85% rename from qt/widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/DataProcessorProcessCommand.h rename to qt/widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/ProcessCommand.h index 3ca9a2a6124..be6e30b8fb3 100644 --- a/qt/widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/DataProcessorProcessCommand.h +++ b/qt/widgets/common/inc/MantidQtWidgets/Common/DataProcessorUI/ProcessCommand.h @@ -7,9 +7,9 @@ namespace MantidQt { namespace MantidWidgets { namespace DataProcessor { -/** @class DataProcessorProcessCommand +/** @class ProcessCommand -DataProcessorProcessCommand defines the action "Process" +ProcessCommand defines the action "Process" Copyright © 2011-16 ISIS Rutherford Appleton Laboratory, NScD Oak Ridge National Laboratory & European Spallation Source @@ -32,13 +32,13 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. File change history is stored at: <https://github.com/mantidproject/mantid>. Code Documentation is available at: <http://doxygen.mantidproject.org> */ -class DataProcessorProcessCommand : public CommandBase { +class ProcessCommand : public CommandBase { public: - DataProcessorProcessCommand(DataProcessorPresenter *tablePresenter) + ProcessCommand(DataProcessorPresenter *tablePresenter) : CommandBase(tablePresenter){}; - DataProcessorProcessCommand(const QDataProcessorWidget &widget) + ProcessCommand(const QDataProcessorWidget &widget) : CommandBase(widget){}; - virtual ~DataProcessorProcessCommand(){}; + virtual ~ProcessCommand(){}; void execute() override { m_presenter->notify(DataProcessorPresenter::ProcessFlag); diff --git a/qt/widgets/common/src/DataProcessorUI/DataProcessorTwoLevelTreeManager.cpp b/qt/widgets/common/src/DataProcessorUI/DataProcessorTwoLevelTreeManager.cpp index b698ab13b4a..7b48a6ff794 100644 --- a/qt/widgets/common/src/DataProcessorUI/DataProcessorTwoLevelTreeManager.cpp +++ b/qt/widgets/common/src/DataProcessorUI/DataProcessorTwoLevelTreeManager.cpp @@ -22,7 +22,7 @@ #include "MantidQtWidgets/Common/DataProcessorUI/PauseCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/PlotGroupCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/PlotRowCommand.h" -#include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorProcessCommand.h" +#include "MantidQtWidgets/Common/DataProcessorUI/ProcessCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSaveTableAsCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSaveTableCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSeparatorCommand.h" @@ -91,7 +91,7 @@ DataProcessorTwoLevelTreeManager::publishCommands() { addCommand(commands, make_unique<DataProcessorSeparatorCommand>(m_presenter)); addCommand(commands, make_unique<OptionsCommand>(m_presenter)); addCommand(commands, make_unique<DataProcessorSeparatorCommand>(m_presenter)); - addCommand(commands, make_unique<DataProcessorProcessCommand>(m_presenter)); + addCommand(commands, make_unique<ProcessCommand>(m_presenter)); addCommand(commands, make_unique<PauseCommand>(m_presenter)); addCommand(commands, make_unique<DataProcessorSeparatorCommand>(m_presenter)); addCommand(commands, make_unique<ExpandCommand>(m_presenter)); diff --git a/qt/widgets/common/src/DataProcessorUI/OneLevelTreeManager.cpp b/qt/widgets/common/src/DataProcessorUI/OneLevelTreeManager.cpp index 9cf2613ba53..e5c8580b4e7 100644 --- a/qt/widgets/common/src/DataProcessorUI/OneLevelTreeManager.cpp +++ b/qt/widgets/common/src/DataProcessorUI/OneLevelTreeManager.cpp @@ -15,7 +15,7 @@ #include "MantidQtWidgets/Common/DataProcessorUI/PasteSelectedCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/PauseCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/PlotRowCommand.h" -#include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorProcessCommand.h" +#include "MantidQtWidgets/Common/DataProcessorUI/ProcessCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSaveTableAsCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSaveTableCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSeparatorCommand.h" @@ -82,7 +82,7 @@ OneLevelTreeManager::publishCommands() { addCommand(commands, make_unique<DataProcessorSeparatorCommand>(m_presenter)); addCommand(commands, make_unique<OptionsCommand>(m_presenter)); addCommand(commands, make_unique<DataProcessorSeparatorCommand>(m_presenter)); - addCommand(commands, make_unique<DataProcessorProcessCommand>(m_presenter)); + addCommand(commands, make_unique<ProcessCommand>(m_presenter)); addCommand(commands, make_unique<PauseCommand>(m_presenter)); addCommand(commands, make_unique<DataProcessorSeparatorCommand>(m_presenter)); addCommand(commands, make_unique<PlotRowCommand>(m_presenter)); diff --git a/qt/widgets/common/test/DataProcessorUI/CommandsTest.h b/qt/widgets/common/test/DataProcessorUI/CommandsTest.h index fc865c8c6a7..a71efa34ced 100644 --- a/qt/widgets/common/test/DataProcessorUI/CommandsTest.h +++ b/qt/widgets/common/test/DataProcessorUI/CommandsTest.h @@ -28,7 +28,7 @@ #include "MantidQtWidgets/Common/DataProcessorUI/PlotRowCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorPresenter.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorPresenter.h" -#include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorProcessCommand.h" +#include "MantidQtWidgets/Common/DataProcessorUI/ProcessCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSaveTableAsCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSaveTableCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSeparatorCommand.h" @@ -146,7 +146,7 @@ public: void test_process_command() { NiceMock<MockDataProcessorPresenter> mockPresenter; - DataProcessorProcessCommand command(&mockPresenter); + ProcessCommand command(&mockPresenter); // The presenter should be notified with the ProcessFlag EXPECT_CALL(mockPresenter, notify(DataProcessorPresenter::ProcessFlag)) diff --git a/qt/widgets/common/test/DataProcessorUI/DataProcessorTwoLevelTreeManagerTest.h b/qt/widgets/common/test/DataProcessorUI/DataProcessorTwoLevelTreeManagerTest.h index b93b40ec072..f49f3e949b9 100644 --- a/qt/widgets/common/test/DataProcessorUI/DataProcessorTwoLevelTreeManagerTest.h +++ b/qt/widgets/common/test/DataProcessorUI/DataProcessorTwoLevelTreeManagerTest.h @@ -30,7 +30,7 @@ #include "MantidQtWidgets/Common/DataProcessorUI/PauseCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/PlotGroupCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/PlotRowCommand.h" -#include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorProcessCommand.h" +#include "MantidQtWidgets/Common/DataProcessorUI/ProcessCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSaveTableAsCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSaveTableCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSeparatorCommand.h" @@ -149,7 +149,7 @@ public: TS_ASSERT(dynamic_cast<DataProcessorSeparatorCommand *>(comm[7].get())); TS_ASSERT(dynamic_cast<OptionsCommand *>(comm[8].get())); TS_ASSERT(dynamic_cast<DataProcessorSeparatorCommand *>(comm[9].get())); - TS_ASSERT(dynamic_cast<DataProcessorProcessCommand *>(comm[10].get())); + TS_ASSERT(dynamic_cast<ProcessCommand *>(comm[10].get())); TS_ASSERT(dynamic_cast<PauseCommand *>(comm[11].get())); TS_ASSERT(dynamic_cast<DataProcessorSeparatorCommand *>(comm[12].get())); TS_ASSERT(dynamic_cast<ExpandCommand *>(comm[13].get())); diff --git a/qt/widgets/common/test/DataProcessorUI/OneLevelTreeManagerTest.h b/qt/widgets/common/test/DataProcessorUI/OneLevelTreeManagerTest.h index 452f5c31437..60b4c49ed34 100644 --- a/qt/widgets/common/test/DataProcessorUI/OneLevelTreeManagerTest.h +++ b/qt/widgets/common/test/DataProcessorUI/OneLevelTreeManagerTest.h @@ -23,7 +23,7 @@ #include "MantidQtWidgets/Common/DataProcessorUI/PasteSelectedCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/PauseCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/PlotRowCommand.h" -#include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorProcessCommand.h" +#include "MantidQtWidgets/Common/DataProcessorUI/ProcessCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSaveTableAsCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSaveTableCommand.h" #include "MantidQtWidgets/Common/DataProcessorUI/DataProcessorSeparatorCommand.h" @@ -137,7 +137,7 @@ public: TS_ASSERT(dynamic_cast<DataProcessorSeparatorCommand *>(comm[7].get())); TS_ASSERT(dynamic_cast<OptionsCommand *>(comm[8].get())); TS_ASSERT(dynamic_cast<DataProcessorSeparatorCommand *>(comm[9].get())); - TS_ASSERT(dynamic_cast<DataProcessorProcessCommand *>(comm[10].get())); + TS_ASSERT(dynamic_cast<ProcessCommand *>(comm[10].get())); TS_ASSERT(dynamic_cast<PauseCommand *>(comm[11].get())); TS_ASSERT(dynamic_cast<DataProcessorSeparatorCommand *>(comm[12].get())); TS_ASSERT(dynamic_cast<PlotRowCommand *>(comm[13].get())); diff --git a/scripts/Interface/ui/dataprocessorinterface/data_processor_gui.py b/scripts/Interface/ui/dataprocessorinterface/data_processor_gui.py index d9fe31ee11b..ce446e65b74 100644 --- a/scripts/Interface/ui/dataprocessorinterface/data_processor_gui.py +++ b/scripts/Interface/ui/dataprocessorinterface/data_processor_gui.py @@ -160,7 +160,7 @@ class DataProcessorGui(QtGui.QMainWindow, ui_data_processor_window.Ui_DataProces self.menuFile.clear() # Actions that go in the 'Edit' menu - self._create_action(MantidQt.MantidWidgets.DataProcessorProcessCommand(self.data_processor_table), self.menuEdit) + self._create_action(MantidQt.MantidWidgets.ProcessCommand(self.data_processor_table), self.menuEdit) self._create_action(MantidQt.MantidWidgets.ExpandCommand(self.data_processor_table), self.menuEdit) self._create_action(MantidQt.MantidWidgets.PlotRowCommand(self.data_processor_table), self.menuEdit) self._create_action(MantidQt.MantidWidgets.PlotGroupCommand(self.data_processor_table), self.menuEdit) diff --git a/scripts/Interface/ui/poldi/poldi_gui.py b/scripts/Interface/ui/poldi/poldi_gui.py index 21f41eb28a2..4f38f2bef01 100644 --- a/scripts/Interface/ui/poldi/poldi_gui.py +++ b/scripts/Interface/ui/poldi/poldi_gui.py @@ -149,7 +149,7 @@ class PoldiGui(QtGui.QMainWindow, ui_poldi_window.Ui_PoldiWindow): self.menuFile.addAction(demo) # Actions that go in the 'Edit' menu - self._create_action(MantidQt.MantidWidgets.DataProcessorProcessCommand(self.data_processor_table), self.menuEdit) + self._create_action(MantidQt.MantidWidgets.ProcessCommand(self.data_processor_table), self.menuEdit) self._create_action(MantidQt.MantidWidgets.ExpandCommand(self.data_processor_table), self.menuEdit) self._create_action(MantidQt.MantidWidgets.PlotRowCommand(self.data_processor_table), self.menuEdit) self._create_action(MantidQt.MantidWidgets.PlotGroupCommand(self.data_processor_table), self.menuEdit) diff --git a/scripts/Interface/ui/sans_isis/sans_data_processor_gui.py b/scripts/Interface/ui/sans_isis/sans_data_processor_gui.py index e7d512f8fec..28e4db2e464 100644 --- a/scripts/Interface/ui/sans_isis/sans_data_processor_gui.py +++ b/scripts/Interface/ui/sans_isis/sans_data_processor_gui.py @@ -1465,7 +1465,7 @@ class SANSDataProcessorGui(QtGui.QMainWindow, ui_sans_data_processor_window.Ui_S self.menuFile.clear() # Actions that go in the 'Edit' menu - self._create_action(MantidQt.MantidWidgets.DataProcessorProcessCommand(self.data_processor_table), + self._create_action(MantidQt.MantidWidgets.ProcessCommand(self.data_processor_table), self.menuEdit) self._create_action(MantidQt.MantidWidgets.PlotRowCommand(self.data_processor_table), self.menuEdit) -- GitLab