diff options
| author | Mikaƫl Capelle <capelle.mikael@gmail.com> | 2020-09-23 18:40:20 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-09-23 18:40:20 +0200 |
| commit | bf351ff80b42aaf105771ff2078f99bb48b044ea (patch) | |
| tree | 79bf6333fb838ccd6b72a089de0f4865f00ec4eb /src/installationmanager.h | |
| parent | 865ae1d802cc58cc812f4802c0b3f8c1ca7a38f3 (diff) | |
| parent | 8980153a2cba833cf8817e15e814bc7b6c2d2230 (diff) | |
Merge pull request #1238 from Holt59/plugin-installer-callbacks
Add IPluginInstaller onInstallationStart and onInstallationEnd callbacks
Diffstat (limited to 'src/installationmanager.h')
| -rw-r--r-- | src/installationmanager.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/installationmanager.h b/src/installationmanager.h index 63e8794e..149295a6 100644 --- a/src/installationmanager.h +++ b/src/installationmanager.h @@ -34,6 +34,8 @@ along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>. #include <map> #include <errorcodes.h> +#include "modinfo.h" + /** * @brief manages the installation of mod archives @@ -63,6 +65,24 @@ public: void setURL(const QString &url); /** + * @brief Notify all installer plugins that an installation is about to start. + * + * @param archive Path to the archive that is going to be installed. + * @param reinstallation True if this is a reinstallation, false otherwise. + * @param currentMod The installed mod corresponding to the archive being installed, or a null + * if there is no such mod. + */ + void notifyInstallationStart(QString const& archive, bool reinstallation, ModInfo::Ptr currentMod); + + /** + * @brief notify all installer plugins that an installation has ended. + * + * @param result The result of the installation process. + * @param currentMod The newly install mod, if result is SUCCESS, a null pointer otherwise. + */ + void notifyInstallationEnd(MOBase::IPluginInstaller::EInstallResult result, ModInfo::Ptr newMod); + + /** * @brief update the directory where mods are to be installed * @param modsDirectory the mod directory * @note this is called a lot, probably redundantly |
