From 25cdcdd2fe6a7317f338ae85405ac1338670cbb0 Mon Sep 17 00:00:00 2001 From: Tannin Date: Wed, 16 Oct 2013 23:04:03 +0200 Subject: [PATCH] =?UTF-8?q?-=20plugin=20(esp/esm)=20list=20is=20now=20expo?= =?UTF-8?q?sed=20to=20plugins=20(read-only=20functionality=20right=20now)?= =?UTF-8?q?=20-=20integrated=20fomod=20installer=20now=20supports=20file?= =?UTF-8?q?=20dependencies=20-=20bugfix:=20integrated=20fomod=20installer?= =?UTF-8?q?=20crashed=20if=20the=20installer=20had=20no=20optiosn=B4=B4ns?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/runner/proxypluginwrappers.cpp | 2 +- src/runner/pythonrunner.cpp | 6 +++++- src/runner/uibasewrappers.h | 9 ++++----- 3 files changed, 10 insertions(+), 7 deletions(-) diff --git a/src/runner/proxypluginwrappers.cpp b/src/runner/proxypluginwrappers.cpp index 7835a1b..ec2fb1f 100644 --- a/src/runner/proxypluginwrappers.cpp +++ b/src/runner/proxypluginwrappers.cpp @@ -171,7 +171,7 @@ bool IPluginInstallerCustomWrapper::isManualInstaller() const } PYCATCH; } -bool IPluginInstallerCustomWrapper::isArchiveSupported(const DirectoryTree &tree) const +bool IPluginInstallerCustomWrapper::isArchiveSupported(const DirectoryTree &) const { try { //return this->get_override("isArchiveSupported")(tree); diff --git a/src/runner/pythonrunner.cpp b/src/runner/pythonrunner.cpp index 842cf07..556e0b3 100644 --- a/src/runner/pythonrunner.cpp +++ b/src/runner/pythonrunner.cpp @@ -577,7 +577,11 @@ BOOST_PYTHON_MODULE(mobase) .def("setPersistent", bpy::pure_virtual(&IOrganizer::setPersistent)) .def("pluginDataPath", bpy::pure_virtual(&IOrganizer::pluginDataPath)) .def("installMod", bpy::pure_virtual(&IOrganizer::installMod)) - .def("downloadManager", bpy::pure_virtual(&IOrganizer::downloadManager), bpy::return_value_policy()); + .def("downloadManager", bpy::pure_virtual(&IOrganizer::downloadManager), bpy::return_value_policy()) + .def("pluginList", bpy::pure_virtual(&IOrganizer::pluginList), bpy::return_value_policy()) + .def("startApplication", bpy::pure_virtual(&IOrganizer::startApplication), bpy::return_value_policy()) + .def("onAboutToRun", bpy::pure_virtual(&IOrganizer::onAboutToRun)) + ; bpy::class_("ModRepositoryBridge") .def("requestDescription", &ModRepositoryBridgeWrapper::requestDescription) diff --git a/src/runner/uibasewrappers.h b/src/runner/uibasewrappers.h index 41528e0..007dc8d 100644 --- a/src/runner/uibasewrappers.h +++ b/src/runner/uibasewrappers.h @@ -119,10 +119,6 @@ struct IOrganizerWrapper: MOBase::IOrganizer, boost::python::wrapperget_override("createNexusBridge")(); } -/* - static ModRepositoryBridgeWrapper newNexusBridge(IOrganizerWrapper *self) { - return ModRepositoryBridgeWrapper(self->createNexusBridge()); - }*/ virtual QString profileName() const { return this->get_override("profileName")(); } virtual QString profilePath() const { return this->get_override("profilePath")(); } @@ -139,10 +135,13 @@ struct IOrganizerWrapper: MOBase::IOrganizer, boost::python::wrapperget_override("pluginDataPath")(); } virtual void installMod(const QString &fileName) { this->get_override("installMod")(fileName); } virtual MOBase::IDownloadManager *downloadManager() { return this->get_override("downloadManager")(); } + virtual MOBase::IPluginList *pluginList() { return this->get_override("pluginList")(); } virtual QString resolvePath(const QString &fileName) const { return this->get_override("resolvePath")(fileName); } virtual QStringList listDirectories(const QString &directoryName) const { return this->get_override("listDirectories")(directoryName); } virtual QStringList findFiles(const QString &path, const std::function &filter) const { return this->get_override("findFiles")(path, filter); } - virtual void onAboutToRun(const boost::function &func) { this->get_override("onAboutToRun")(func); } + virtual HANDLE startApplication(const QString &executable, const QStringList &args = QStringList(), const QString &cwd = "", const QString &profile = "") { return this->get_override("startApplication")(executable, args, cwd, profile); } + virtual bool onAboutToRun(const std::function &func) { return this->get_override("onAboutToRun")(func); } + }; struct IDownloadManagerWrapper: MOBase::IDownloadManager, boost::python::wrapper