2011-06-24, 17:48
carmenm Wrote:Wow great news!. Thanks a lot for that one!
I have a question about "Now Playing" in XBMC, what is the equivalent in JSON. I mean is it :
if (VideoPlayerAvailable) return VideoPlaylist.GetItems
else if (AudioPlayerAvailable) return AudioPlaylist.GetItems
Did i get it right?
Yeah you basically call Player.GetActivePlayers. From the response you get you can determine whether the video or the audio player is active. Based on that you call VideoPlaylist.GetItems or AudioPlaylist.GetItems and use the "current" attribute you get in the result to determine the index of the currently playing item in the list of items also returned by GetItems().