playlist bug: randomly repeating tracks

Daniel Jones danielcjones at gmail.com
Thu Aug 7 20:32:12 CEST 2008


What happens with changing tracks is:
1. User requests a track change
2. Playlist::Model::m_nextRowCandidate gets set to the requested row.
3. Engine is told the new track
4. When the engine changes tracks it calls the model back with
Model::engineNewTrackPlaying, which sets the active row in the model.

>
>            warning() << "engineNewTrackPlaying:: MISS";
>
>            foreach( Item* item, itemList() )
>            {
>                if( item->track() == track )
>                {
>                    setActiveItem( item );
>                    break;
>                }
>            }

This get's executed as a fallback if the track that m_nextRowCandidate
points to in not in fact the track that the engine just changed to. It
really should never happen, but I thought that would be better than
just an explosion.

Since it is happening, that means the engine isn't changing to the
correct track. The problem is in engine controller.

Undoubtably it was something I introduced when I rewrote all the track
changing stuff. I'll take look it in a second.

~Daniel


More information about the Amarok-devel mailing list