Beispiel #1
0
        private void LoadAlbum(BufferItem item)
        {
            AlbumBufferItem abi = item as AlbumBufferItem;

            _output.OutputMessage(StringStore.LoadingAlbum, false);
            buffers.Add(new AlbumBufferList(abi.Model.Name));
            buffers.CurrentListIndex = buffers.Count - 1;
            var albumBuffer = buffers.CurrentList;

            _output.OutputMessage(albumBuffer.ToString(), false);
            var tracks = SpotifyController.GetAlbumTracks(abi.Model.AlbumPtr).ToList();

            _output.OutputMessage(String.Format("{0} {1}", tracks.Count, StringStore.TracksLoaded), false);
            tracks.ForEach(t =>
            {
                albumBuffer.Add(new TrackBufferItem(new Track(t)));
            });
        }