From a1d13bfe47c5b2b7ca2c915dca0094c1f8448deb Mon Sep 17 00:00:00 2001 From: Cristian Maureira-Fredes Date: Mon, 7 May 2018 14:08:09 +0200 Subject: Add default parameter to Q*Applications When no arguments are passed, build an empty list and to start a QCoreApplication, QApplication and QGuiApplication. This is a small effort to include the idea of a default parameter from Python. Change-Id: Ieedc1e7ee17de996778aa2d0bddfb88c5ef208cf Reviewed-by: Friedemann Kleint --- sources/pyside2/PySide2/QtCore/typesystem_core_common.xml | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'sources/pyside2/PySide2/QtCore') diff --git a/sources/pyside2/PySide2/QtCore/typesystem_core_common.xml b/sources/pyside2/PySide2/QtCore/typesystem_core_common.xml index b0c4da4ee..f0b6b9640 100644 --- a/sources/pyside2/PySide2/QtCore/typesystem_core_common.xml +++ b/sources/pyside2/PySide2/QtCore/typesystem_core_common.xml @@ -3259,6 +3259,14 @@ QCoreApplicationConstructor(%PYSELF, args, &%0); + + + PyObject *empty = PyTuple_New(2); + if (!PyTuple_SetItem(empty, 0, PyList_New(0))) { + QCoreApplicationConstructor(%PYSELF, empty, &%0); + } + + -- cgit v1.2.3