diff options
author | Ulf Hermann <ulf.hermann@qt.io> | 2021-06-11 16:01:10 +0200 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@qt.io> | 2021-07-05 09:25:14 +0000 |
commit | 8012333a1f828d5e5530ee92e8883653964506b9 (patch) | |
tree | 5ff5bedd31d69d8084f43b94ff2ad9b0bccff83a | |
parent | 77b6089ef81cf562505e704798d1906c6139a004 (diff) |
Don't leak buttons in QQuickDialogButtonBox
Fixes: QTBUG-94455
Change-Id: I8d8c82f3b10e5e755ac11924c335ee07ab08d4a6
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
(cherry-picked from commit af4137ec20f0cd0e4f385cc5e7a7f2d0a87df6f7)
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
-rw-r--r-- | src/quicktemplates2/qquickdialogbuttonbox.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/quicktemplates2/qquickdialogbuttonbox.cpp b/src/quicktemplates2/qquickdialogbuttonbox.cpp index 447d3a2d..b6b9ed84 100644 --- a/src/quicktemplates2/qquickdialogbuttonbox.cpp +++ b/src/quicktemplates2/qquickdialogbuttonbox.cpp @@ -421,6 +421,7 @@ QQuickAbstractButton *QQuickDialogButtonBoxPrivate::createStandardButton(QPlatfo attached->setButtonRole(QPlatformDialogHelper::buttonRole(standardButton)); button->setText(buttonText(standardButton)); delegate->completeCreate(); + button->setParent(q); return button; } |