diff options
| author | Jonathan Feenstra <26406078+JonathanFeenstra@users.noreply.github.com> | 2024-09-28 19:58:29 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-09-28 19:58:29 +0200 |
| commit | 7ed06a77c1119b6ee7cd6d32893339465197f420 (patch) | |
| tree | e1c108d4fe88e0047330538854ff6f226659365e /src/pluginlist.cpp | |
| parent | 9c130cbf2fc7225fb2916e46419af50671772aa0 (diff) | |
Add author and description methods to IPluginList (#2118)
Diffstat (limited to 'src/pluginlist.cpp')
| -rw-r--r-- | src/pluginlist.cpp | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/pluginlist.cpp b/src/pluginlist.cpp index 94aee98d..9a49b828 100644 --- a/src/pluginlist.cpp +++ b/src/pluginlist.cpp @@ -1028,6 +1028,26 @@ bool PluginList::hasNoRecords(const QString& name) const } } +QString PluginList::author(const QString& name) const +{ + auto iter = m_ESPsByName.find(name); + if (iter == m_ESPsByName.end()) { + return QString(); + } else { + return m_ESPs[iter->second].author; + } +} + +QString PluginList::description(const QString& name) const +{ + auto iter = m_ESPsByName.find(name); + if (iter == m_ESPsByName.end()) { + return QString(); + } else { + return m_ESPs[iter->second].description; + } +} + boost::signals2::connection PluginList::onPluginStateChanged( const std::function<void(const std::map<QString, PluginStates>&)>& func) { |
