Skip unplayable items when adding to playlist?
#1
Hi!

I'm working on a classical music streaming addon, and I've gotten it to work pretty well. There's just one thing; since XBMC doesn't support 'work titles' (as opposed to actual track titles, i. e. work title: 'Symphony no. 41', track title: 'II. Andante Cantabile') I add a non-playable listitem above the tracks and set the label to be the same as the title of the work.

Example:

[Folder]

Toccata and Fugue in D Minor [non-playable listitem]
- Toccata - 03:42 [playable]
- Fugue - 06:20 [playable]
Passacaglia and Fugue in C Minor [non-playable]
- Passacaglia - 08:19 [playable]
- Fugue - 06:12 [playable]
etc...

The playable listitems each have a parameter named 'mode' set to 'play' which then resolves to an actual link using setResolvedUrl.
The non-playable items have their 'mode'-parameter set to 'skip' which then really does nothing. Oh, and I also set the 'IsPlayable'-property to True/False respectively.

So, when playing a playable item it plays correctly, adds the rest of the items in the folder to the playlist so that it automatically moves on to the next track when the current one is finished. If the next track happens to be a non-playable item, it just skips over to the next one.

That's fine and works really well, so this isn't much of an issue, really. Still, I just wondered if there is a way to avoid adding the non-playable items at all?
Reply

Logout Mark Read Team Forum Stats Members Help
Skip unplayable items when adding to playlist?0