feat(slint): system media controls — MPRIS with GNOME app icon + SMTC/MediaRemote

New frontend-agnostic crate qbz-media-controls (ADR-006): one MediaIntegration
trait, cfg-split backends. Linux uses mpris-server and publishes the MPRIS
org.mpris.MediaPlayer2.DesktopEntry property as com.blitzfc.qbz — the only way
GNOME Shell resolves the app icon for its media widget (souvlaki, the old
cross-platform crate, never set it, so GNOME showed no icon; KDE is lenient).
macOS/Windows keep souvlaki (MediaRemote/SMTC), where the icon comes from the
app bundle, not a DesktopEntry. The Linux server runs on a dedicated thread
with its own tokio runtime; state arrives over an async channel.

Wired into qbz-slint via src/media_controls.rs: started on shell entry,
metadata/playback pushed from the playback paths (mirroring the tray), and
inbound control events (media keys, the desktop media widget, Now Playing)
dispatched to the player through the existing QConnect-aware helpers. Both
Linux and macOS compile clean.

cc
This commit is contained in:
vicrodh committed 2026-06-06 11:03:11 -06:00
1 parent 682e735dc2
commit 7a7e5f82c4
12 files changed
+893 -4

No files matched your search

+1
View File
@@ -43,6 +43,7 @@ serde_json = { workspace = true }
dirs = "5"
chrono = { workspace = true, features = ["unstable-locales"] }
qbz-app = { path = "../qbz-app" }
qbz-media-controls = { path = "../qbz-media-controls" }
qbz-audio = { path = "../qbz-audio" }
qbz-core = { path = "../qbz-core" }
qbz-player = { path = "../qbz-player" }