aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--PySide/QtCore/typesystem_core.xml8
-rw-r--r--tests/QtCore/CMakeLists.txt1
-rw-r--r--tests/QtCore/bug_1031.py5
3 files changed, 13 insertions, 1 deletions
diff --git a/PySide/QtCore/typesystem_core.xml b/PySide/QtCore/typesystem_core.xml
index b07195555..8c843e2d9 100644
--- a/PySide/QtCore/typesystem_core.xml
+++ b/PySide/QtCore/typesystem_core.xml
@@ -3029,7 +3029,13 @@
<enum-type name="State"/>
</object-type>
- <object-type name="QAbstractState" since="4.6" />
+ <object-type name="QAbstractState" since="4.6">
+ <modify-function signature="machine() const">
+ <modify-argument index="this">
+ <parent index="return" action="add"/>
+ </modify-argument>
+ </modify-function>
+ </object-type>
<object-type name="QAbstractTransition" since="4.6">
<modify-function signature="QAbstractTransition(QState*)">
diff --git a/tests/QtCore/CMakeLists.txt b/tests/QtCore/CMakeLists.txt
index cdd260e0e..ca737063c 100644
--- a/tests/QtCore/CMakeLists.txt
+++ b/tests/QtCore/CMakeLists.txt
@@ -24,6 +24,7 @@ PYSIDE_TEST(bug_953.py)
PYSIDE_TEST(bug_987.py)
PYSIDE_TEST(bug_994.py)
PYSIDE_TEST(bug_1019.py)
+PYSIDE_TEST(bug_1031.py)
PYSIDE_TEST(blocking_signals_test.py)
PYSIDE_TEST(classinfo_test.py)
PYSIDE_TEST(child_event_test.py)
diff --git a/tests/QtCore/bug_1031.py b/tests/QtCore/bug_1031.py
new file mode 100644
index 000000000..b97452543
--- /dev/null
+++ b/tests/QtCore/bug_1031.py
@@ -0,0 +1,5 @@
+from PySide.QtCore import QStateMachine, QState
+
+mach = QStateMachine()
+state = QState(mach)
+print(state.machine())