From 531bffdf1a3bf60ab13b983f9f565204f457bbf5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=B1=E5=AD=90=E6=A5=9A=5Czhuzi?= Date: Wed, 6 Sep 2023 23:17:33 +0800 Subject: [PATCH] update --- .../FluentUI/Controls/FluProgressButton.qml | 2 +- .../imports/FluentUI/Controls/FluWindow.qml | 33 ++++++++++++++++--- .../FluentUI/Controls/FluProgressButton.qml | 2 +- .../imports/FluentUI/Controls/FluWindow.qml | 33 ++++++++++++++++--- 4 files changed, 58 insertions(+), 12 deletions(-) diff --git a/src/Qt5/imports/FluentUI/Controls/FluProgressButton.qml b/src/Qt5/imports/FluentUI/Controls/FluProgressButton.qml index 2ace3bcb..2ef5fae4 100644 --- a/src/Qt5/imports/FluentUI/Controls/FluProgressButton.qml +++ b/src/Qt5/imports/FluentUI/Controls/FluProgressButton.qml @@ -8,7 +8,7 @@ Button { property string contentDescription: "" QtObject{ id:d - property bool checked: rect_back.height === background.height + property bool checked: rect_back.height == background.height } property color normalColor: { if(d.checked){ diff --git a/src/Qt5/imports/FluentUI/Controls/FluWindow.qml b/src/Qt5/imports/FluentUI/Controls/FluWindow.qml index 13c6b96d..35b54ea2 100644 --- a/src/Qt5/imports/FluentUI/Controls/FluWindow.qml +++ b/src/Qt5/imports/FluentUI/Controls/FluWindow.qml @@ -69,6 +69,8 @@ Window { id:popup_loading modal:true focus: true + width: window.width + height: window.height anchors.centerIn: Overlay.overlay closePolicy: { if(cancel){ @@ -76,17 +78,38 @@ Window { } return Popup.NoAutoClose } - Overlay.modal: Rectangle { - color: "#44000000" - } + Overlay.modal: Item {} onVisibleChanged: { if(!visible){ loader_loading.sourceComponent = undefined } } - visible: true - background: Item{} + padding: 0 + opacity: 0 + visible:true + Behavior on opacity { + SequentialAnimation { + PauseAnimation { + duration: 88 + } + NumberAnimation{ + duration: 167 + } + } + } + Component.onCompleted: { + opacity = 1 + } + background: Rectangle{ + color:"#44000000" + } contentItem: Item{ + MouseArea{ + anchors.fill: parent + onClicked: { + popup_loading.visible = false + } + } ColumnLayout{ spacing: 8 anchors.centerIn: parent diff --git a/src/Qt6/imports/FluentUI/Controls/FluProgressButton.qml b/src/Qt6/imports/FluentUI/Controls/FluProgressButton.qml index ee13ecba..cf4d5027 100644 --- a/src/Qt6/imports/FluentUI/Controls/FluProgressButton.qml +++ b/src/Qt6/imports/FluentUI/Controls/FluProgressButton.qml @@ -9,7 +9,7 @@ Button { property string contentDescription: "" QtObject{ id:d - property bool checked: rect_back.height === background.height + property bool checked: rect_back.height == background.height } property color normalColor: { if(d.checked){ diff --git a/src/Qt6/imports/FluentUI/Controls/FluWindow.qml b/src/Qt6/imports/FluentUI/Controls/FluWindow.qml index 7ab56f92..fe1d2bb9 100644 --- a/src/Qt6/imports/FluentUI/Controls/FluWindow.qml +++ b/src/Qt6/imports/FluentUI/Controls/FluWindow.qml @@ -68,6 +68,8 @@ Window { id:popup_loading modal:true focus: true + width: window.width + height: window.height anchors.centerIn: Overlay.overlay closePolicy: { if(cancel){ @@ -75,17 +77,38 @@ Window { } return Popup.NoAutoClose } - Overlay.modal: Rectangle { - color: "#44000000" - } + Overlay.modal: Item {} onVisibleChanged: { if(!visible){ loader_loading.sourceComponent = undefined } } - visible: true - background: Item{} + padding: 0 + opacity: 0 + visible:true + Behavior on opacity { + SequentialAnimation { + PauseAnimation { + duration: 88 + } + NumberAnimation{ + duration: 167 + } + } + } + Component.onCompleted: { + opacity = 1 + } + background: Rectangle{ + color:"#44000000" + } contentItem: Item{ + MouseArea{ + anchors.fill: parent + onClicked: { + popup_loading.visible = false + } + } ColumnLayout{ spacing: 8 anchors.centerIn: parent