From 3c02985990a15d1e99b69d08ebff4f49eded3c0b Mon Sep 17 00:00:00 2001 From: Chris Josten Date: Tue, 2 Jan 2024 20:09:23 +0100 Subject: [PATCH] core/MPRIS: change track id to String For some reason, the track id was a QDbusObjectPath, but somehow that caused issues, so I'm breaking the spec and simply changing it to a string. Now SailfishOS does display the MPRIS controls on the lockscreen. --- core/src/platform/freedesktop/mediaplayer2player.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/platform/freedesktop/mediaplayer2player.cpp b/core/src/platform/freedesktop/mediaplayer2player.cpp index 13c28d2..f98d44c 100644 --- a/core/src/platform/freedesktop/mediaplayer2player.cpp +++ b/core/src/platform/freedesktop/mediaplayer2player.cpp @@ -108,7 +108,7 @@ QVariantMap PlayerAdaptor::metadata() const QSharedPointer item = plybkMgr->dataItem(); if (!item.isNull()) { - map[QStringLiteral("mpris:trackid")] = QVariant::fromValue(QDBusObjectPath(QStringLiteral("/nl/netsoj/chris/jellyfinqt/item/").append(item->jellyfinId()))); + map[QStringLiteral("mpris:trackid")] = QVariant::fromValue(QStringLiteral("/nl/netsoj/chris/jellyfinqt/item/").append(item->jellyfinId())); if (item->runTimeTicks().has_value()) { map[QStringLiteral("mpris:length")] = item->runTimeTicks().value() / 10; }