diff options
author | Hugo Lima <hugo.lima@openbossa.org> | 2010-01-07 16:53:18 -0200 |
---|---|---|
committer | Hugo Lima <hugo.lima@openbossa.org> | 2010-01-07 18:46:53 -0200 |
commit | 55516cd9f79bdf608c27b755bbae2f8edf87d5c3 (patch) | |
tree | 6b55e602bf63bd73f43e8f97bb7e7e57cd215e22 /PySide/QtCore | |
parent | 42c7bd94516eae1042c404684cc468a88ad73317 (diff) |
If the QVariant is holding a QString, QVariant::toPyObject will return an QString.
Diffstat (limited to 'PySide/QtCore')
-rw-r--r-- | PySide/QtCore/typesystem_core.xml | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/PySide/QtCore/typesystem_core.xml b/PySide/QtCore/typesystem_core.xml index e8a1731b1..7e3049bd2 100644 --- a/PySide/QtCore/typesystem_core.xml +++ b/PySide/QtCore/typesystem_core.xml @@ -1550,6 +1550,8 @@ uint type_id = QMetaType::type(type_name); if (!type_id || type_id > QVariant::UserType) { %PYARG_0 = %CPPSELF.value<PyObjectHolder>(); + } else if (type_id == QVariant::String) { + %PYARG_0 = %CONVERTTOPYTHON[QString](%CPPSELF.toString()); } else { %PYARG_0 = Py_None; Py_INCREF(Py_None); |