From e0254f2f8088f9061a112044b5221147d5adf1f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=B1=E5=AD=90=E6=A5=9A=5Czhuzi?= Date: Sat, 23 Mar 2024 22:28:14 +0800 Subject: [PATCH] fix bug --- src/Qt5/imports/FluentUI/Controls/FluWindowDialog.qml | 2 +- src/Qt6/imports/FluentUI/Controls/FluWindowDialog.qml | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Qt5/imports/FluentUI/Controls/FluWindowDialog.qml b/src/Qt5/imports/FluentUI/Controls/FluWindowDialog.qml index 41137736..5ff94931 100644 --- a/src/Qt5/imports/FluentUI/Controls/FluWindowDialog.qml +++ b/src/Qt5/imports/FluentUI/Controls/FluWindowDialog.qml @@ -37,6 +37,6 @@ FluWindow { var y = transientParent.y + (transientParent.height - height)/2 control.stayTop = Qt.binding(function(){return transientParent.stayTop}) control.setGeometry(x,y,width,height) - control.visible = true + control.visibility = Window.Windowed } } diff --git a/src/Qt6/imports/FluentUI/Controls/FluWindowDialog.qml b/src/Qt6/imports/FluentUI/Controls/FluWindowDialog.qml index d62f707c..bd7d0904 100644 --- a/src/Qt6/imports/FluentUI/Controls/FluWindowDialog.qml +++ b/src/Qt6/imports/FluentUI/Controls/FluWindowDialog.qml @@ -26,9 +26,9 @@ FluWindow { } Connections{ target: control.transientParent - function onVisibleChanged(){ - if(control.transientParent.visible === false){ - control.visible = false + function onVisibilityChanged(){ + if(control.transientParent.visibility === Window.Hidden){ + control.visibility = Window.Hidden } } } @@ -37,6 +37,6 @@ FluWindow { var y = transientParent.y + (transientParent.height - height)/2 control.stayTop = Qt.binding(function(){return transientParent.stayTop}) control.setGeometry(x,y,width,height) - control.visible = true + control.visibility = Window.Windowed } }