Index: sources/view/dg/data/VDGPostSingleResultData.h =================================================================== diff -u -r83ffaef436920eba534cde428e14d168ea931bea -r8f45330e0b1af61e029bece73c9f23669ada56c1 --- sources/view/dg/data/VDGPostSingleResultData.h (.../VDGPostSingleResultData.h) (revision 83ffaef436920eba534cde428e14d168ea931bea) +++ sources/view/dg/data/VDGPostSingleResultData.h (.../VDGPostSingleResultData.h) (revision 8f45330e0b1af61e029bece73c9f23669ada56c1) @@ -22,7 +22,6 @@ #include "main.h" // Doxygen : don't remove #include "VView.h" #include "MDGPostSingleResultData.h" -#include "MSettings.h" // namespace namespace View { @@ -34,38 +33,9 @@ * \sa Model::MDGPostSingleResultData * */ -class VDGPostSingleResult : public QAbstractListModel { +class VDGPostSingleResult : public QObject { Q_OBJECT - PROPERTY(quint32, result, 0) - PROPERTY(quint32, index, 0) - - VIEW_DEC_SLOT(DGPostSingleResultData) - VIEW_DEC_SLOT(SettingsData) - -private: - struct PostTest { - QString name; - quint32 result = 2; - }; - - QList _tests; - -public: - explicit VDGPostSingleResult(QAbstractListModel *parent = nullptr); - - enum TestDataRole { - TestNameRole = Qt::UserRole + 1, - TestResultRole, - }; -protected: - int rowCount (const QModelIndex &parent = QModelIndex()) const override; - QVariant data (const QModelIndex &index, int role = Qt::DisplayRole) const override; - QHash roleNames() const override; - bool setData(int vIndex, const QVariant &vValue, const TestDataRole &vRole); - void removeAllRows(); -private: - void initConnections(); - void addSelfTest(const PostTest &vTest); + VIEW_DEC(VDGPostSingleResult, DGPostSingleResultData) }; }