This commit is contained in:
Ly-sec 2025-08-26 13:12:01 +02:00
parent 1533b2d3a1
commit 3c39ea192b
4 changed files with 10 additions and 10 deletions

View file

@ -12,7 +12,8 @@ Singleton {
property var currentPlayer: null
property real currentPosition: 0
property int selectedPlayerIndex: 0
property bool isPlaying: currentPlayer ? (currentPlayer.playbackState === MprisPlaybackState.Playing || currentPlayer.isPlaying) : false
property bool isPlaying: currentPlayer ? (currentPlayer.playbackState === MprisPlaybackState.Playing
|| currentPlayer.isPlaying) : false
property string trackTitle: currentPlayer ? (currentPlayer.trackTitle || "") : ""
property string trackArtist: currentPlayer ? (currentPlayer.trackArtist || "") : ""
property string trackAlbum: currentPlayer ? (currentPlayer.trackAlbum || "") : ""
@ -38,7 +39,8 @@ Singleton {
let controllablePlayers = []
// Apply blacklist and controllable filter
const blacklist = (Settings.data.audio && Settings.data.audio.mprisBlacklist) ? Settings.data.audio.mprisBlacklist : []
const blacklist = (Settings.data.audio
&& Settings.data.audio.mprisBlacklist) ? Settings.data.audio.mprisBlacklist : []
for (var i = 0; i < allPlayers.length; i++) {
let player = allPlayers[i]
if (!player)
@ -49,7 +51,8 @@ Singleton {
const idKey = identity.toLowerCase()
const match = blacklist.find(b => {
const s = String(b || "").toLowerCase()
return s && (idKey.includes(s) || busName.toLowerCase().includes(s) || desktop.toLowerCase().includes(s))
return s && (idKey.includes(s) || busName.toLowerCase().includes(s)
|| desktop.toLowerCase().includes(s))
})
if (match)
continue

View file

@ -28,9 +28,6 @@ Rectangle {
signal exited
signal clicked
implicitWidth: size
implicitHeight: size