virtual void playlist_manager::playlist_set_focus_item (t_size p_playlist, t_size p_item) [pure virtual]
Sets index of focus item on specified playlist; use infinite to set no focus item.
I have a question concerning this command. I what to set no focus (remove existing focus), so i should use "infinite".
How do i do this? (pfc::infinite_size doesn't work)
Have you given proper p_playlist?
From the documentation I would that you should specify p_playlist but leave p_item as infinite.
Thanks for answer.
p_playlist is not the problem, i use: (following command has no comment)
void playlist_manager::activeplaylist_set_focus_item(t_size p_item)
leave p_item as infinite.
I don't understand. Is pfc::infinite_size correct for p_item?
give please a code example.
What should i insert to unfocus the active playlist?
Well I haven't tried these but here goes...
Does this work as expected?
static_api_ptr_t<playlist_manager> api;
api->activeplaylist_set_focus_item(pfc::infinite_size);
Or this (clears the
selection)?
static_api_ptr_t<playlist_manager> api;
t_size playlist = api->get_active_playlist();
if(playlist != pfc::infinite_size) api->playlist_clear_selection(playlist);
both do not work
virtual void playlist_manager::playlist_set_focus_item (t_size p_playlist, t_size p_item) [pure virtual]
Sets index of focus item on specified playlist; use infinite to set no focus item.
"set no focus item" probably
not mean: remove existing focus/selection.
What exactly are you trying to do? Note that you cannot remove the keyboard focus from a playlist view using the playlist_manager service.
I want to make an option to repeat a playlist or jump to first track of next playlist at playlistend.
Never heard from difference between Keyboard Focus and Item Focus before.
Any way to remove Keyboard Focus?
It may be easier to manipulate the playback queue. As in, when playback reaches the last item in the current playlist, add the first track of the next playlist to the playback queue.
Never heard from difference between Keyboard Focus and Item Focus before.
Actually I was just guessing what you might be doing. The focused item in a playlist is indeed independent of the keyboard focus in the sense that even inactive playlists can have a focused item.
It's probably related to my request made here (http://www.hydrogenaudio.org/forums/index.php?s=&showtopic=83748&view=findpost&p=754552)? Using the queue might not be a bad solution, as long as it is able to be overwritten by manual queue content (ie. even if the last song of the playlist ends, if you queued something else, that will play rather than the first song of the next playlist).
Maybe foo_scheduler (http://www.hydrogenaudio.org/forums/index.php?showtopic=49589)/andrew_smolko can shed light on this though? It has a feature that skips to next playlist and starts playback at 1 (or any other number you want).