QmlDesigner: Close PopupDialog on QtDS inactive

Close a PopupDialog whenever the main application becomes inactive by
e.g. focusing another app. This prevents the PopupDialog being drawn
on top of that any other application.

Task-number: QDS-11870
Change-Id: I2d5dce4a7a54d43382010dedee3ba214a70d2eb8
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
This commit is contained in:
Henning Gruendl
2024-02-06 10:59:17 +01:00
committed by Henning Gründl
parent ba536a5e9a
commit 211ae49130

View File

@@ -286,8 +286,10 @@ QtObject {
enabled: root.visible
function onFocusWindowChanged(focusWindow) {
if (!focusWindow)
if (!focusWindow) {
root.close()
return
}
if (root.keepOpen)
return