[Gambas-user] mpris MediaPlayer2 interface

Benoit Minisini benoit.minisini at gambas-basic.org
Sat Feb 25 01:26:03 CET 2023


Le 04/02/2023 à 16:15, Bruce Steers a écrit :
> 
> I have attached a project that has a MediaView that adds mpris DBus but 
> it seems to be , er , a bit off.
> The form has a button that tries this..
>    Print 
> DBus["org.mpris.MediaPlayer2.gplayer"]["/org/mpris/MediaPlayer2", 
> "org.mpris.MediaPlayer2"].CanQuit
> But it hangs if pressed.
> 

Of course: you are waiting for the DBus answer, but that answer is given 
by the same program. It's a deadlock.

Just read the CanQuit property from another process, it will work.

Regards,

-- 
Benoît Minisini.



More information about the User mailing list