Merge pull request #21 from ModOrganizer2/Develop

Stage for release 2.1.6
This commit is contained in:
LostDragonist
2018-12-20 13:58:41 -06:00
committed by GitHub
9 changed files with 1929 additions and 1815 deletions
+1 -1
View File
@@ -14,7 +14,7 @@ LIST(APPEND CMAKE_PREFIX_PATH ${QT_ROOT}/lib/cmake)
FILE(GLOB_RECURSE PYTHON_ROOT ${DEPENDENCIES_DIR}/Python*/pyconfig.h.in)
GET_FILENAME_COMPONENT(PYTHON_ROOT ${PYTHON_ROOT} DIRECTORY)
FILE(GLOB_RECURSE SIP_ROOT ${DEPENDENCIES_DIR}/sip*/siplib/sip.h)
FILE(GLOB_RECURSE SIP_ROOT ${DEPENDENCIES_DIR}/sip-*/siplib/sip.h)
GET_FILENAME_COMPONENT(SIP_ROOT ${SIP_ROOT} DIRECTORY)
# need to install python
+1 -1
View File
@@ -196,7 +196,7 @@ QString ProxyPython::description() const
VersionInfo ProxyPython::version() const
{
return VersionInfo(1, 3, 1, VersionInfo::RELEASE_FINAL);
return VersionInfo(2, 0, 0, VersionInfo::RELEASE_FINAL);
}
bool ProxyPython::isActive() const
+1
View File
@@ -13,6 +13,7 @@ FILE(GLOB ${PROJ_NAME}_HDRS *.h)
SET(CMAKE_INCLUDE_CURRENT_DIR ON)
SET(CMAKE_AUTOMOC ON)
SET(CMAKE_AUTOUIC ON)
ADD_DEFINITIONS(-DQT_NO_KEYWORDS)
FIND_PACKAGE(Qt5Widgets REQUIRED)
#QT5_WRAP_UI(${PROJ_NAME}_UIHDRS ${${PROJ_NAME}_FORMS})
FIND_PACKAGE(Qt5LinguistTools)
+17 -4
View File
@@ -23,13 +23,18 @@ bool BSAInvalidationWrapper::isInvalidationBSA(const QString &bsaName)
void BSAInvalidationWrapper::deactivate(MOBase::IProfile *profile)
{
basicWrapperFunctionImplementation<BSAInvalidationWrapper, void>(this, "deactivate", boost::python::ptr(profile));
return basicWrapperFunctionImplementation<BSAInvalidationWrapper, void>(this, "deactivate", boost::python::ptr(profile));
}
void BSAInvalidationWrapper::activate(MOBase::IProfile *profile)
{
return basicWrapperFunctionImplementation<BSAInvalidationWrapper, void>(this, "activate", boost::python::ptr(profile));
}
bool BSAInvalidationWrapper::prepareProfile(MOBase::IProfile *profile)
{
return basicWrapperFunctionImplementation<BSAInvalidationWrapper, bool>(this, "prepareProfile", boost::python::ptr(profile));
}
/// end BSAInvalidation Wrapper
/////////////////////////////
/// DataArchives Wrapper
@@ -50,7 +55,7 @@ void DataArchivesWrapper::addArchive(MOBase::IProfile *profile, int index, const
return basicWrapperFunctionImplementation<DataArchivesWrapper, void>(this, "addArchive", boost::python::ptr(profile), index, archiveName);
}
void DataArchivesWrapper::removeArchive(MOBase::IProfile * profile, const QString & archiveName)
void DataArchivesWrapper::removeArchive(MOBase::IProfile *profile, const QString &archiveName)
{
return basicWrapperFunctionImplementation<DataArchivesWrapper, void>(this, "removeArchive", boost::python::ptr(profile), archiveName);
}
@@ -68,6 +73,12 @@ void GamePluginsWrapper::readPluginLists(MOBase::IPluginList * pluginList)
{
return basicWrapperFunctionImplementation<GamePluginsWrapper, void>(this, "readPluginLists", boost::python::ptr(pluginList));
}
void GamePluginsWrapper::getLoadOrder(QStringList &loadOrder)
{
return basicWrapperFunctionImplementation<GamePluginsWrapper, void>(this, "getLoadOrder", loadOrder);
}
/// end GamePlugins Wrapper
/////////////////////////////
/// LocalSavegames Wrapper
@@ -78,10 +89,11 @@ MappingType LocalSavegamesWrapper::mappings(const QDir & profileSaveDir) const
return basicWrapperFunctionImplementation<LocalSavegamesWrapper, MappingType>(this, "mappings", profileSaveDir);
}
void LocalSavegamesWrapper::prepareProfile(MOBase::IProfile * profile)
bool LocalSavegamesWrapper::prepareProfile(MOBase::IProfile * profile)
{
return basicWrapperFunctionImplementation<LocalSavegamesWrapper, void>(this, "prepareProfile", boost::python::ptr(profile));
return basicWrapperFunctionImplementation<LocalSavegamesWrapper, bool>(this, "prepareProfile", boost::python::ptr(profile));
}
/// end LocalSavegames Wrapper
/////////////////////////////
/// SaveGameInfo Wrapper
@@ -248,6 +260,7 @@ void registerGameFeaturesPythonConverters()
bpy::class_<GamePluginsWrapper, boost::noncopyable>("GamePlugins")
.def("writePluginLists", bpy::pure_virtual(&GamePlugins::writePluginLists))
.def("readPluginLists", bpy::pure_virtual(&GamePlugins::readPluginLists))
.def("getLoadOrder", bpy::pure_virtual(&GamePlugins::getLoadOrder))
;
bpy::class_<LocalSavegamesWrapper, boost::noncopyable>("LocalSavegames")
+3 -1
View File
@@ -24,6 +24,7 @@ public:
virtual bool isInvalidationBSA(const QString &bsaName) override;
virtual void deactivate(MOBase::IProfile *profile) override;
virtual void activate(MOBase::IProfile *profile) override;
virtual bool prepareProfile(MOBase::IProfile *profile) override;
};
class DataArchivesWrapper : public DataArchives, public boost::python::wrapper<DataArchives>
@@ -46,6 +47,7 @@ public:
virtual void writePluginLists(const MOBase::IPluginList *pluginList) override;
virtual void readPluginLists(MOBase::IPluginList *pluginList) override;
virtual void getLoadOrder(QStringList &loadOrder) override;
};
class LocalSavegamesWrapper : public LocalSavegames, public boost::python::wrapper<LocalSavegames>
@@ -55,7 +57,7 @@ public:
using boost::python::wrapper<LocalSavegames>::get_override;
virtual MappingType mappings(const QDir &profileSaveDir) const override;
virtual void prepareProfile(MOBase::IProfile *profile) override;
virtual bool prepareProfile(MOBase::IProfile *profile) override;
};
class SaveGameInfoWrapper : public SaveGameInfo, public boost::python::wrapper<SaveGameInfo>
+1 -1
View File
@@ -202,7 +202,7 @@ public:
virtual QIcon icon() const;
virtual void setParentWidget(QWidget *parent);
public slots:
public Q_SLOTS:
virtual void display() const;
};
+1412 -1345
View File
File diff suppressed because it is too large Load Diff
+30 -1
View File
@@ -7,7 +7,36 @@ static const sipAPIDef *sipAPI()
{
static const sipAPIDef *sipApi = nullptr;
if (sipApi == nullptr) {
sipApi = (const sipAPIDef *)PyCapsule_Import("sip._C_API", 0);
#if defined(SIP_USE_PYCAPSULE)
PyImport_ImportModule("PyQt5.sip");
sipApi = (const sipAPIDef *)PyCapsule_Import("PyQt5.sip._C_API", 0);
#else
PyObject *sip_module;
PyObject *sip_module_dict;
PyObject *c_api;
/* Import the SIP module. */
sip_module = PyImport_ImportModule("PyQt5.sip");
if (sip_module == NULL)
return NULL;
/* Get the module's dictionary. */
sip_module_dict = PyModule_GetDict(sip_module);
/* Get the "_C_API" attribute. */
c_api = PyDict_GetItemString(sip_module_dict, "_C_API");
if (c_api == NULL)
return NULL;
/* Sanity check that it is the right type. */
if (!PyCObject_Check(c_api))
return NULL;
/* Get the actual pointer from the object. */
sipApi = (const sipAPIDef *)PyCObject_AsVoidPtr(c_api);
#endif
}
return sipApi;
File diff suppressed because it is too large Load Diff