aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside6/PySide6/QtCore/typesystem_core_common.xml
diff options
context:
space:
mode:
authorCristián Maureira-Fredes <Cristian.Maureira-Fredes@qt.io>2023-08-01 18:56:06 +0200
committerCristian Maureira-Fredes <cristian.maureira-fredes@qt.io>2023-08-02 08:01:11 +0000
commit6280d50601705798d4fd96595b8c54fba436918f (patch)
tree0c660c432d3637fd7cd9d6f3aa7e0983064138c0 /sources/pyside6/PySide6/QtCore/typesystem_core_common.xml
parent896320d7df65a1b4d57e8b65caf4342efdae53e1 (diff)
stubs: setParent should accept an Optional object
The current stubs specify the type of the required argument, for example: w = QWidget() help(w.setParent) reports: setParent(self, parent: PySide6.QtWidgets.QWidget) -> None which makes some IDEs to complain when passing None, behavior that it's accepted as well. This change adds an Optional to the parameter. Pick-to: 6.5 Fixes: PYSIDE-2235 Change-Id: I57b54f47aee6783b1b7027981b5d282798d57ad4 Reviewed-by: Christian Tismer <tismer@stackless.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'sources/pyside6/PySide6/QtCore/typesystem_core_common.xml')
-rw-r--r--sources/pyside6/PySide6/QtCore/typesystem_core_common.xml1
1 files changed, 1 insertions, 0 deletions
diff --git a/sources/pyside6/PySide6/QtCore/typesystem_core_common.xml b/sources/pyside6/PySide6/QtCore/typesystem_core_common.xml
index 0aeb2a23a..ac8b0752e 100644
--- a/sources/pyside6/PySide6/QtCore/typesystem_core_common.xml
+++ b/sources/pyside6/PySide6/QtCore/typesystem_core_common.xml
@@ -1689,6 +1689,7 @@
<modify-argument index="this">
<parent index="1" action="add"/>
</modify-argument>
+ <modify-argument index="1" pyi-type="Optional[PySide6.QtCore.QObject]"/>
</modify-function>
<modify-function signature="connect(const QObject*,const char*,const char*,Qt::ConnectionType)const">
<modify-argument index="4">