diff --git a/TODO.md b/TODO.md index 869a184b..736d505e 100644 --- a/TODO.md +++ b/TODO.md @@ -1,7 +1,6 @@ # TODO - mention color in local echo -- cpu usage ## Main goals for next version diff --git a/src/gui/Base/HButtonContent.qml b/src/gui/Base/HButtonContent.qml index 40f37f7b..cef5f7ca 100644 --- a/src/gui/Base/HButtonContent.qml +++ b/src/gui/Base/HButtonContent.qml @@ -25,7 +25,7 @@ HRowLayout { visible: button.icon.name || button.loading Layout.preferredWidth: - button.loading ? busyIndicator.width : icon.width + button.loading ? busyIndicatorLoader.width : icon.width Layout.fillHeight: true Layout.alignment: Qt.AlignCenter @@ -45,15 +45,18 @@ HRowLayout { Behavior on opacity { HNumberAnimation {} } } - HBusyIndicator { - id: busyIndicator + HLoader { + id: busyIndicatorLoader anchors.centerIn: parent width: height height: parent.height opacity: button.loading ? 1 : 0 - visible: opacity > 0 + active: opacity > 0 Behavior on opacity { HNumberAnimation {} } + + sourceComponent: HBusyIndicator { + } } }