From b95373cb12379db7f55bce50cca2d7ef217ac423 Mon Sep 17 00:00:00 2001 From: Mikaƫl Capelle Date: Sat, 5 Sep 2020 13:49:55 +0200 Subject: Change for onPluginStateChanged to take a list of plugins. --- src/pluginlist.h | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'src/pluginlist.h') diff --git a/src/pluginlist.h b/src/pluginlist.h index 00679a35..0b49b86f 100644 --- a/src/pluginlist.h +++ b/src/pluginlist.h @@ -96,7 +96,7 @@ public: typedef boost::signals2::signal SignalRefreshed; typedef boost::signals2::signal SignalPluginMoved; - typedef boost::signals2::signal SignalPluginStateChanged; + typedef boost::signals2::signal&)> SignalPluginStateChanged; public: @@ -235,7 +235,7 @@ public: virtual QString origin(const QString &name) const override; virtual void setLoadOrder(const QStringList &pluginList) override; virtual bool onPluginMoved(const std::function &func) override; - virtual bool onPluginStateChanged(const std::function &func) override; + virtual bool onPluginStateChanged(const std::function&)> &func) override; public: // implementation of the QAbstractTableModel interface @@ -361,6 +361,15 @@ private: int findPluginByPriority(int priority); + /** + * @brief Notify MO2 plugins that the states of the given plugins have changed to the given state. + * + * @param pluginNames Names of the plugin. + * @param state New state of the plugin. + * + */ + void pluginStatesChanged(QStringList const& pluginNames, IPluginList::PluginStates state) const; + private: std::vector m_ESPs; -- cgit v1.3.1