add tracklist sorting logic

This commit is contained in:
Drew Weymouth
2023-05-23 11:10:43 -07:00
parent e434b55dda
commit 1f3559de43
7 changed files with 162 additions and 79 deletions
+1 -1
View File
@@ -107,7 +107,7 @@ func (a *NowPlayingPage) onRemoveSelectedFromQueue() {
// does not make calls to server - can safely be run in UI callbacks
func (a *NowPlayingPage) load(highlightedTrackID string) {
queue := a.pm.GetPlayQueue()
a.tracklist.Tracks = queue
a.tracklist.SetTracks(queue)
a.tracklist.SetNowPlaying(a.nowPlayingID)
if highlightedTrackID != "" {
a.tracklist.SelectAndScrollToTrack(highlightedTrackID)