Exemplo n.º 1
0
        public void RefreshTrackList(bool ReSort)
        {
            TrackQueue queue = filterBar.GetTracks();

            if (NondynamicPlaylistBasedView || (filterBar.IsFilterActive(FilterType.Playlist) && Database.PlaylistIsPreSorted(controller.CurrentPlaylist)))
            {
                trackList.NoSort();
            }
            else if (ReSort && trackList.SortColumn < 0)
            {
                trackList.SortColumn = 0;
            }

            trackList.Queue = queue;

            controller.UpdateTrackOrStationCount();

            if (trackList.HasTracks)
            {
                if (!controller.Playing)
                {
                    artwork.CurrentTrack = trackList[0];
                }
            }
            else if (!controller.Playing)
            {
                artwork.CurrentTrack = null;
            }

            controller.Preload();
        }