Mantid
Loading...
Searching...
No Matches
JobTreeViewSignalAdapter.cpp
Go to the documentation of this file.
1// Mantid Repository : https://github.com/mantidproject/mantid
2//
3// Copyright © 2018 ISIS Rutherford Appleton Laboratory UKRI,
4// NScD Oak Ridge National Laboratory, European Spallation Source,
5// Institut Laue - Langevin & CSNS, Institute of High Energy Physics, CAS
6// SPDX - License - Identifier: GPL - 3.0 +
8
10JobTreeViewSignalAdapter::JobTreeViewSignalAdapter(JobTreeView &view, QObject *parent) : QObject(parent) {
11 qRegisterMetaType<RowLocation>("MantidQt::MantidWidgets::Batch::RowLocation");
12 qRegisterMetaType<std::vector<RowLocation>>("std::vector<MantidQt::MantidWidgets::Batch::RowLocation>");
13 view.subscribe(this);
14}
15
17 std::string const &oldValue, std::string const &newValue) {
18 emit cellTextChanged(itemIndex, column, oldValue, newValue);
19}
20
22
24 emit rowInserted(newRowLocation);
25}
26
28
30
32
33void JobTreeViewSignalAdapter::notifyRemoveRowsRequested(std::vector<RowLocation> const &locationsOfRowsToRemove) {
34 emit removeRowsRequested(locationsOfRowsToRemove);
35}
36
38
40
42
44} // namespace MantidQt::MantidWidgets::Batch
void notifyRowInserted(RowLocation const &newRowLocation) override
void removeRowsRequested(std::vector< MantidQt::MantidWidgets::Batch::RowLocation > const &locationsOfRowsToRemove)
void notifyRemoveRowsRequested(std::vector< RowLocation > const &locationsOfRowsToRemove) override
void rowInserted(MantidQt::MantidWidgets::Batch::RowLocation const &newRowLocation)
JobTreeViewSignalAdapter(JobTreeView &view, QObject *parent=nullptr)
void cellTextChanged(MantidQt::MantidWidgets::Batch::RowLocation const &itemIndex, int column, std::string const &oldValue, std::string const &newValue)
void notifyCellTextChanged(RowLocation const &itemIndex, int column, std::string const &oldValue, std::string const &newValue) override
void subscribe(JobTreeViewSubscriber *subscriber) override