From 977b4075254ca79e68bbdec2e689eccb291fe701 Mon Sep 17 00:00:00 2001 From: Tannin Date: Tue, 13 May 2014 21:20:44 +0200 Subject: - mod list context menu split into two menus (one for whole list, one for selected mods) - added option to combine category filters using "or" - added context menu option for deselecting category filters - slightly changed ui on the category filters - added a sample plugin for cpp that can be built without building the rest of MO - simple installer can now be configured to run without any user interaction - extended interface for python plugins - iorganizer implementation moved out of the main window - nexus requests from plugins will now be identified in the user agent - bugfix: shortcuts created from MO used the wrong working directory - bugfix: deactivation of bsas didn't stick - bugfix: file hiding mechanism wasn't active - bugfix: executables linked on the toolbar couldn't be removed if the executable was removed first - bugfix: the endorsement-filter couldn't be combined with other filters - bugfix: python interface to repository bridge was broken --- src/organizerproxy.h | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 src/organizerproxy.h (limited to 'src/organizerproxy.h') diff --git a/src/organizerproxy.h b/src/organizerproxy.h new file mode 100644 index 00000000..fd9dd56a --- /dev/null +++ b/src/organizerproxy.h @@ -0,0 +1,48 @@ +#ifndef ORGANIZERPROXY_H +#define ORGANIZERPROXY_H + + +#include +#include "mainwindow.h" + +class OrganizerProxy : public MOBase::IOrganizer +{ +public: + OrganizerProxy(MainWindow *window, const QString &pluginName); + + virtual MOBase::IGameInfo &gameInfo() const; + virtual MOBase::IModRepositoryBridge *createNexusBridge() const; + virtual QString profileName() const; + virtual QString profilePath() const; + virtual QString downloadsPath() const; + virtual MOBase::VersionInfo appVersion() const; + virtual MOBase::IModInterface *getMod(const QString &name); + virtual MOBase::IModInterface *createMod(MOBase::GuessedValue &name); + virtual bool removeMod(MOBase::IModInterface *mod); + virtual void modDataChanged(MOBase::IModInterface *mod); + virtual QVariant pluginSetting(const QString &pluginName, const QString &key) const; + virtual void setPluginSetting(const QString &pluginName, const QString &key, const QVariant &value); + virtual QVariant persistent(const QString &pluginName, const QString &key, const QVariant &def = QVariant()) const; + virtual void setPersistent(const QString &pluginName, const QString &key, const QVariant &value, bool sync = true); + virtual QString pluginDataPath() const; + virtual MOBase::IModInterface *installMod(const QString &fileName); + virtual QString resolvePath(const QString &fileName) const; + virtual QStringList listDirectories(const QString &directoryName) const; + virtual QStringList findFiles(const QString &path, const std::function &filter) const; + virtual QList findFileInfos(const QString &path, const std::function &filter) const; + + virtual MOBase::IDownloadManager *downloadManager(); + virtual MOBase::IPluginList *pluginList(); + virtual MOBase::IModList *modList(); + virtual HANDLE startApplication(const QString &executable, const QStringList &args = QStringList(), const QString &cwd = "", const QString &profile = ""); + virtual bool onAboutToRun(const std::function &func); + virtual void refreshModList(bool saveChanges); + +private: + MainWindow *m_Proxied; + const QString &m_PluginName; + +}; + + +#endif // ORGANIZERPROXY_H -- cgit v1.3.1