fixup pw fr
This commit is contained in:
parent
1d023f02a2
commit
d9be154465
2 changed files with 11 additions and 8 deletions
|
|
@ -8,7 +8,6 @@ import qs.modules.Services
|
|||
import QtQuick.Layouts
|
||||
import QtQuick.Controls
|
||||
|
||||
|
||||
PopupWindow {
|
||||
implicitWidth: audioLayout.implicitWidth + 2 * audioLayout.anchors.margins
|
||||
implicitHeight: audioLayout.implicitHeight + 24
|
||||
|
|
@ -28,17 +27,17 @@ PopupWindow {
|
|||
anchors.margins: 10
|
||||
spacing: 8
|
||||
Repeater {
|
||||
id: audioRep
|
||||
id: audioRep
|
||||
model: Audio.sinks
|
||||
|
||||
|
||||
delegate: Rectangle {
|
||||
Layout.fillWidth: true
|
||||
id: audioDelContainer
|
||||
Layout.fillWidth: true
|
||||
color: Colors.moduleBg
|
||||
radius: Config.cfg.appearance.rounding
|
||||
required property var modelData
|
||||
implicitHeight: audioRow.implicitHeight + 8
|
||||
implicitWidth: audioRow.implicitWidth
|
||||
implicitWidth: audioRow.implicitWidth
|
||||
|
||||
RowLayout {
|
||||
id: audioRow
|
||||
|
|
@ -50,11 +49,11 @@ PopupWindow {
|
|||
text: audioDelContainer.modelData.nickname
|
||||
Layout.leftMargin: 10
|
||||
Layout.fillWidth: true
|
||||
Layout.maximumWidth: 200
|
||||
Layout.maximumWidth: 200
|
||||
elide: Text.ElideRight
|
||||
}
|
||||
StyledIcon {
|
||||
Layout.leftMargin: 10
|
||||
Layout.leftMargin: 10
|
||||
iconName: Audio.getVolumeIcon(audioDelContainer.modelData)
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
|
|
@ -66,7 +65,10 @@ PopupWindow {
|
|||
}
|
||||
}
|
||||
StyledIcon {
|
||||
iconName: audioDelContainer.modelData === Audio.preferredAudio ? "radio-checked-symbolic" : "radio-symbolic"
|
||||
readonly property bool isDefault: audioDelContainer.modelData === Audio.defaultAudio
|
||||
readonly property bool isPreferred: audioDelContainer.modelData === Audio.preferredAudio
|
||||
iconName: isDefault ? "radio-checked-symbolic" : "radio-symbolic"
|
||||
opacity: (isPreferred && !isDefault) ? 0.5 : 1.0
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
|
|
|
|||
Loading…
Reference in a new issue