kdeconnect-kde/app/qml/volume.qml
Nicolas Fella 37ff0b5318 [app] Remove QML import versions
Those are not needed in Qt6 and only get in the way
2023-12-25 15:56:13 +00:00

55 lines
1.3 KiB
QML

/*
* SPDX-FileCopyrightText: 2018 Nicolas Fella <nicolas.fella@gmx.de>
*
* SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
*/
import QtQuick
import QtQuick.Controls
import QtQuick.Layouts
import org.kde.kirigami as Kirigami
import org.kde.kdeconnect
Kirigami.Page
{
id: root
title: i18nd("kdeconnect-app", "Volume control")
property QtObject pluginInterface
ListView {
id: sinkList
anchors.fill: parent
spacing: Kirigami.Units.largeSpacing
model: RemoteSinksModel {
deviceId: pluginInterface.deviceId
}
delegate: ColumnLayout {
width: parent.width
Label {
text: description
elide: Text.ElideRight
Layout.fillWidth: true
}
RowLayout {
Button {
icon.name: muted ? "player-volume-muted" : "player-volume"
onClicked: muted = !muted
}
Slider {
Layout.fillWidth: true
from: 0
value: volume
to: maxVolume
onMoved: volume = value
}
}
}
}
}