Hi yawfle,
Post by yawfleThe resume feature is nice, but I think it's usefullness could be
enhanced if the resume information also included playlist position, if
that's the mode that cmus was in at quit. As it is now, when cmus
starts up in the playlist view/mode and resumes playing the file,
there's no indication of the current track in the playlist, and after
playing the file, the playlist is started playing from the beginning.
Any chance this functionality could be added?
I've just now written a "working-but-too-ugly-to-send" patch that
implements this functionality. The problem is that the resume
information is loaded before the library/playlist is read, which is a
good thing, because loading those could take minutes. The problem is,
cmus can't jump to a specific row if no row is there (because no tracks
have been loaded yet).
So my patch assumes loading is very fast and tries to jump to the
correct row after 1/4 second, which works if the library/playlist is
small and cached. The correct approach would maybe be something like a
hook (callback) in the playlist/library loading, but this is more
complicated, so I have to postpone it to later.
It would be cool if you would add it to the roadmap [1] so we don't
forget about it! Also, I've attached the (non-fit for inclusion) patch.
Johannes
[1] http://cmus.sourceforge.net/wiki/doku.php?id=todo