diff options
author | Qt Forward Merge Bot <qt_forward_merge_bot@qt-project.org> | 2019-11-09 03:07:01 +0100 |
---|---|---|
committer | Qt Forward Merge Bot <qt_forward_merge_bot@qt-project.org> | 2019-11-09 03:07:01 +0100 |
commit | cb182fb50e49fa88f7bf33f2407447167fd8048f (patch) | |
tree | 3e8cc6319ee9b2c4d20f7e0bcb784928f916146e /src/quicktemplates2/qquickpopup.cpp | |
parent | 611422b5968ceac6cfba034116a3d1e107d8e2df (diff) | |
parent | 9c05807b951167bc0c8385811c9df1bd9d48ca6d (diff) |
Merge remote-tracking branch 'origin/5.14' into 5.15
Change-Id: Ib14b8c77cefe7aaf5b11483d9a30b2ef05314598
Diffstat (limited to 'src/quicktemplates2/qquickpopup.cpp')
-rw-r--r-- | src/quicktemplates2/qquickpopup.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/quicktemplates2/qquickpopup.cpp b/src/quicktemplates2/qquickpopup.cpp index b798c82c..d83bb8aa 100644 --- a/src/quicktemplates2/qquickpopup.cpp +++ b/src/quicktemplates2/qquickpopup.cpp @@ -2411,6 +2411,13 @@ void QQuickPopup::componentComplete() d->complete = true; d->popupItem->componentComplete(); + + if (isVisible()) { + if (d->closePolicy & QQuickPopup::CloseOnEscape) + d->popupItem->grabShortcut(); + else + d->popupItem->ungrabShortcut(); + } } bool QQuickPopup::isComponentComplete() const |