mirror of
https://github.com/zoriya/Opus.git
synced 2025-12-06 06:26:15 +00:00
Solving a bug with the queue management.
This commit is contained in:
@@ -213,9 +213,9 @@ namespace MusicApp.Resources.Portable_Class
|
||||
if (item.Album == null)
|
||||
{
|
||||
var songCover = Uri.Parse("content://media/external/audio/albumart");
|
||||
var nextAlbumArtUri = ContentUris.WithAppendedId(songCover, item.AlbumArt);
|
||||
var songAlbumArtUri = ContentUris.WithAppendedId(songCover, item.AlbumArt);
|
||||
|
||||
Picasso.With(MainActivity.instance).Load(nextAlbumArtUri).Placeholder(Resource.Drawable.noAlbum).Resize(400, 400).CenterCrop().Into(bottomView.FindViewById<ImageView>(Resource.Id.bsArt));
|
||||
Picasso.With(MainActivity.instance).Load(songAlbumArtUri).Placeholder(Resource.Drawable.noAlbum).Resize(400, 400).CenterCrop().Into(bottomView.FindViewById<ImageView>(Resource.Id.bsArt));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -226,9 +226,9 @@ namespace MusicApp.Resources.Portable_Class
|
||||
|
||||
public static void InsertToQueue(int position, Song item)
|
||||
{
|
||||
if (MusicPlayer.CurrentID() > position)
|
||||
if (MusicPlayer.CurrentID() >= position)
|
||||
{
|
||||
MusicPlayer.currentID--;
|
||||
MusicPlayer.currentID++;
|
||||
MusicPlayer.SaveQueueSlot();
|
||||
}
|
||||
|
||||
|
||||
@@ -339,7 +339,6 @@ namespace MusicApp.Resources.Portable_Class
|
||||
{
|
||||
Song song = songList[position];
|
||||
Queue.RemoveFromQueue(position);
|
||||
NotifyItemRemoved(position);
|
||||
Snackbar.Make(Queue.instance.FindViewById(Resource.Id.recycler), (song.Title.Length > 20 ? song.Title.Substring(0, 17) + "..." : song.Title) + " has been removed from the queue.", Snackbar.LengthShort)
|
||||
.SetAction("Undo", (view) =>
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user