Fixes custom code for QtCore's HWND on win32.
This commit is contained in:
parent
31804c2adc
commit
ebeae9d084
3 changed files with 15 additions and 8 deletions
|
|
@ -43,6 +43,9 @@
|
||||||
</target-to-native>
|
</target-to-native>
|
||||||
</conversion-rule>
|
</conversion-rule>
|
||||||
</primitive-type>
|
</primitive-type>
|
||||||
|
<inject-code class="native" position="beginning">
|
||||||
|
<insert-template name="checkPyCapsuleOrPyCObject_func"/>
|
||||||
|
</inject-code>
|
||||||
<value-type name="POINT">
|
<value-type name="POINT">
|
||||||
<include file-name="wtypes.h" location="global"/>
|
<include file-name="wtypes.h" location="global"/>
|
||||||
</value-type>
|
</value-type>
|
||||||
|
|
|
||||||
|
|
@ -43,14 +43,7 @@
|
||||||
</conversion-rule>
|
</conversion-rule>
|
||||||
</primitive-type>
|
</primitive-type>
|
||||||
<inject-code class="native" position="beginning">
|
<inject-code class="native" position="beginning">
|
||||||
static bool checkPyCapsuleOrPyCObject(PyObject* pyObj)
|
<insert-template name="checkPyCapsuleOrPyCObject_func"/>
|
||||||
{
|
|
||||||
#ifdef IS_PY3K
|
|
||||||
return PyCapsule_CheckExact(pyObj);
|
|
||||||
#else
|
|
||||||
return PyCObject_Check(pyObj);
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
</inject-code>
|
</inject-code>
|
||||||
<enum-type name="QPixmap::HBitmapFormat" />
|
<enum-type name="QPixmap::HBitmapFormat" />
|
||||||
</typesystem>
|
</typesystem>
|
||||||
|
|
|
||||||
|
|
@ -414,4 +414,15 @@
|
||||||
}
|
}
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
<template name="checkPyCapsuleOrPyCObject_func">
|
||||||
|
static bool checkPyCapsuleOrPyCObject(PyObject* pyObj)
|
||||||
|
{
|
||||||
|
#ifdef IS_PY3K
|
||||||
|
return PyCapsule_CheckExact(pyObj);
|
||||||
|
#else
|
||||||
|
return PyCObject_Check(pyObj);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
</template>
|
||||||
|
|
||||||
</typesystem>
|
</typesystem>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue