aboutsummaryrefslogtreecommitdiffstats
path: root/PySide/QtCore
diff options
context:
space:
mode:
authorHugo Lima <hugo.lima@openbossa.org>2010-01-07 16:53:18 -0200
committerHugo Lima <hugo.lima@openbossa.org>2010-01-07 18:46:53 -0200
commit55516cd9f79bdf608c27b755bbae2f8edf87d5c3 (patch)
tree6b55e602bf63bd73f43e8f97bb7e7e57cd215e22 /PySide/QtCore
parent42c7bd94516eae1042c404684cc468a88ad73317 (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.xml2
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&lt;PyObjectHolder>();
+ } else if (type_id == QVariant::String) {
+ %PYARG_0 = %CONVERTTOPYTHON[QString](%CPPSELF.toString());
} else {
%PYARG_0 = Py_None;
Py_INCREF(Py_None);