aboutsummaryrefslogtreecommitdiffstats
path: root/PySide
diff options
context:
space:
mode:
authorHugo Parente Lima <hugo.pl@gmail.com>2011-03-23 13:31:35 -0300
committerHugo Parente Lima <hugo.pl@gmail.com>2012-03-08 16:54:05 -0300
commitdeefa3508703537c318d18e5da2df57ae19a70bd (patch)
treec73144080fa16143ebcd6d6d11c4d8d6e84353af /PySide
parent61f479b6826f7d88c02c0ab5986e8e2c08be5518 (diff)
Fix bug 694 - "QWebPage::extensions need injected overloads due to required casts on C++ version"
Diffstat (limited to 'PySide')
-rw-r--r--PySide/QtWebKit/typesystem_webkit.xml23
1 files changed, 23 insertions, 0 deletions
diff --git a/PySide/QtWebKit/typesystem_webkit.xml b/PySide/QtWebKit/typesystem_webkit.xml
index 1e632926b..eb645c25f 100644
--- a/PySide/QtWebKit/typesystem_webkit.xml
+++ b/PySide/QtWebKit/typesystem_webkit.xml
@@ -81,6 +81,29 @@
<value-type name="ExtensionOption" />
<value-type name="ExtensionReturn" />
+ <modify-function signature="extension(QWebPage::Extension, const QWebPage::ExtensionOption*, QWebPage::ExtensionReturn*)">
+ <modify-argument index="2" invalidate-after-use="yes">
+ <conversion-rule class="target">
+ PyObject* %out = 0;
+ // Cast the parameters according to the extension type
+ if (extension == QWebPage::ChooseMultipleFilesExtension)
+ %out = %CONVERTTOPYTHON[ChooseMultipleFilesExtensionOption*](reinterpret_cast&lt;const ChooseMultipleFilesExtensionOption*>(option));
+ else if (extension == QWebPage::ErrorPageExtension)
+ %out = %CONVERTTOPYTHON[ErrorPageExtensionOption*](reinterpret_cast&lt;const ErrorPageExtensionOption*>(option));
+ </conversion-rule>
+ </modify-argument>
+ <modify-argument index="3" invalidate-after-use="yes">
+ <conversion-rule class="target">
+ PyObject* %out = 0;
+ // Cast the parameters according to the extension type
+ if (extension == QWebPage::ChooseMultipleFilesExtension)
+ %out = %CONVERTTOPYTHON[ChooseMultipleFilesExtensionReturn*](reinterpret_cast&lt;const ChooseMultipleFilesExtensionReturn*>(output));
+ else if (extension == QWebPage::ErrorPageExtension)
+ %out = %CONVERTTOPYTHON[ErrorPageExtensionReturn*](reinterpret_cast&lt;const ErrorPageExtensionReturn*>(output));
+ </conversion-rule>
+ </modify-argument>
+ </modify-function>
+
<modify-function signature="setNetworkAccessManager(QNetworkAccessManager*)">
<modify-argument index="1">
<reference-count action="set"/>