From 992d8c142ca2ff36f528df212e148c1184994f06 Mon Sep 17 00:00:00 2001 From: zhuzichu Date: Thu, 12 Oct 2023 18:25:08 +0800 Subject: [PATCH] update --- src/Qt6/imports/FluentUI/Controls/FluProgressBar.qml | 5 +++-- src/Qt6/imports/FluentUI/Controls/FluProgressRing.qml | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/Qt6/imports/FluentUI/Controls/FluProgressBar.qml b/src/Qt6/imports/FluentUI/Controls/FluProgressBar.qml index b8dd6207..5bdc80db 100644 --- a/src/Qt6/imports/FluentUI/Controls/FluProgressBar.qml +++ b/src/Qt6/imports/FluentUI/Controls/FluProgressBar.qml @@ -3,6 +3,7 @@ import QtQuick.Controls import FluentUI ProgressBar{ + property int duration: 888 property real strokeWidth: 6 property bool progressVisible: false property color color: FluTheme.dark ? FluTheme.primaryColor.lighter : FluTheme.primaryColor.dark @@ -17,7 +18,7 @@ ProgressBar{ if(!indeterminate){ animator_x.duration = 0 rect_progress.x = 0 - animator_x.duration = 888 + animator_x.duration = control.duration } } background: Rectangle { @@ -46,7 +47,7 @@ ProgressBar{ from: -rect_progress.width to:control.width+rect_progress.width loops: Animation.Infinite - duration: 888 + duration: control.duration } } } diff --git a/src/Qt6/imports/FluentUI/Controls/FluProgressRing.qml b/src/Qt6/imports/FluentUI/Controls/FluProgressRing.qml index b8b88f08..2e50c85a 100644 --- a/src/Qt6/imports/FluentUI/Controls/FluProgressRing.qml +++ b/src/Qt6/imports/FluentUI/Controls/FluProgressRing.qml @@ -4,6 +4,7 @@ import QtQuick.Shapes import FluentUI ProgressBar{ + property int duration: 888 property real strokeWidth: 6 property bool progressVisible: false property color color: FluTheme.dark ? FluTheme.primaryColor.lighter : FluTheme.primaryColor.dark @@ -23,7 +24,7 @@ ProgressBar{ if(!indeterminate){ animator_r.duration = 0 layout_item.rotation = 0 - animator_r.duration = 888 + animator_r.duration = control.duration } } QtObject{ @@ -48,7 +49,7 @@ ProgressBar{ from: 0 to:360 loops: Animation.Infinite - duration: 888 + duration: control.duration } Canvas { id:canvas