summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author2 * r + 2 * t <61896496+soramanew@users.noreply.github.com>2025-08-02 15:59:38 +1000
committer2 * r + 2 * t <61896496+soramanew@users.noreply.github.com>2025-08-02 15:59:38 +1000
commit5bddb40b3e7a31d16ce1bb7d8cd9ef68b95d47ef (patch)
tree6135843485c55c0b61a7383a8f49be6da13ef2c2
parentfunding: add buymeacoffee (diff)
downloadcaelestia-shell-5bddb40b3e7a31d16ce1bb7d8cd9ef68b95d47ef.tar.gz
caelestia-shell-5bddb40b3e7a31d16ce1bb7d8cd9ef68b95d47ef.tar.bz2
caelestia-shell-5bddb40b3e7a31d16ce1bb7d8cd9ef68b95d47ef.zip
dashboard: fix player selector icons
-rw-r--r--modules/dashboard/Media.qml13
1 files changed, 7 insertions, 6 deletions
diff --git a/modules/dashboard/Media.qml b/modules/dashboard/Media.qml
index 913a5c4..be31236 100644
--- a/modules/dashboard/Media.qml
+++ b/modules/dashboard/Media.qml
@@ -395,7 +395,7 @@ Item {
spacing: Appearance.spacing.small
PlayerIcon {
- identity: Players.active?.identity ?? ""
+ player: Players.active
}
StyledText {
@@ -451,6 +451,7 @@ Item {
required property MprisPlayer modelData
Layout.fillWidth: true
+ Layout.minimumWidth: playerSelector.implicitWidth
implicitWidth: playerInner.implicitWidth + Appearance.padding.normal * 2
implicitHeight: playerInner.implicitHeight + Appearance.padding.smaller * 2
@@ -470,7 +471,7 @@ Item {
spacing: Appearance.spacing.small
PlayerIcon {
- identity: player.modelData.identity
+ player: player.modelData
}
StyledText {
@@ -546,12 +547,12 @@ Item {
component PlayerIcon: Loader {
id: loader
- required property string identity
- readonly property string icon: Icons.getAppIcon(identity)
+ required property MprisPlayer player
+ readonly property string icon: Icons.getAppIcon(player?.identity)
Layout.fillHeight: true
asynchronous: true
- sourceComponent: icon === "image://icon/" ? fallbackIcon : playerImage
+ sourceComponent: !player || icon === "image://icon/" ? fallbackIcon : playerImage
Component {
id: playerImage
@@ -566,7 +567,7 @@ Item {
id: fallbackIcon
MaterialIcon {
- text: loader.identity ? "animated_images" : "music_off"
+ text: loader.player ? "animated_images" : "music_off"
}
}
}