diff options
-rw-r--r-- | PySide/QtCore/typesystem_core.xml | 10 | ||||
-rw-r--r-- | PySide/typesystem_templates.xml | 5 |
2 files changed, 14 insertions, 1 deletions
diff --git a/PySide/QtCore/typesystem_core.xml b/PySide/QtCore/typesystem_core.xml index 94710230a..100ae118c 100644 --- a/PySide/QtCore/typesystem_core.xml +++ b/PySide/QtCore/typesystem_core.xml @@ -2116,7 +2116,15 @@ <!-- <modify-function signature="readData(char *,qint64)" remove="all"/> --> <modify-function signature="readLine(char *,qint64)" remove="all"/> <modify-function signature="write(const char *,qint64)" remove="all"/> - <modify-function signature="getChar(char *)" remove="all" /> + <modify-function signature="getChar(char *)"> + <modify-argument index="1"> + <remove-argument /> + <remove-default-expression /> + </modify-argument> + <inject-code class="target" position="beginning"> + <insert-template name="fix_char*" /> + </inject-code> + </modify-function> </object-type> <object-type name="QCryptographicHash"> <modify-function signature="addData(const char*,int)" remove="all"/> diff --git a/PySide/typesystem_templates.xml b/PySide/typesystem_templates.xml index 7aafaa98a..b5b0f00cb 100644 --- a/PySide/typesystem_templates.xml +++ b/PySide/typesystem_templates.xml @@ -59,5 +59,10 @@ return %CONVERTTOPYTHON[QRectF](rect_); </template> + <template name="fix_char*"> + char val_; + %RETURN_TYPE retval_ = %CPPSELF.%FUNCTION_NAME(&val_); + %PYARG_0 = PyTuple_Pack(2, %CONVERTTOPYTHON[%RETURN_TYPE](retval_), %CONVERTTOPYTHON[char](val_)); + </template> </typesystem> |