Page MenuHomePhorge

No OneTemporary

Authored By
Unknown
Size
1 KB
Referenced Files
None
Subscribers
None
diff --git a/src/contents/ui/ProgressBar.qml b/src/contents/ui/ProgressBar.qml
index 7ca374d..497bc04 100644
--- a/src/contents/ui/ProgressBar.qml
+++ b/src/contents/ui/ProgressBar.qml
@@ -1,45 +1,52 @@
/*
* This file is part of kazv.
* SPDX-FileCopyrightText: 2020 Tusooa Zhu <tusooa@kazv.moe>
* SPDX-License-Identifier: AGPL-3.0-or-later
*/
import QtQuick.Controls 2.15
import QtQuick.Layouts 1.15
+import org.kde.kirigami 2.13 as Kirigami
+
import moe.kazv.mxc.kazv 0.0 as MK
RowLayout {
id: progressBarLayout
property var kazvIO
visible: false
Layout.preferredWidth: image.width
ProgressBar {
id: progressBar
Layout.fillWidth: true
value: kazvIO.progress
}
- RoundButton {
- /* In the best case this should be an icon */
- text: l10n.get('button-download-suspend')
+ Kirigami.Action {
+ id: pauseAction
+ iconName: "media-playback-pause"
property var suspended: false
- onClicked: {
+ onTriggered: {
if (suspended) {
kazvIO.resume()
- console.log("resume")
} else {
kazvIO.suspend()
suspended = true
- console.log("suspend")
}
}
}
- RoundButton {
- /* In the best case this should be an icon */
- text: l10n.get('button-download-cancel')
- onClicked: {
+ Kirigami.Action {
+ id: cancelAction
+ iconName: "dialog-cancel"
+ onTriggered: {
kazvIO.cancel()
- console.log("cancel")
}
}
+ RoundButton {
+ icon.name: "media-playback-pause"
+ onClicked: pauseAction.trigger()
+ }
+ RoundButton {
+ icon.name: "dialog-cancel"
+ onClicked: cancelAction.trigger()
+ }
}

File Metadata

Mime Type
text/x-diff
Expires
Mon, Nov 2, 8:11 AM (9 h, 54 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1803727
Default Alt Text
(1 KB)

Event Timeline