From 79d57110031decd825f37f2c2b2a97c756250e37 Mon Sep 17 00:00:00 2001 From: Sander van Grieken Date: Fri, 14 Apr 2023 13:34:05 +0200 Subject: [PATCH] qml: InfoTextArea add Spinner to styles --- .../qml/components/controls/InfoTextArea.qml | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/electrum/gui/qml/components/controls/InfoTextArea.qml b/electrum/gui/qml/components/controls/InfoTextArea.qml index b8867eb77..dcdab8c4c 100644 --- a/electrum/gui/qml/components/controls/InfoTextArea.qml +++ b/electrum/gui/qml/components/controls/InfoTextArea.qml @@ -11,7 +11,8 @@ TextHighlightPane { Error, Progress, Pending, - Done + Done, + Spinner } property alias text: infotext.text @@ -24,7 +25,7 @@ TextHighlightPane { ? constants.colorWarning : iconStyle == InfoTextArea.IconStyle.Error ? constants.colorError - : iconStyle == InfoTextArea.IconStyle.Progress + : iconStyle == InfoTextArea.IconStyle.Progress || iconStyle == InfoTextArea.IconStyle.Spinner ? constants.colorProgress : iconStyle == InfoTextArea.IconStyle.Done ? constants.colorDone @@ -36,6 +37,9 @@ TextHighlightPane { spacing: constants.paddingLarge Image { + Layout.preferredWidth: constants.iconSizeMedium + Layout.preferredHeight: constants.iconSizeMedium + visible: iconStyle != InfoTextArea.IconStyle.Spinner source: iconStyle == InfoTextArea.IconStyle.Info ? "../../../icons/info.png" : iconStyle == InfoTextArea.IconStyle.Warn @@ -49,8 +53,19 @@ TextHighlightPane { : iconStyle == InfoTextArea.IconStyle.Done ? "../../../icons/confirmed.png" : "" + } + + Item { Layout.preferredWidth: constants.iconSizeMedium Layout.preferredHeight: constants.iconSizeMedium + visible: iconStyle == InfoTextArea.IconStyle.Spinner + + BusyIndicator { + anchors.centerIn: parent + scale: 0.66 + smooth: true + running: visible + } } Label {