Media Player interface (was org.gnome.Application)



On Thu, 2007-08-16 at 12:37 -0500, Scott J. Harmon wrote:
> Alex Jones wrote:
> > On Thu, 2007-08-16 at 19:00 +0200, Nicolas Trangez wrote:
> >> On Thu, 2007-08-16 at 18:05 +0100, Alex Jones wrote:
> >>> media_player_proxy = dbus_g_proxy_new_for_name (connection,
> >>> 	"org.gnome.Rhythmbox",
> >>>         "/org/gnome/Rhythmbox,
> >>> 	"org.gnome.MediaPlayer"); // Any random interface here
> >>>
> >>> error = NULL;
> >>> dbus_g_proxy_call (proxy, "Pause", &error, G_TYPE_INVALID, G_TYPE_INVALID);
> >> Remains the issue: "I want to pause the currently playing music player.
> >> Now I wonder what it's object path is."
> >> You can hardly keep a list of all known object paths (RB, Totem,
> >> Banshee, whatever) in your application-which-wants-to-pause-the-player.
> >>
> >> Nicolas
> > 
> > We are getting hideously off topic, but this is something that can be
> > stored in GConf as a "preferred media player" key:
> > 
> > service_name = "org.gnome.Rhythmbox"
> > object_path = "/org/gnome/Rhythmbox"
> > 
> > Sorted.
> 
> Preferred is not the same as currently playing.
> 
> Scott.

"Currently playing" is too fuzzy. You could have three players
"currently playing". I'm sure there's no significant use case for your
media keys to be controlling all three at once.

For general desktop co-ordination, signals are your friend. Media
players should be listening for actions to respond to, not being
explicitly told to "pause" or "mute".




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]