From f010c22a3b2ec31bc4ebc3f577ac4455c5de5dfb Mon Sep 17 00:00:00 2001 From: Tannin Date: Wed, 6 Nov 2013 18:35:27 +0100 Subject: - diagnosis plugins can now request to be re-evaluated - main application now contains means for plugins to react on some changes (to be extended) - plugins can now retrieve more information about a mod - user-agent sent to nexus now automatically contains the current MO version - included updated russian translation - problems dialog now refreshes itself after a fix was applied - fixed new esp/asset ordering diagnosis. May be fully functional now - bugfix: restoring locked load order could leave MO in an endless loop (not sure if this fix is correct yet) - bugfix: plugin list was not visually updated after some changes - bugfix: nmm importer threw away mod ordering --- src/modlist.h | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) (limited to 'src/modlist.h') diff --git a/src/modlist.h b/src/modlist.h index cdaa24ca..8cab7f3e 100644 --- a/src/modlist.h +++ b/src/modlist.h @@ -32,7 +32,7 @@ along with Mod Organizer. If not, see . #include #include #include - +#include #include #include #include @@ -61,6 +61,8 @@ public: COL_LASTCOLUMN = COL_PRIORITY }; + typedef boost::signals2::signal SignalModStateChanged; + public: /** @@ -94,10 +96,13 @@ public: void changeModPriority(int sourceIndex, int newPriority); + void modInfoAboutToChange(ModInfo::Ptr info); + void modInfoChanged(ModInfo::Ptr info); + public: /// \copydoc MOBase::IModList::state - virtual ModState state(const QString &name) const; + virtual ModStates state(const QString &name) const; /// \copydoc MOBase::IModList::priority virtual int priority(const QString &name) const; @@ -105,6 +110,9 @@ public: /// \copydoc MOBase::IModList::setPriority virtual bool setPriority(const QString &name, int newPriority); + /// \copydoc MOBase::IModList::onModStateChanged + virtual bool onModStateChanged(const std::function &func); + public: // implementation of virtual functions of QAbstractItemModel virtual int rowCount(const QModelIndex &parent = QModelIndex()) const; @@ -245,6 +253,11 @@ private: unsigned int categoryOrder; }; + struct TModInfoChange { + QString name; + QFlags state; + }; + private: Profile *m_Profile; @@ -258,6 +271,10 @@ private: bool m_DropOnItems; + TModInfoChange m_ChangeInfo; + + SignalModStateChanged m_ModStateChanged; + }; #endif // MODLIST_H -- cgit v1.3.1