summaryrefslogtreecommitdiff
path: root/src/installationmanager.cpp
diff options
context:
space:
mode:
authorMikaƫl Capelle <capelle.mikael@gmail.com>2020-09-23 18:40:20 +0200
committerGitHub <noreply@github.com>2020-09-23 18:40:20 +0200
commitbf351ff80b42aaf105771ff2078f99bb48b044ea (patch)
tree79bf6333fb838ccd6b72a089de0f4865f00ec4eb /src/installationmanager.cpp
parent865ae1d802cc58cc812f4802c0b3f8c1ca7a38f3 (diff)
parent8980153a2cba833cf8817e15e814bc7b6c2d2230 (diff)
Merge pull request #1238 from Holt59/plugin-installer-callbacks
Add IPluginInstaller onInstallationStart and onInstallationEnd callbacks
Diffstat (limited to 'src/installationmanager.cpp')
-rw-r--r--src/installationmanager.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/installationmanager.cpp b/src/installationmanager.cpp
index e089d560..a755b0cb 100644
--- a/src/installationmanager.cpp
+++ b/src/installationmanager.cpp
@@ -868,3 +868,19 @@ QStringList InstallationManager::getSupportedExtensions() const
{
return QStringList(std::begin(m_SupportedExtensions), std::end(m_SupportedExtensions));
}
+
+void InstallationManager::notifyInstallationStart(QString const& archive, bool reinstallation, ModInfo::Ptr currentMod)
+{
+ for (auto* installer : m_Installers) {
+ installer->onInstallationStart(archive, reinstallation, currentMod.get());
+ }
+}
+
+void InstallationManager::notifyInstallationEnd(
+ MOBase::IPluginInstaller::EInstallResult result,
+ ModInfo::Ptr newMod)
+{
+ for (auto* installer : m_Installers) {
+ installer->onInstallationEnd(result, newMod.get());
+ }
+}