Mpris CanPlay=true never gets signalled
VLC never sends the signal that CanPlay = true
on DBus, so MPRIS clients (e.g. KDE Connect) don't know that playing is allowed. This results on a broken UI after pausing, since the play button is disabled.
After a bit of debugging, I think this is what happens:
- VLC starts with an empty playlist (because it's populated asynchronoously?)
- VLC becomes available on DBus, gets queries, and correctly replies with
CanPlay = false
- The playlist becomes available, but
CanPlay = true
is never sent
After looking a bit at the VLC code, it seems CanPlay = true/false
gets signalled after playlist additions/deletions. Testing confirms that this works as intended: after deletion/addition/clearing CanPlay = true
is sent.
So I think the only thing missing is an playlist updated call when it's finished loading initially (but I can't find where to do that).