aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRenato Filho <renato.filho@openbossa.org>2010-08-03 11:45:53 -0300
committerRenato Filho <renato.filho@openbossa.org>2010-08-03 14:06:31 -0300
commitee9e1f6155db49bbb46ecf6a4d264b5658a05e4a (patch)
treef57cf0c908795f50c9f8aae1f6807b0d6c909dc1
parent5ce8d05a089d0409b474be03eab1c7c4d5cfabb6 (diff)
Added support to shortcut named arg on QAction constructor.ps-0.4.0
Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
-rw-r--r--PySide/QtGui/typesystem_gui_common.xml17
1 files changed, 14 insertions, 3 deletions
diff --git a/PySide/QtGui/typesystem_gui_common.xml b/PySide/QtGui/typesystem_gui_common.xml
index 64849ae64..e0341e016 100644
--- a/PySide/QtGui/typesystem_gui_common.xml
+++ b/PySide/QtGui/typesystem_gui_common.xml
@@ -4251,22 +4251,33 @@
<parent index="this" action="add"/>
</modify-argument>
</modify-function>
- <add-function signature="QAction(const QString&amp;, QObject*, PyObject*)">
+ <add-function signature="QAction(const QString&amp;, QObject*, const QKeySequence&amp;, PyObject*)">
+
+ <!-- NOT use this for now Fix bug #???
<modify-argument index="2">
<replace-default-expression with="0"/>
<rename to="parent"/>
</modify-argument>
+ -->
+
<modify-argument index="3">
+ <replace-default-expression with="QKeySequence()"/>
+ <rename to="shortcut"/>
+ </modify-argument>
+
+ <modify-argument index="4">
<replace-default-expression with="0"/>
<rename to="triggered"/>
</modify-argument>
+
<inject-code class="target" position="beginning">
%0 = new QActionWrapper(%1, %2);
+ %0->setShortcut(%3);
</inject-code>
<inject-code class="target" position="end">
- if (%PYARG_3 != Py_None)
- Shiboken::AutoDecRef result(PyObject_CallMethod(%PYSELF, "connect", "OsO", %PYSELF, SIGNAL(triggered(bool)), %PYARG_3));
+ if (%PYARG_4 != Py_None)
+ Shiboken::AutoDecRef result(PyObject_CallMethod(%PYSELF, "connect", "OsO", %PYSELF, SIGNAL(triggered(bool)), %PYARG_4));
</inject-code>
</add-function>
</object-type>