aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2018-09-04 08:06:26 +0200
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2018-09-04 08:06:30 +0200
commit567a7196fdb37312a90e07c05b46e1e5e5bcc1c2 (patch)
treebc785eca5697d7b32415cf8f030adf7c37652a27
parentfafd06df5f87f13df7136cc903f4d7e094510325 (diff)
parent3d34fd298735ba352d0b6e48a7778f8820a9ddc2 (diff)
Merge remote-tracking branch 'origin/5.11' into dev
-rw-r--r--sources/pyside2/PySide2/QtCore/typesystem_core_common.xml2
-rw-r--r--sources/pyside2/PySide2/QtMultimedia/typesystem_multimedia_common.xml11
-rw-r--r--sources/pyside2/libpyside/pyside.cpp2
-rw-r--r--sources/shiboken2/generator/qtdoc/qtdocgenerator.cpp2
-rw-r--r--sources/shiboken2/libshiboken/basewrapper.cpp4
-rw-r--r--sources/shiboken2/libshiboken/bindingmanager.cpp2
-rw-r--r--sources/shiboken2/tests/libother/otherderived.h2
7 files changed, 21 insertions, 4 deletions
diff --git a/sources/pyside2/PySide2/QtCore/typesystem_core_common.xml b/sources/pyside2/PySide2/QtCore/typesystem_core_common.xml
index 309cce420..1744a5927 100644
--- a/sources/pyside2/PySide2/QtCore/typesystem_core_common.xml
+++ b/sources/pyside2/PySide2/QtCore/typesystem_core_common.xml
@@ -4312,6 +4312,7 @@ s1.addTransition(button.clicked, s1h)&lt;/code>
</add-function>
<inject-code class="native" position="beginning">
+ QT_BEGIN_NAMESPACE
extern bool
qRegisterResourceData(int,
const unsigned char *,
@@ -4323,6 +4324,7 @@ s1.addTransition(button.clicked, s1h)&lt;/code>
const unsigned char *,
const unsigned char *,
const unsigned char *);
+ QT_END_NAMESPACE
</inject-code>
<add-function signature="qRegisterResourceData(int,PyBytes,PyBytes,PyBytes)" return-type="bool">
<inject-code class="target" position="beginning">
diff --git a/sources/pyside2/PySide2/QtMultimedia/typesystem_multimedia_common.xml b/sources/pyside2/PySide2/QtMultimedia/typesystem_multimedia_common.xml
index 5486fb157..6fe90ccb9 100644
--- a/sources/pyside2/PySide2/QtMultimedia/typesystem_multimedia_common.xml
+++ b/sources/pyside2/PySide2/QtMultimedia/typesystem_multimedia_common.xml
@@ -302,6 +302,17 @@
%END_ALLOW_THREADS
</inject-code>
</modify-function>
+ <modify-function signature="setVideoOutput(QAbstractVideoSurface*)">
+ <modify-argument index="1">
+ <replace-type modified-type="QObject *" />
+ </modify-argument>
+ <inject-code class="target" position="beginning">
+ %BEGIN_ALLOW_THREADS
+ QObject* upcastedArg = %CONVERTTOCPP[QObject*](%PYARG_1);
+ %CPPSELF.%FUNCTION_NAME(reinterpret_cast&lt; %ARG1_TYPE &gt;(upcastedArg));
+ %END_ALLOW_THREADS
+ </inject-code>
+ </modify-function>
</object-type>
<object-type name="QMediaPlayerControl"/>
<object-type name="QMediaPlaylist">
diff --git a/sources/pyside2/libpyside/pyside.cpp b/sources/pyside2/libpyside/pyside.cpp
index b70743cee..367a1adc2 100644
--- a/sources/pyside2/libpyside/pyside.cpp
+++ b/sources/pyside2/libpyside/pyside.cpp
@@ -72,8 +72,10 @@
static QStack<PySide::CleanupFunction> cleanupFunctionList;
static void* qobjectNextAddr;
+QT_BEGIN_NAMESPACE
extern bool qRegisterResourceData(int, const unsigned char *, const unsigned char *,
const unsigned char *);
+QT_END_NAMESPACE
namespace PySide
{
diff --git a/sources/shiboken2/generator/qtdoc/qtdocgenerator.cpp b/sources/shiboken2/generator/qtdoc/qtdocgenerator.cpp
index b492ea49f..9a69c21b1 100644
--- a/sources/shiboken2/generator/qtdoc/qtdocgenerator.cpp
+++ b/sources/shiboken2/generator/qtdoc/qtdocgenerator.cpp
@@ -267,6 +267,8 @@ static const char *linkKeyWord(QtXmlToSphinx::LinkContext::Type type)
return ":ref:";
case QtXmlToSphinx::LinkContext::External:
break;
+ case QtXmlToSphinx::LinkContext::FunctionMask:
+ break;
}
return "";
}
diff --git a/sources/shiboken2/libshiboken/basewrapper.cpp b/sources/shiboken2/libshiboken/basewrapper.cpp
index 9eb686ed0..81830952a 100644
--- a/sources/shiboken2/libshiboken/basewrapper.cpp
+++ b/sources/shiboken2/libshiboken/basewrapper.cpp
@@ -1502,7 +1502,7 @@ std::string info(SbkObject* self)
s << String::toCString(parent) << "\n";
}
- if (self->d->parentInfo && self->d->parentInfo->children.size()) {
+ if (self->d->parentInfo && !self->d->parentInfo->children.empty()) {
s << "children.......... ";
for (SbkObject *sbkChild : self->d->parentInfo->children) {
Shiboken::AutoDecRef child(PyObject_Str(reinterpret_cast<PyObject *>(sbkChild)));
@@ -1511,7 +1511,7 @@ std::string info(SbkObject* self)
s << '\n';
}
- if (self->d->referredObjects && self->d->referredObjects->size()) {
+ if (self->d->referredObjects && !self->d->referredObjects->empty()) {
Shiboken::RefCountMap& map = *self->d->referredObjects;
s << "referred objects.. ";
std::string lastKey;
diff --git a/sources/shiboken2/libshiboken/bindingmanager.cpp b/sources/shiboken2/libshiboken/bindingmanager.cpp
index 4053b87f9..82c5bd65f 100644
--- a/sources/shiboken2/libshiboken/bindingmanager.cpp
+++ b/sources/shiboken2/libshiboken/bindingmanager.cpp
@@ -191,7 +191,7 @@ BindingManager::~BindingManager()
while (!m_d->wrapperMapper.empty()) {
Object::destroy(m_d->wrapperMapper.begin()->second, const_cast<void*>(m_d->wrapperMapper.begin()->first));
}
- assert(m_d->wrapperMapper.size() == 0);
+ assert(m_d->wrapperMapper.empty());
}
delete m_d;
}
diff --git a/sources/shiboken2/tests/libother/otherderived.h b/sources/shiboken2/tests/libother/otherderived.h
index dfb219e1d..72e1e2302 100644
--- a/sources/shiboken2/tests/libother/otherderived.h
+++ b/sources/shiboken2/tests/libother/otherderived.h
@@ -55,7 +55,7 @@ public:
// factory method
static Abstract* createObject();
- void hideFunction(HideType*) {}
+ void hideFunction(HideType*) override {}
protected:
inline const char* getClassName() { return className(); }