Changeset View
Changeset View
Standalone View
Standalone View
kmymoney/plugins/views/onlinejoboutbox/onlinejobmodel.h
- This file was moved from kmymoney/models/onlinejobmodel.h.
Show All 40 Lines | 32 | public: | |||
---|---|---|---|---|---|
41 | 41 | | |||
42 | enum columns { | 42 | enum columns { | ||
43 | ColAccount, | 43 | ColAccount, | ||
44 | ColAction, | 44 | ColAction, | ||
45 | ColDestination, | 45 | ColDestination, | ||
46 | ColValue | 46 | ColValue | ||
47 | }; | 47 | }; | ||
48 | 48 | | |||
49 | /** Only @ref Models should be able to construct this class */ | ||||
50 | explicit onlineJobModel(QObject *parent = nullptr); | ||||
51 | friend class Models; | ||||
52 | | ||||
49 | int rowCount(const QModelIndex & parent = QModelIndex()) const; | 53 | int rowCount(const QModelIndex & parent = QModelIndex()) const; | ||
50 | int columnCount(const QModelIndex & parent = QModelIndex()) const; | 54 | int columnCount(const QModelIndex & parent = QModelIndex()) const; | ||
51 | QVariant data(const QModelIndex & index, int role = Qt::DisplayRole) const; | 55 | QVariant data(const QModelIndex & index, int role = Qt::DisplayRole) const; | ||
52 | QVariant headerData(int section, Qt::Orientation orientation , int role = Qt::DisplayRole) const; | 56 | QVariant headerData(int section, Qt::Orientation orientation , int role = Qt::DisplayRole) const; | ||
53 | /** @brief Remove onlineJob identified by row */ | 57 | /** @brief Remove onlineJob identified by row */ | ||
54 | bool removeRow(int row, const QModelIndex & parent = QModelIndex()); | 58 | bool removeRow(int row, const QModelIndex & parent = QModelIndex()); | ||
55 | /** @brief Remove onlineJobs identified by row and count */ | 59 | /** @brief Remove onlineJobs identified by row and count */ | ||
56 | bool removeRows(int row, int count, const QModelIndex & parent = QModelIndex()); | 60 | bool removeRows(int row, int count, const QModelIndex & parent = QModelIndex()); | ||
57 | 61 | | |||
58 | Q_SIGNALS: | 62 | Q_SIGNALS: | ||
59 | 63 | | |||
60 | public Q_SLOTS: | 64 | public Q_SLOTS: | ||
61 | void reloadAll(); | 65 | void reloadAll(); | ||
62 | 66 | | |||
63 | void slotObjectAdded(eMyMoney::File::Object objType, const QString &id); | 67 | void slotObjectAdded(eMyMoney::File::Object objType, const QString &id); | ||
64 | void slotObjectModified(eMyMoney::File::Object objType, const QString &id); | 68 | void slotObjectModified(eMyMoney::File::Object objType, const QString &id); | ||
65 | void slotObjectRemoved(eMyMoney::File::Object objType, const QString& id); | 69 | void slotObjectRemoved(eMyMoney::File::Object objType, const QString& id); | ||
66 | 70 | | |||
67 | /** @brief Load data from MyMoneyFile */ | 71 | /** @brief Load data from MyMoneyFile */ | ||
68 | void load(); | 72 | void load(); | ||
69 | void unload(); | 73 | void unload(); | ||
70 | 74 | | |||
71 | protected: | | |||
72 | /** Only @ref Models should be able to construct this class */ | | |||
73 | explicit onlineJobModel(QObject *parent = 0); | | |||
74 | friend class Models; | | |||
75 | | ||||
76 | private: | 75 | private: | ||
77 | QStringList m_jobIdList; | 76 | QStringList m_jobIdList; | ||
78 | 77 | | |||
79 | }; | 78 | }; | ||
80 | 79 | | |||
81 | #endif // ONLINEJOBMODEL_H | 80 | #endif // ONLINEJOBMODEL_H |