diff options
| author | Mikaël Capelle <capelle.mikael@gmail.com> | 2020-12-28 17:15:22 +0100 |
|---|---|---|
| committer | Mikaël Capelle <capelle.mikael@gmail.com> | 2021-01-02 15:38:15 +0100 |
| commit | b340c564cfd151540bf5b03f3f878153b8f120ee (patch) | |
| tree | afb2265f9f93c79564622e02d2bd8b8073956dda /src/modlist.h | |
| parent | 9d8c64dccbdb5144c6496cbd9ef4eb636f6b4ace (diff) | |
Fix keyboard move selection.
Diffstat (limited to 'src/modlist.h')
| -rw-r--r-- | src/modlist.h | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/src/modlist.h b/src/modlist.h index 4e50c959..83e8ec9c 100644 --- a/src/modlist.h +++ b/src/modlist.h @@ -55,6 +55,10 @@ class ModList : public QAbstractItemModel public:
+ // role of the index of the mod
+ //
+ constexpr static int IndexRole = Qt::UserRole + 1;
+
enum EColumn {
COL_NAME,
COL_CONFLICTFLAGS,
@@ -70,8 +74,6 @@ public: COL_LASTCOLUMN = COL_NOTES,
};
- friend class ModListProxy;
-
using SignalModInstalled = boost::signals2::signal<void(MOBase::IModInterface*)>;
using SignalModRemoved = boost::signals2::signal<void(QString const&)>;
using SignalModStateChanged = boost::signals2::signal<void (const std::map<QString, MOBase::IModList::ModStates>&)>;
@@ -222,12 +224,12 @@ public slots: signals:
/**
- * @brief emitted whenever the sorting in the list was changed by the user
+ * @brief Emitted whenever the priority of mods changes
*
- * the sorting of the list can only be manually changed if the list is sorted by priority
- * in which case the move is intended to change the priority of a mod
+ * The sorting of the list can only be manually changed if the list is sorted by priority
+ * in which case the move is intended to change the priority of a mod.
**/
- void modorder_changed();
+ void modPrioritiesChanged(std::vector<int> const& index);
/**
* @brief emitted when the model wants a text to be displayed by the UI
@@ -389,6 +391,7 @@ private: private:
+ friend class ModListProxy;
friend class ModListByPriorityProxy;
OrganizerCore *m_Organizer;
|
