mirror of
https://github.com/zoriya/Opus.git
synced 2025-12-06 06:26:15 +00:00
Finishing the current item decoration for the queue.
This commit is contained in:
@@ -336,6 +336,7 @@
|
||||
<Compile Include="Resources\Portable Class\ChannelAdapter.cs" />
|
||||
<Compile Include="Resources\Portable Class\ChannelPreviewHolder.cs" />
|
||||
<Compile Include="Resources\Portable Class\CircleTransformation.cs" />
|
||||
<Compile Include="Resources\Portable Class\CurrentItemDecoration.cs" />
|
||||
<Compile Include="Resources\Portable Class\DownloadQueue.cs" />
|
||||
<Compile Include="Resources\Portable Class\DownloadQueueAdapter.cs" />
|
||||
<Compile Include="Resources\Portable Class\FixedLinearLayoutManager.cs" />
|
||||
@@ -867,6 +868,12 @@
|
||||
<ItemGroup>
|
||||
<AndroidResource Include="Resources\drawable\darkLinear.xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<AndroidResource Include="Resources\layout\QueueCurrent.xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<AndroidResource Include="Resources\layout\Empty.xml" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildExtensionsPath)\Xamarin\Android\Xamarin.Android.CSharp.targets" />
|
||||
<Import Project="..\packages\Xamarin.Android.Support.Animated.Vector.Drawable.25.4.0.2\build\MonoAndroid70\Xamarin.Android.Support.Animated.Vector.Drawable.targets" Condition="Exists('..\packages\Xamarin.Android.Support.Animated.Vector.Drawable.25.4.0.2\build\MonoAndroid70\Xamarin.Android.Support.Animated.Vector.Drawable.targets')" />
|
||||
<Import Project="..\packages\Xamarin.Android.Support.v7.Preference.25.4.0.2\build\MonoAndroid70\Xamarin.Android.Support.v7.Preference.targets" Condition="Exists('..\packages\Xamarin.Android.Support.v7.Preference.25.4.0.2\build\MonoAndroid70\Xamarin.Android.Support.v7.Preference.targets')" />
|
||||
|
||||
@@ -15,7 +15,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
public override void ItemsReloaded()
|
||||
{
|
||||
base.ItemsReloaded();
|
||||
Queue.instance?.adapter.NotifyDataSetChanged();
|
||||
Queue.instance?.Refresh();
|
||||
Home.instance?.QueueAdapter?.NotifyDataSetChanged();
|
||||
Player.instance?.RefreshPlayer();
|
||||
}
|
||||
@@ -25,7 +25,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
base.ItemsRemovedAtIndexes(indexes);
|
||||
foreach(int index in indexes)
|
||||
{
|
||||
Queue.instance?.adapter.NotifyItemRemoved(index);
|
||||
Queue.instance?.NotifyItemRemoved(index);
|
||||
Home.instance?.QueueAdapter?.NotifyItemRemoved(index);
|
||||
|
||||
if (index == MusicPlayer.CurrentID())
|
||||
@@ -56,7 +56,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
|
||||
if(song != null)
|
||||
{
|
||||
Queue.instance?.adapter.NotifyItemChanged(index, song.Title);
|
||||
Queue.instance?.NotifyItemChanged(index, song.Title);
|
||||
Home.instance?.QueueAdapter?.NotifyItemChanged(index, song.Title);
|
||||
|
||||
if (index == MusicPlayer.CurrentID())
|
||||
|
||||
124
MusicApp/Resources/Portable Class/CurrentItemDecoration.cs
Normal file
124
MusicApp/Resources/Portable Class/CurrentItemDecoration.cs
Normal file
@@ -0,0 +1,124 @@
|
||||
using Android.App;
|
||||
using Android.Content;
|
||||
using Android.Graphics;
|
||||
using Android.Support.V7.Widget;
|
||||
using Android.Text;
|
||||
using Android.Text.Style;
|
||||
using Android.Views;
|
||||
using MusicApp.Resources.values;
|
||||
using Square.Picasso;
|
||||
|
||||
namespace MusicApp.Resources.Portable_Class
|
||||
{
|
||||
public class CurrentItemDecoration : RecyclerView.ItemDecoration
|
||||
{
|
||||
public CurrentItemDecoration() { }
|
||||
|
||||
public override void OnDrawOver(Canvas c, RecyclerView parent, RecyclerView.State state)
|
||||
{
|
||||
base.OnDrawOver(c, parent, state);
|
||||
|
||||
if(parent.ChildCount > 1 && parent.Width > 0)
|
||||
{
|
||||
int firstPos = parent.GetChildAdapterPosition(parent.GetChildAt(0));
|
||||
int lastPos = parent.GetChildAdapterPosition(parent.GetChildAt(parent.ChildCount - 1));
|
||||
int currentPos = MusicPlayer.CurrentID() + 1;
|
||||
|
||||
if (currentPos <= firstPos)
|
||||
{
|
||||
View header = LayoutInflater.From(parent.Context).Inflate(Resource.Layout.QueueCurrent, parent, false);
|
||||
int parentWidth = View.MeasureSpec.MakeMeasureSpec(parent.Width, MeasureSpecMode.Exactly);
|
||||
int parentHeight = View.MeasureSpec.MakeMeasureSpec(parent.Height, MeasureSpecMode.Unspecified);
|
||||
int headerWidth = ViewGroup.GetChildMeasureSpec(parentWidth, 0, header.LayoutParameters.Width);
|
||||
int headerHeight = ViewGroup.GetChildMeasureSpec(parentHeight, 0, header.LayoutParameters.Height);
|
||||
|
||||
header.Measure(headerWidth, headerHeight);
|
||||
header.Layout(0, 0, header.MeasuredWidth, header.MeasuredHeight);
|
||||
|
||||
header.FindViewById(Resource.Id.topDivider).Visibility = ViewStates.Gone;
|
||||
BindHolder(new RecyclerHolder(header, null, null));
|
||||
|
||||
c.Save();
|
||||
c.Translate(0, 0);
|
||||
header.Draw(c);
|
||||
c.Restore();
|
||||
parent.SetPadding(0, header.MeasuredHeight, 0, 0);
|
||||
}
|
||||
else if (currentPos >= lastPos)
|
||||
{
|
||||
View header = LayoutInflater.From(parent.Context).Inflate(Resource.Layout.QueueCurrent, parent, false);
|
||||
int parentWidth = View.MeasureSpec.MakeMeasureSpec(parent.Width, MeasureSpecMode.Exactly);
|
||||
int parentHeight = View.MeasureSpec.MakeMeasureSpec(parent.Height, MeasureSpecMode.Unspecified);
|
||||
int headerWidth = ViewGroup.GetChildMeasureSpec(parentWidth, 0, header.LayoutParameters.Width);
|
||||
int headerHeight = ViewGroup.GetChildMeasureSpec(parentHeight, 0, header.LayoutParameters.Height);
|
||||
|
||||
header.Measure(headerWidth, headerHeight);
|
||||
header.Layout(0, 0, header.MeasuredWidth, header.MeasuredHeight);
|
||||
|
||||
header.FindViewById(Resource.Id.bottomDivider).Visibility = ViewStates.Gone;
|
||||
BindHolder(new RecyclerHolder(header, null, null));
|
||||
|
||||
c.Save();
|
||||
c.Translate(0, parentHeight - header.MeasuredHeight);
|
||||
header.Draw(c);
|
||||
c.Restore();
|
||||
parent.SetPadding(0, 0, 0, header.MeasuredHeight);
|
||||
}
|
||||
else
|
||||
{
|
||||
parent.SetPadding(0, 0, 0, 0);
|
||||
}
|
||||
}
|
||||
|
||||
void BindHolder(RecyclerHolder holder)
|
||||
{
|
||||
Song current = MusicPlayer.queue[MusicPlayer.CurrentID()];
|
||||
|
||||
holder.more.SetColorFilter(Color.White);
|
||||
holder.youtubeIcon.SetColorFilter(Color.White);
|
||||
holder.status.SetTextColor(MusicPlayer.isRunning ? Color.Argb(255, 244, 81, 30) : Color.Argb(255, 66, 165, 245));
|
||||
string status = MusicPlayer.isRunning ? Queue.instance.GetString(Resource.String.playing) : Queue.instance.GetString(Resource.String.paused);
|
||||
SpannableString statusText = new SpannableString(status);
|
||||
statusText.SetSpan(new BackgroundColorSpan(Color.ParseColor("#8C000000")), 0, status.Length, SpanTypes.InclusiveInclusive);
|
||||
holder.status.TextFormatted = statusText;
|
||||
|
||||
SpannableString titleText = new SpannableString(current.Title);
|
||||
titleText.SetSpan(new BackgroundColorSpan(Color.ParseColor("#8C000000")), 0, current.Title.Length, SpanTypes.InclusiveInclusive);
|
||||
holder.Title.TextFormatted = titleText;
|
||||
|
||||
if (current.AlbumArt == -1 || current.IsYt)
|
||||
{
|
||||
var songAlbumArtUri = Android.Net.Uri.Parse(current.Album);
|
||||
Picasso.With(Application.Context).Load(songAlbumArtUri).Placeholder(Resource.Color.background_material_dark).Transform(new RemoveBlackBorder(true)).Into(holder.AlbumArt);
|
||||
}
|
||||
else
|
||||
{
|
||||
var songCover = Android.Net.Uri.Parse("content://media/external/audio/albumart");
|
||||
var songAlbumArtUri = ContentUris.WithAppendedId(songCover, current.AlbumArt);
|
||||
|
||||
Picasso.With(Application.Context).Load(songAlbumArtUri).Placeholder(Resource.Color.background_material_dark).Resize(400, 400).CenterCrop().Into(holder.AlbumArt);
|
||||
}
|
||||
|
||||
if (current.IsLiveStream)
|
||||
holder.Live.Visibility = ViewStates.Visible;
|
||||
else
|
||||
holder.Live.Visibility = ViewStates.Gone;
|
||||
|
||||
if (current.IsParsed != true && current.IsYt)
|
||||
{
|
||||
holder.youtubeIcon.SetImageResource(Resource.Drawable.needProcessing);
|
||||
holder.youtubeIcon.Visibility = ViewStates.Visible;
|
||||
}
|
||||
else if (current.IsParsed == true && current.IsYt)
|
||||
{
|
||||
holder.youtubeIcon.SetImageResource(Resource.Drawable.PublicIcon);
|
||||
holder.youtubeIcon.Visibility = ViewStates.Visible;
|
||||
}
|
||||
else
|
||||
{
|
||||
holder.youtubeIcon.Visibility = ViewStates.Gone;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -417,7 +417,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
{
|
||||
HomeSection queue = new HomeSection("Queue", SectionType.SinglePlaylist, MusicPlayer.queue);
|
||||
adapterItems.Insert(0, queue);
|
||||
adapter.Insert(0, queue);
|
||||
adapter?.Insert(0, queue);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
int dragFlag = ItemTouchHelper.Up | ItemTouchHelper.Down;
|
||||
int swipeFlag = ItemTouchHelper.Left | ItemTouchHelper.Right;
|
||||
|
||||
if (Queue.instance != null && viewHolder.AdapterPosition + 1 == Queue.instance.adapter.ItemCount)
|
||||
if (Queue.instance != null && (viewHolder.AdapterPosition + 1 == ((QueueAdapter)adapter).ItemCount || viewHolder.AdapterPosition == 0))
|
||||
return MakeFlag(0, 0);
|
||||
|
||||
if (Queue.instance != null && MusicPlayer.CurrentID() == viewHolder.AdapterPosition)
|
||||
@@ -59,7 +59,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
|
||||
public override bool OnMove(RecyclerView recyclerView, RecyclerView.ViewHolder source, RecyclerView.ViewHolder target)
|
||||
{
|
||||
if (Queue.instance != null && target.AdapterPosition + 1 == Queue.instance.adapter.ItemCount)
|
||||
if (Queue.instance != null && target.AdapterPosition + 1 == ((QueueAdapter)adapter).ItemCount)
|
||||
return false;
|
||||
|
||||
if (from == -1)
|
||||
|
||||
@@ -343,7 +343,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
SaveQueueSlot();
|
||||
Player.instance?.RefreshPlayer();
|
||||
Home.instance?.AddQueue();
|
||||
Queue.instance?.adapter.NotifyDataSetChanged();
|
||||
Queue.instance?.Refresh();
|
||||
ParseNextSong();
|
||||
if (useAutoPlay)
|
||||
GenerateAutoPlay(false);
|
||||
@@ -453,7 +453,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
SaveQueueSlot();
|
||||
autoPlay.Clear();
|
||||
currentID = CurrentID() + 1;
|
||||
Queue.instance?.adapter.NotifyDataSetChanged();
|
||||
Queue.instance?.Refresh();
|
||||
}
|
||||
else
|
||||
Queue.instance?.RefreshCurrent();
|
||||
@@ -508,7 +508,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
song.IsParsed = true;
|
||||
|
||||
if (position != -1)
|
||||
Queue.instance?.adapter.NotifyItemChanged(position, Resource.Drawable.PublicIcon);
|
||||
Queue.instance?.NotifyItemChanged(position, Resource.Drawable.PublicIcon);
|
||||
|
||||
if (startPlaybackWhenPosible)
|
||||
instance.Play(song, -1, position == -1);
|
||||
@@ -520,7 +520,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
Player.instance?.RefreshPlayer();
|
||||
|
||||
if (position != -1)
|
||||
Queue.instance?.adapter.NotifyItemChanged(position, song.Artist);
|
||||
Queue.instance?.NotifyItemChanged(position, song.Artist);
|
||||
|
||||
if (!song.IsLiveStream)
|
||||
song.ExpireDate = mediaStreamInfo.ValidUntil;
|
||||
@@ -560,7 +560,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
queue.Clear();
|
||||
autoPlay.Clear();
|
||||
queue.Add(song);
|
||||
Queue.instance?.adapter.NotifyDataSetChanged();
|
||||
Queue.instance?.Refresh();
|
||||
Player.instance?.RefreshPlayer();
|
||||
currentID = 0;
|
||||
await ParseSong(song, 0, true);
|
||||
@@ -759,7 +759,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
UpdateQueueDataBase();
|
||||
SaveQueueSlot();
|
||||
Player.instance?.UpdateNext();
|
||||
Queue.instance?.adapter.NotifyDataSetChanged();
|
||||
Queue.instance?.Refresh();
|
||||
Home.instance?.RefreshQueue();
|
||||
Queue.instance?.ListView.ScrollToPosition(0);
|
||||
}
|
||||
@@ -1336,7 +1336,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
|
||||
public void Resume()
|
||||
{
|
||||
if(!UseCastPlayer && player != null && !isRunning)
|
||||
if(!UseCastPlayer && player != null && notification != null && !isRunning)
|
||||
{
|
||||
ISharedPreferences prefManager = PreferenceManager.GetDefaultSharedPreferences(Application.Context);
|
||||
player.Volume = prefManager.GetInt("volumeMultiplier", 100) / 100f;
|
||||
@@ -1503,7 +1503,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
for (int i = 0; i < RemotePlayer.MediaQueue.ItemCount; i++)
|
||||
queue.Add((Song)RemotePlayer.MediaQueue.GetItemAtIndex(i, true));
|
||||
|
||||
Queue.instance?.adapter.NotifyDataSetChanged();
|
||||
Queue.instance?.Refresh();
|
||||
Console.WriteLine("&Waiting for fetch - queue count: " + queue.Count);
|
||||
|
||||
if (queue.Count > 0)
|
||||
@@ -1522,7 +1522,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
|
||||
Home.instance?.AddQueue();
|
||||
Home.instance?.RefreshQueue(false);
|
||||
Queue.instance?.adapter.NotifyDataSetChanged();
|
||||
Queue.instance?.Refresh();
|
||||
|
||||
if (showPlayer)
|
||||
MainActivity.instance.ShowSmallPlayer();
|
||||
@@ -1561,7 +1561,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
MainActivity.instance?.HideSmallPlayer();
|
||||
if (Home.adapterItems?.Count > 0 && Home.adapterItems[0]?.SectionTitle == "Queue")
|
||||
{
|
||||
Home.instance?.adapter.NotifyItemRemoved(0);
|
||||
Home.instance?.adapter?.NotifyItemRemoved(0);
|
||||
Home.adapterItems?.RemoveAt(0);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -179,21 +179,24 @@ namespace MusicApp
|
||||
view.SetImageBitmap(drawable);
|
||||
Palette.From(drawable).MaximumColorCount(28).Generate(this);
|
||||
|
||||
//The width of the view in pixel (we'll multiply this by 0.75f because the drawer has a width of 75%)
|
||||
int width = (int)(view.Width * (float)drawable.Height / view.Height);
|
||||
int dX = (int)((drawable.Width - width) * 0.5f);
|
||||
Bitmap blured = Bitmap.CreateBitmap(drawable, dX, 0, (int)(width * 0.75f), drawable.Height);
|
||||
if(view.Width > 0)
|
||||
{
|
||||
//The width of the view in pixel (we'll multiply this by 0.75f because the drawer has a width of 75%)
|
||||
int width = (int)(view.Width * (float)drawable.Height / view.Height);
|
||||
int dX = (int)((drawable.Width - width) * 0.5f);
|
||||
Bitmap blured = Bitmap.CreateBitmap(drawable, dX, 0, (int)(width * 0.75f), drawable.Height);
|
||||
|
||||
RenderScript rs = RenderScript.Create(MainActivity.instance);
|
||||
Allocation input = Allocation.CreateFromBitmap(rs, blured);
|
||||
Allocation output = Allocation.CreateTyped(rs, input.Type);
|
||||
ScriptIntrinsicBlur blurrer = ScriptIntrinsicBlur.Create(rs, Element.U8_4(rs));
|
||||
blurrer.SetRadius(13);
|
||||
blurrer.SetInput(input);
|
||||
blurrer.ForEach(output);
|
||||
RenderScript rs = RenderScript.Create(MainActivity.instance);
|
||||
Allocation input = Allocation.CreateFromBitmap(rs, blured);
|
||||
Allocation output = Allocation.CreateTyped(rs, input.Type);
|
||||
ScriptIntrinsicBlur blurrer = ScriptIntrinsicBlur.Create(rs, Element.U8_4(rs));
|
||||
blurrer.SetRadius(13);
|
||||
blurrer.SetInput(input);
|
||||
blurrer.ForEach(output);
|
||||
|
||||
output.CopyTo(blured);
|
||||
MainActivity.instance.FindViewById<ImageView>(Resource.Id.queueBackground).SetImageBitmap(blured);
|
||||
output.CopyTo(blured);
|
||||
MainActivity.instance.FindViewById<ImageView>(Resource.Id.queueBackground).SetImageBitmap(blured);
|
||||
}
|
||||
|
||||
if (bar != null)
|
||||
{
|
||||
@@ -402,7 +405,7 @@ namespace MusicApp
|
||||
|
||||
private void ShowQueue_Click(object sender, EventArgs e)
|
||||
{
|
||||
Queue.instance?.adapter.NotifyDataSetChanged();
|
||||
Queue.instance?.Refresh();
|
||||
DrawerLayout.OpenDrawer((int)GravityFlags.Start);
|
||||
}
|
||||
|
||||
|
||||
@@ -792,7 +792,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
|
||||
songs.RemoveAt(0);
|
||||
MusicPlayer.queue.AddRange(songs);
|
||||
Queue.instance?.adapter.NotifyDataSetChanged();
|
||||
Queue.instance?.Refresh();
|
||||
|
||||
while (MusicPlayer.instance == null)
|
||||
await Task.Delay(10);
|
||||
|
||||
@@ -5,9 +5,10 @@ using Android.Graphics;
|
||||
using Android.OS;
|
||||
using Android.Runtime;
|
||||
using Android.Support.Design.Widget;
|
||||
using Android.Support.V7.App;
|
||||
using Android.Support.V7.Widget;
|
||||
using Android.Support.V7.Widget.Helper;
|
||||
using Android.Text;
|
||||
using Android.Text.Style;
|
||||
using Android.Views;
|
||||
using Android.Widget;
|
||||
using MusicApp;
|
||||
@@ -16,7 +17,6 @@ using MusicApp.Resources.values;
|
||||
using Square.Picasso;
|
||||
using System.Collections.Generic;
|
||||
using Fragment = Android.Support.V4.App.Fragment;
|
||||
using Toolbar = Android.Support.V7.Widget.Toolbar;
|
||||
|
||||
[Activity(Label = "Queue", Theme = "@style/Theme", ScreenOrientation = ScreenOrientation.Portrait)]
|
||||
[Register("MusicApp/Queue")]
|
||||
@@ -24,7 +24,7 @@ public class Queue : Fragment
|
||||
{
|
||||
public static Queue instance;
|
||||
public RecyclerView ListView;
|
||||
public QueueAdapter adapter;
|
||||
private QueueAdapter adapter;
|
||||
public ItemTouchHelper itemTouchHelper;
|
||||
public IMenu menu;
|
||||
|
||||
@@ -39,6 +39,7 @@ public class Queue : Fragment
|
||||
adapter.ItemClick += ListView_ItemClick;
|
||||
adapter.ItemLongCLick += ListView_ItemLongCLick;
|
||||
ListView.SetItemAnimator(new DefaultItemAnimator());
|
||||
ListView.AddItemDecoration(new CurrentItemDecoration());
|
||||
ListView.ScrollChange += Scroll;
|
||||
|
||||
ItemTouchHelper.Callback callback = new ItemTouchCallback(adapter, true);
|
||||
@@ -66,6 +67,29 @@ public class Queue : Fragment
|
||||
// instance = null;
|
||||
//}
|
||||
|
||||
public void Refresh()
|
||||
{
|
||||
adapter.NotifyDataSetChanged();
|
||||
}
|
||||
|
||||
public void NotifyItemChanged(int position)
|
||||
{
|
||||
position++;
|
||||
adapter.NotifyItemChanged(position);
|
||||
}
|
||||
|
||||
public void NotifyItemChanged(int position, Java.Lang.Object payload)
|
||||
{
|
||||
position++;
|
||||
adapter.NotifyItemChanged(position, payload);
|
||||
}
|
||||
|
||||
public void NotifyItemRemoved(int position)
|
||||
{
|
||||
position++;
|
||||
adapter.NotifyItemRemoved(position);
|
||||
}
|
||||
|
||||
public void RefreshCurrent()
|
||||
{
|
||||
int first = ((LinearLayoutManager)ListView.GetLayoutManager()).FindFirstVisibleItemPosition();
|
||||
@@ -74,11 +98,15 @@ public class Queue : Fragment
|
||||
{
|
||||
Song song = MusicPlayer.queue[i];
|
||||
RecyclerHolder holder = (RecyclerHolder)ListView.GetChildViewHolder(((LinearLayoutManager)ListView.GetLayoutManager()).FindViewByPosition(i));
|
||||
if (MusicPlayer.queue[MusicPlayer.CurrentID()] == song)
|
||||
if (MusicPlayer.queue[MusicPlayer.CurrentID() + 1] == song)
|
||||
{
|
||||
holder.status.Text = MusicPlayer.isRunning ? GetString(Resource.String.playing) : GetString(Resource.String.paused);
|
||||
holder.status.SetTextColor(MusicPlayer.isRunning ? Color.Argb(255, 244, 81, 30) : Color.Argb(255, 66, 165, 245));
|
||||
holder.status.Visibility = ViewStates.Visible;
|
||||
holder.status.SetTextColor(MusicPlayer.isRunning ? Color.Argb(255, 244, 81, 30) : Color.Argb(255, 66, 165, 245));
|
||||
|
||||
string status = MusicPlayer.isRunning ? GetString(Resource.String.playing) : GetString(Resource.String.paused);
|
||||
SpannableString statusText = new SpannableString(status);
|
||||
statusText.SetSpan(new BackgroundColorSpan(Color.ParseColor("#8C000000")), 0, status.Length, SpanTypes.InclusiveInclusive);
|
||||
holder.status.TextFormatted = statusText;
|
||||
}
|
||||
else
|
||||
holder.status.Visibility = ViewStates.Gone;
|
||||
|
||||
@@ -22,10 +22,13 @@ namespace MusicApp.Resources.Portable_Class
|
||||
|
||||
public QueueAdapter(List<Song> songList) { }
|
||||
|
||||
public override int ItemCount => MusicPlayer.UseCastPlayer ? MusicPlayer.RemotePlayer.MediaQueue.ItemCount + 1 : MusicPlayer.queue.Count + 1;
|
||||
public override int ItemCount => MusicPlayer.UseCastPlayer ? MusicPlayer.RemotePlayer.MediaQueue.ItemCount + 2 : MusicPlayer.queue.Count + 2;
|
||||
|
||||
public override void OnBindViewHolder(RecyclerView.ViewHolder viewHolder, int position)
|
||||
{
|
||||
if (position == 0)
|
||||
return;
|
||||
|
||||
if (position + 1 == ItemCount)
|
||||
{
|
||||
QueueFooter holder = (QueueFooter)viewHolder;
|
||||
@@ -109,24 +112,23 @@ namespace MusicApp.Resources.Portable_Class
|
||||
}
|
||||
else
|
||||
{
|
||||
position--;
|
||||
RecyclerHolder holder = (RecyclerHolder)viewHolder;
|
||||
|
||||
if (MainActivity.Theme == 1)
|
||||
{
|
||||
holder.reorder.SetColorFilter(Color.White);
|
||||
holder.Title.SetTextColor(Color.White);
|
||||
holder.Artist.SetTextColor(Color.White);
|
||||
holder.Artist.Alpha = 0.7f;
|
||||
holder.youtubeIcon.SetColorFilter(Color.White);
|
||||
}
|
||||
|
||||
holder.reorder.SetColorFilter(Color.White);
|
||||
holder.Title.SetTextColor(Color.White);
|
||||
holder.youtubeIcon.SetColorFilter(Color.White);
|
||||
holder.reorder.Visibility = ViewStates.Visible;
|
||||
holder.more.Visibility = ViewStates.Gone;
|
||||
if (position == MusicPlayer.CurrentID())
|
||||
{
|
||||
holder.status.Visibility = ViewStates.Visible;
|
||||
holder.status.Text = MusicPlayer.isRunning ? Queue.instance.GetString(Resource.String.playing) : Queue.instance.GetString(Resource.String.paused);
|
||||
holder.status.SetTextColor(MusicPlayer.isRunning ? Color.Argb(255, 244, 81, 30) : Color.Argb(255, 66, 165, 245));
|
||||
|
||||
string status = MusicPlayer.isRunning ? Queue.instance.GetString(Resource.String.playing) : Queue.instance.GetString(Resource.String.paused);
|
||||
SpannableString statusText = new SpannableString(status);
|
||||
statusText.SetSpan(new BackgroundColorSpan(Color.ParseColor("#8C000000")), 0, status.Length, SpanTypes.InclusiveInclusive);
|
||||
holder.status.TextFormatted = statusText;
|
||||
}
|
||||
else
|
||||
holder.status.Visibility = ViewStates.Gone;
|
||||
@@ -279,10 +281,6 @@ namespace MusicApp.Resources.Portable_Class
|
||||
}
|
||||
else
|
||||
{
|
||||
Console.WriteLine("&Payload: " + payloads[0].ToString());
|
||||
Console.WriteLine("&Position: " + position);
|
||||
Console.WriteLine("&Song at position: " + MusicPlayer.queue[position]);
|
||||
|
||||
RecyclerHolder holder = (RecyclerHolder)viewHolder;
|
||||
|
||||
if (payloads[0].ToString() == holder.Title.Text)
|
||||
@@ -297,7 +295,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
if (payloads[0].ToString() != null && (holder.Artist.Text == "" || holder.Artist.Text == null))
|
||||
{
|
||||
holder.Artist.Text = payloads[0].ToString();
|
||||
Song song = MusicPlayer.queue[position];
|
||||
Song song = MusicPlayer.queue[position - 1];
|
||||
|
||||
if (song.IsYt)
|
||||
{
|
||||
@@ -319,6 +317,11 @@ namespace MusicApp.Resources.Portable_Class
|
||||
View itemView = LayoutInflater.From(parent.Context).Inflate(Resource.Layout.SongList, parent, false);
|
||||
return new RecyclerHolder(itemView, OnClick, OnLongClick);
|
||||
}
|
||||
else if(viewType == 1)
|
||||
{
|
||||
View itemView = LayoutInflater.From(parent.Context).Inflate(Resource.Layout.Empty, parent, false);
|
||||
return new UslessHolder(itemView);
|
||||
}
|
||||
else
|
||||
{
|
||||
View itemView = LayoutInflater.From(parent.Context).Inflate(Resource.Layout.QueueFooter, parent, false);
|
||||
@@ -329,6 +332,8 @@ namespace MusicApp.Resources.Portable_Class
|
||||
public override int GetItemViewType(int position)
|
||||
{
|
||||
if (position + 1 == ItemCount)
|
||||
return 2;
|
||||
else if (position == 0)
|
||||
return 1;
|
||||
else
|
||||
return 0;
|
||||
@@ -336,16 +341,21 @@ namespace MusicApp.Resources.Portable_Class
|
||||
|
||||
void OnClick(int position)
|
||||
{
|
||||
position--;
|
||||
ItemClick?.Invoke(this, position);
|
||||
}
|
||||
|
||||
void OnLongClick(int position)
|
||||
{
|
||||
position--;
|
||||
ItemLongCLick?.Invoke(this, position);
|
||||
}
|
||||
|
||||
public void ItemMoved(int fromPosition, int toPosition)
|
||||
{
|
||||
fromPosition--;
|
||||
toPosition--;
|
||||
|
||||
if(fromPosition < toPosition)
|
||||
{
|
||||
for(int i = fromPosition; i < toPosition; i++)
|
||||
@@ -362,6 +372,9 @@ namespace MusicApp.Resources.Portable_Class
|
||||
|
||||
public void ItemMoveEnded(int fromPosition, int toPosition)
|
||||
{
|
||||
fromPosition--;
|
||||
toPosition--;
|
||||
|
||||
if (MusicPlayer.CurrentID() > fromPosition && MusicPlayer.CurrentID() <= toPosition)
|
||||
MusicPlayer.currentID--;
|
||||
|
||||
@@ -381,6 +394,8 @@ namespace MusicApp.Resources.Portable_Class
|
||||
|
||||
List<T> Swap<T>(List<T> list, int fromPosition, int toPosition)
|
||||
{
|
||||
fromPosition--;
|
||||
toPosition--;
|
||||
T item = list[fromPosition];
|
||||
list[fromPosition] = list[toPosition];
|
||||
list[toPosition] = item;
|
||||
@@ -389,6 +404,8 @@ namespace MusicApp.Resources.Portable_Class
|
||||
|
||||
public void ItemDismissed(int position)
|
||||
{
|
||||
position--;
|
||||
|
||||
Song song = MusicPlayer.queue[position];
|
||||
Queue.RemoveFromQueue(position);
|
||||
Snackbar snackbar = Snackbar.Make(MainActivity.instance.FindViewById(Resource.Id.recycler), (song.Title.Length > 20 ? song.Title.Substring(0, 17) + "..." : song.Title) + Queue.instance.GetString(Resource.String.removed_from_queue), Snackbar.LengthShort)
|
||||
|
||||
@@ -994,7 +994,7 @@ namespace MusicApp.Resources.Portable_Class
|
||||
MainActivity.instance.ShowPlayer();
|
||||
Player.instance?.UpdateNext();
|
||||
Home.instance?.RefreshQueue();
|
||||
Queue.instance?.adapter.NotifyDataSetChanged();
|
||||
Queue.instance?.Refresh();
|
||||
parseProgress.Visibility = ViewStates.Gone;
|
||||
}
|
||||
|
||||
|
||||
349
MusicApp/Resources/Resource.Designer.cs
generated
349
MusicApp/Resources/Resource.Designer.cs
generated
@@ -5072,8 +5072,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0057
|
||||
public const int add = 2131361879;
|
||||
|
||||
// aapt resource value: 0x7f0a01cc
|
||||
public const int addToQueue = 2131362252;
|
||||
// aapt resource value: 0x7f0a01cf
|
||||
public const int addToQueue = 2131362255;
|
||||
|
||||
// aapt resource value: 0x7f0a00cc
|
||||
public const int added = 2131361996;
|
||||
@@ -5096,11 +5096,11 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0068
|
||||
public const int always = 2131361896;
|
||||
|
||||
// aapt resource value: 0x7f0a01b5
|
||||
public const int apAlbum = 2131362229;
|
||||
// aapt resource value: 0x7f0a01ba
|
||||
public const int apAlbum = 2131362234;
|
||||
|
||||
// aapt resource value: 0x7f0a01b7
|
||||
public const int apTitle = 2131362231;
|
||||
// aapt resource value: 0x7f0a01bc
|
||||
public const int apTitle = 2131362236;
|
||||
|
||||
// aapt resource value: 0x7f0a011c
|
||||
public const int appbar = 2131362076;
|
||||
@@ -5117,8 +5117,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a004b
|
||||
public const int auto = 2131361867;
|
||||
|
||||
// aapt resource value: 0x7f0a01b4
|
||||
public const int autoplay = 2131362228;
|
||||
// aapt resource value: 0x7f0a01b9
|
||||
public const int autoplay = 2131362233;
|
||||
|
||||
// aapt resource value: 0x7f0a0120
|
||||
public const int backToolbar = 2131362080;
|
||||
@@ -5144,11 +5144,14 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a006d
|
||||
public const int bottom = 2131361901;
|
||||
|
||||
// aapt resource value: 0x7f0a01b7
|
||||
public const int bottomDivider = 2131362231;
|
||||
|
||||
// aapt resource value: 0x7f0a0137
|
||||
public const int bottomView = 2131362103;
|
||||
|
||||
// aapt resource value: 0x7f0a01c7
|
||||
public const int browseLayout = 2131362247;
|
||||
// aapt resource value: 0x7f0a01ca
|
||||
public const int browseLayout = 2131362250;
|
||||
|
||||
// aapt resource value: 0x7f0a00d8
|
||||
public const int browseList = 2131362008;
|
||||
@@ -5315,8 +5318,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a009e
|
||||
public const int default_activity_button = 2131361950;
|
||||
|
||||
// aapt resource value: 0x7f0a01c9
|
||||
public const int delete = 2131362249;
|
||||
// aapt resource value: 0x7f0a01cc
|
||||
public const int delete = 2131362252;
|
||||
|
||||
// aapt resource value: 0x7f0a0111
|
||||
public const int design_bottom_sheet = 2131362065;
|
||||
@@ -5342,11 +5345,11 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0190
|
||||
public const int downButton = 2131362192;
|
||||
|
||||
// aapt resource value: 0x7f0a01d3
|
||||
public const int download = 2131362259;
|
||||
// aapt resource value: 0x7f0a01d6
|
||||
public const int download = 2131362262;
|
||||
|
||||
// aapt resource value: 0x7f0a01ca
|
||||
public const int downloadMDfromYT = 2131362250;
|
||||
// aapt resource value: 0x7f0a01cd
|
||||
public const int downloadMDfromYT = 2131362253;
|
||||
|
||||
// aapt resource value: 0x7f0a0119
|
||||
public const int downloadStatus = 2131362073;
|
||||
@@ -5471,8 +5474,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0087
|
||||
public const int filled = 2131361927;
|
||||
|
||||
// aapt resource value: 0x7f0a01d0
|
||||
public const int filter = 2131362256;
|
||||
// aapt resource value: 0x7f0a01d3
|
||||
public const int filter = 2131362259;
|
||||
|
||||
// aapt resource value: 0x7f0a0092
|
||||
public const int fit = 2131361938;
|
||||
@@ -5498,8 +5501,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a008f
|
||||
public const int forever = 2131361935;
|
||||
|
||||
// aapt resource value: 0x7f0a01d4
|
||||
public const int fork = 2131362260;
|
||||
// aapt resource value: 0x7f0a01d7
|
||||
public const int fork = 2131362263;
|
||||
|
||||
// aapt resource value: 0x7f0a0017
|
||||
public const int ghost_view = 2131361815;
|
||||
@@ -5537,8 +5540,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a00a0
|
||||
public const int icon = 2131361952;
|
||||
|
||||
// aapt resource value: 0x7f0a01c0
|
||||
public const int icon1 = 2131362240;
|
||||
// aapt resource value: 0x7f0a01c3
|
||||
public const int icon1 = 2131362243;
|
||||
|
||||
// aapt resource value: 0x7f0a0129
|
||||
public const int icon_frame = 2131362089;
|
||||
@@ -5564,8 +5567,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a019e
|
||||
public const int infoPanel = 2131362206;
|
||||
|
||||
// aapt resource value: 0x7f0a01bd
|
||||
public const int isLive = 2131362237;
|
||||
// aapt resource value: 0x7f0a01b5
|
||||
public const int isLive = 2131362229;
|
||||
|
||||
// aapt resource value: 0x7f0a0090
|
||||
public const int italic = 2131361936;
|
||||
@@ -5594,8 +5597,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0029
|
||||
public const int line1 = 2131361833;
|
||||
|
||||
// aapt resource value: 0x7f0a01c3
|
||||
public const int line2 = 2131362243;
|
||||
// aapt resource value: 0x7f0a01c6
|
||||
public const int line2 = 2131362246;
|
||||
|
||||
// aapt resource value: 0x7f0a002a
|
||||
public const int line3 = 2131361834;
|
||||
@@ -5630,17 +5633,17 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0103
|
||||
public const int logo = 2131362051;
|
||||
|
||||
// aapt resource value: 0x7f0a01c5
|
||||
public const int masked = 2131362245;
|
||||
// aapt resource value: 0x7f0a01c8
|
||||
public const int masked = 2131362248;
|
||||
|
||||
// aapt resource value: 0x7f0a01bc
|
||||
public const int maxValue = 2131362236;
|
||||
// aapt resource value: 0x7f0a01c1
|
||||
public const int maxValue = 2131362241;
|
||||
|
||||
// aapt resource value: 0x7f0a017e
|
||||
public const int media_actions = 2131362174;
|
||||
|
||||
// aapt resource value: 0x7f0a01d1
|
||||
public const int media_route_menu_item = 2131362257;
|
||||
// aapt resource value: 0x7f0a01d4
|
||||
public const int media_route_menu_item = 2131362260;
|
||||
|
||||
// aapt resource value: 0x7f0a00cb
|
||||
public const int message = 2131361995;
|
||||
@@ -5669,8 +5672,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0061
|
||||
public const int middle = 2131361889;
|
||||
|
||||
// aapt resource value: 0x7f0a01bb
|
||||
public const int minValue = 2131362235;
|
||||
// aapt resource value: 0x7f0a01c0
|
||||
public const int minValue = 2131362240;
|
||||
|
||||
// aapt resource value: 0x7f0a0081
|
||||
public const int mini = 2131361921;
|
||||
@@ -5837,8 +5840,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0058
|
||||
public const int multiply = 2131361880;
|
||||
|
||||
// aapt resource value: 0x7f0a01c6
|
||||
public const int musicLayout = 2131362246;
|
||||
// aapt resource value: 0x7f0a01c9
|
||||
public const int musicLayout = 2131362249;
|
||||
|
||||
// aapt resource value: 0x7f0a0102
|
||||
public const int name = 2131362050;
|
||||
@@ -5879,8 +5882,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0088
|
||||
public const int outline = 2131361928;
|
||||
|
||||
// aapt resource value: 0x7f0a01c2
|
||||
public const int pager = 2131362242;
|
||||
// aapt resource value: 0x7f0a01c5
|
||||
public const int pager = 2131362245;
|
||||
|
||||
// aapt resource value: 0x7f0a007f
|
||||
public const int parallax = 2131361919;
|
||||
@@ -5927,8 +5930,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0132
|
||||
public const int playlistHeader = 2131362098;
|
||||
|
||||
// aapt resource value: 0x7f0a01c8
|
||||
public const int playlistLayout = 2131362248;
|
||||
// aapt resource value: 0x7f0a01cb
|
||||
public const int playlistLayout = 2131362251;
|
||||
|
||||
// aapt resource value: 0x7f0a010b
|
||||
public const int playlistLocation = 2131362059;
|
||||
@@ -5936,8 +5939,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a010a
|
||||
public const int playlistName = 2131362058;
|
||||
|
||||
// aapt resource value: 0x7f0a01b8
|
||||
public const int playlistURL = 2131362232;
|
||||
// aapt resource value: 0x7f0a01bd
|
||||
public const int playlistURL = 2131362237;
|
||||
|
||||
// aapt resource value: 0x7f0a011b
|
||||
public const int progress = 2131362075;
|
||||
@@ -5960,8 +5963,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a019b
|
||||
public const int queueParent = 2131362203;
|
||||
|
||||
// aapt resource value: 0x7f0a01b3
|
||||
public const int queueSwitch = 2131362227;
|
||||
// aapt resource value: 0x7f0a01b8
|
||||
public const int queueSwitch = 2131362232;
|
||||
|
||||
// aapt resource value: 0x7f0a00b6
|
||||
public const int radio = 2131361974;
|
||||
@@ -5972,17 +5975,17 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a01ab
|
||||
public const int recycler_view = 2131362219;
|
||||
|
||||
// aapt resource value: 0x7f0a01c1
|
||||
public const int refine = 2131362241;
|
||||
// aapt resource value: 0x7f0a01c4
|
||||
public const int refine = 2131362244;
|
||||
|
||||
// aapt resource value: 0x7f0a01cd
|
||||
public const int rename = 2131362253;
|
||||
// aapt resource value: 0x7f0a01d0
|
||||
public const int rename = 2131362256;
|
||||
|
||||
// aapt resource value: 0x7f0a01bf
|
||||
public const int reorder = 2131362239;
|
||||
// aapt resource value: 0x7f0a01c2
|
||||
public const int reorder = 2131362242;
|
||||
|
||||
// aapt resource value: 0x7f0a01cf
|
||||
public const int repeat = 2131362255;
|
||||
// aapt resource value: 0x7f0a01d2
|
||||
public const int repeat = 2131362258;
|
||||
|
||||
// aapt resource value: 0x7f0a007d
|
||||
public const int right = 2131361917;
|
||||
@@ -5990,8 +5993,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a01a7
|
||||
public const int rightButtons = 2131362215;
|
||||
|
||||
// aapt resource value: 0x7f0a01b6
|
||||
public const int rightIcon = 2131362230;
|
||||
// aapt resource value: 0x7f0a01bb
|
||||
public const int rightIcon = 2131362235;
|
||||
|
||||
// aapt resource value: 0x7f0a0186
|
||||
public const int right_icon = 2131362182;
|
||||
@@ -6026,11 +6029,11 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0085
|
||||
public const int scrollable = 2131361925;
|
||||
|
||||
// aapt resource value: 0x7f0a01b9
|
||||
public const int search = 2131362233;
|
||||
// aapt resource value: 0x7f0a01be
|
||||
public const int search = 2131362238;
|
||||
|
||||
// aapt resource value: 0x7f0a01ba
|
||||
public const int searchSuggestions = 2131362234;
|
||||
// aapt resource value: 0x7f0a01bf
|
||||
public const int searchSuggestions = 2131362239;
|
||||
|
||||
// aapt resource value: 0x7f0a00c0
|
||||
public const int search_badge = 2131361984;
|
||||
@@ -6080,8 +6083,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0077
|
||||
public const int selected = 2131361911;
|
||||
|
||||
// aapt resource value: 0x7f0a01d2
|
||||
public const int settings = 2131362258;
|
||||
// aapt resource value: 0x7f0a01d5
|
||||
public const int settings = 2131362261;
|
||||
|
||||
// aapt resource value: 0x7f0a00b2
|
||||
public const int shortcut = 2131361970;
|
||||
@@ -6098,8 +6101,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0055
|
||||
public const int showTitle = 2131361877;
|
||||
|
||||
// aapt resource value: 0x7f0a01ce
|
||||
public const int shuffle = 2131362254;
|
||||
// aapt resource value: 0x7f0a01d1
|
||||
public const int shuffle = 2131362257;
|
||||
|
||||
// aapt resource value: 0x7f0a010c
|
||||
public const int smallLabel = 2131362060;
|
||||
@@ -6125,6 +6128,9 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0193
|
||||
public const int songTimer = 2131362195;
|
||||
|
||||
// aapt resource value: 0x7f0a01b4
|
||||
public const int songView = 2131362228;
|
||||
|
||||
// aapt resource value: 0x7f0a013d
|
||||
public const int spArt = 2131362109;
|
||||
|
||||
@@ -6299,6 +6305,9 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a006e
|
||||
public const int top = 2131361902;
|
||||
|
||||
// aapt resource value: 0x7f0a01b3
|
||||
public const int topDivider = 2131362227;
|
||||
|
||||
// aapt resource value: 0x7f0a00ac
|
||||
public const int topPanel = 2131361964;
|
||||
|
||||
@@ -6320,8 +6329,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0020
|
||||
public const int transition_transform = 2131361824;
|
||||
|
||||
// aapt resource value: 0x7f0a01cb
|
||||
public const int undoChange = 2131362251;
|
||||
// aapt resource value: 0x7f0a01ce
|
||||
public const int undoChange = 2131362254;
|
||||
|
||||
// aapt resource value: 0x7f0a005d
|
||||
public const int uniform = 2131361885;
|
||||
@@ -6341,8 +6350,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a0028
|
||||
public const int view_offset_helper = 2131361832;
|
||||
|
||||
// aapt resource value: 0x7f0a01c4
|
||||
public const int visible = 2131362244;
|
||||
// aapt resource value: 0x7f0a01c7
|
||||
public const int visible = 2131362247;
|
||||
|
||||
// aapt resource value: 0x7f0a0169
|
||||
public const int volume_item_container = 2131362153;
|
||||
@@ -6356,8 +6365,8 @@ namespace MusicApp
|
||||
// aapt resource value: 0x7f0a005e
|
||||
public const int wrap_content = 2131361886;
|
||||
|
||||
// aapt resource value: 0x7f0a01be
|
||||
public const int youtubeIcon = 2131362238;
|
||||
// aapt resource value: 0x7f0a01b6
|
||||
public const int youtubeIcon = 2131362230;
|
||||
|
||||
// aapt resource value: 0x7f0a0134
|
||||
public const int ytProgress = 2131362100;
|
||||
@@ -6672,301 +6681,307 @@ namespace MusicApp
|
||||
public const int EditMetaData = 2130903101;
|
||||
|
||||
// aapt resource value: 0x7f03003e
|
||||
public const int EmptyListCategory = 2130903102;
|
||||
public const int Empty = 2130903102;
|
||||
|
||||
// aapt resource value: 0x7f03003f
|
||||
public const int EmptyLoadingLayout = 2130903103;
|
||||
public const int EmptyListCategory = 2130903103;
|
||||
|
||||
// aapt resource value: 0x7f030040
|
||||
public const int EmptyView = 2130903104;
|
||||
public const int EmptyLoadingLayout = 2130903104;
|
||||
|
||||
// aapt resource value: 0x7f030041
|
||||
public const int exo_list_divider = 2130903105;
|
||||
public const int EmptyView = 2130903105;
|
||||
|
||||
// aapt resource value: 0x7f030042
|
||||
public const int exo_playback_control_view = 2130903106;
|
||||
public const int exo_list_divider = 2130903106;
|
||||
|
||||
// aapt resource value: 0x7f030043
|
||||
public const int exo_player_control_view = 2130903107;
|
||||
public const int exo_playback_control_view = 2130903107;
|
||||
|
||||
// aapt resource value: 0x7f030044
|
||||
public const int exo_player_view = 2130903108;
|
||||
public const int exo_player_control_view = 2130903108;
|
||||
|
||||
// aapt resource value: 0x7f030045
|
||||
public const int exo_simple_player_view = 2130903109;
|
||||
public const int exo_player_view = 2130903109;
|
||||
|
||||
// aapt resource value: 0x7f030046
|
||||
public const int exo_track_selection_dialog = 2130903110;
|
||||
public const int exo_simple_player_view = 2130903110;
|
||||
|
||||
// aapt resource value: 0x7f030047
|
||||
public const int expand_button = 2130903111;
|
||||
public const int exo_track_selection_dialog = 2130903111;
|
||||
|
||||
// aapt resource value: 0x7f030048
|
||||
public const int folderList = 2130903112;
|
||||
public const int expand_button = 2130903112;
|
||||
|
||||
// aapt resource value: 0x7f030049
|
||||
public const int HomeChannel = 2130903113;
|
||||
public const int folderList = 2130903113;
|
||||
|
||||
// aapt resource value: 0x7f03004a
|
||||
public const int HomeChannels = 2130903114;
|
||||
public const int HomeChannel = 2130903114;
|
||||
|
||||
// aapt resource value: 0x7f03004b
|
||||
public const int HomePlaylists = 2130903115;
|
||||
public const int HomeChannels = 2130903115;
|
||||
|
||||
// aapt resource value: 0x7f03004c
|
||||
public const int HomeShuffle = 2130903116;
|
||||
public const int HomePlaylists = 2130903116;
|
||||
|
||||
// aapt resource value: 0x7f03004d
|
||||
public const int HomeTopic = 2130903117;
|
||||
public const int HomeShuffle = 2130903117;
|
||||
|
||||
// aapt resource value: 0x7f03004e
|
||||
public const int LineSong = 2130903118;
|
||||
public const int HomeTopic = 2130903118;
|
||||
|
||||
// aapt resource value: 0x7f03004f
|
||||
public const int LineSongs = 2130903119;
|
||||
public const int LineSong = 2130903119;
|
||||
|
||||
// aapt resource value: 0x7f030050
|
||||
public const int LogOutButton = 2130903120;
|
||||
public const int LineSongs = 2130903120;
|
||||
|
||||
// aapt resource value: 0x7f030051
|
||||
public const int Main = 2130903121;
|
||||
public const int LogOutButton = 2130903121;
|
||||
|
||||
// aapt resource value: 0x7f030052
|
||||
public const int mr_cast_dialog = 2130903122;
|
||||
public const int Main = 2130903122;
|
||||
|
||||
// aapt resource value: 0x7f030053
|
||||
public const int mr_cast_group_item = 2130903123;
|
||||
public const int mr_cast_dialog = 2130903123;
|
||||
|
||||
// aapt resource value: 0x7f030054
|
||||
public const int mr_cast_group_volume_item = 2130903124;
|
||||
public const int mr_cast_group_item = 2130903124;
|
||||
|
||||
// aapt resource value: 0x7f030055
|
||||
public const int mr_cast_media_metadata = 2130903125;
|
||||
public const int mr_cast_group_volume_item = 2130903125;
|
||||
|
||||
// aapt resource value: 0x7f030056
|
||||
public const int mr_cast_route_item = 2130903126;
|
||||
public const int mr_cast_media_metadata = 2130903126;
|
||||
|
||||
// aapt resource value: 0x7f030057
|
||||
public const int mr_chooser_dialog = 2130903127;
|
||||
public const int mr_cast_route_item = 2130903127;
|
||||
|
||||
// aapt resource value: 0x7f030058
|
||||
public const int mr_chooser_list_item = 2130903128;
|
||||
public const int mr_chooser_dialog = 2130903128;
|
||||
|
||||
// aapt resource value: 0x7f030059
|
||||
public const int mr_controller_material_dialog_b = 2130903129;
|
||||
public const int mr_chooser_list_item = 2130903129;
|
||||
|
||||
// aapt resource value: 0x7f03005a
|
||||
public const int mr_controller_volume_item = 2130903130;
|
||||
public const int mr_controller_material_dialog_b = 2130903130;
|
||||
|
||||
// aapt resource value: 0x7f03005b
|
||||
public const int mr_dialog_header_item = 2130903131;
|
||||
public const int mr_controller_volume_item = 2130903131;
|
||||
|
||||
// aapt resource value: 0x7f03005c
|
||||
public const int mr_picker_dialog = 2130903132;
|
||||
public const int mr_dialog_header_item = 2130903132;
|
||||
|
||||
// aapt resource value: 0x7f03005d
|
||||
public const int mr_picker_route_item = 2130903133;
|
||||
public const int mr_picker_dialog = 2130903133;
|
||||
|
||||
// aapt resource value: 0x7f03005e
|
||||
public const int mr_playback_control = 2130903134;
|
||||
public const int mr_picker_route_item = 2130903134;
|
||||
|
||||
// aapt resource value: 0x7f03005f
|
||||
public const int mr_volume_control = 2130903135;
|
||||
public const int mr_playback_control = 2130903135;
|
||||
|
||||
// aapt resource value: 0x7f030060
|
||||
public const int mtrl_layout_snackbar = 2130903136;
|
||||
public const int mr_volume_control = 2130903136;
|
||||
|
||||
// aapt resource value: 0x7f030061
|
||||
public const int mtrl_layout_snackbar_include = 2130903137;
|
||||
public const int mtrl_layout_snackbar = 2130903137;
|
||||
|
||||
// aapt resource value: 0x7f030062
|
||||
public const int MusicLayout = 2130903138;
|
||||
public const int mtrl_layout_snackbar_include = 2130903138;
|
||||
|
||||
// aapt resource value: 0x7f030063
|
||||
public const int NoSong = 2130903139;
|
||||
public const int MusicLayout = 2130903139;
|
||||
|
||||
// aapt resource value: 0x7f030064
|
||||
public const int notification_action = 2130903140;
|
||||
public const int NoSong = 2130903140;
|
||||
|
||||
// aapt resource value: 0x7f030065
|
||||
public const int notification_action_tombstone = 2130903141;
|
||||
public const int notification_action = 2130903141;
|
||||
|
||||
// aapt resource value: 0x7f030066
|
||||
public const int notification_media_action = 2130903142;
|
||||
public const int notification_action_tombstone = 2130903142;
|
||||
|
||||
// aapt resource value: 0x7f030067
|
||||
public const int notification_media_cancel_action = 2130903143;
|
||||
public const int notification_media_action = 2130903143;
|
||||
|
||||
// aapt resource value: 0x7f030068
|
||||
public const int notification_template_big_media = 2130903144;
|
||||
public const int notification_media_cancel_action = 2130903144;
|
||||
|
||||
// aapt resource value: 0x7f030069
|
||||
public const int notification_template_big_media_custom = 2130903145;
|
||||
public const int notification_template_big_media = 2130903145;
|
||||
|
||||
// aapt resource value: 0x7f03006a
|
||||
public const int notification_template_big_media_narrow = 2130903146;
|
||||
public const int notification_template_big_media_custom = 2130903146;
|
||||
|
||||
// aapt resource value: 0x7f03006b
|
||||
public const int notification_template_big_media_narrow_custom = 2130903147;
|
||||
public const int notification_template_big_media_narrow = 2130903147;
|
||||
|
||||
// aapt resource value: 0x7f03006c
|
||||
public const int notification_template_custom_big = 2130903148;
|
||||
public const int notification_template_big_media_narrow_custom = 2130903148;
|
||||
|
||||
// aapt resource value: 0x7f03006d
|
||||
public const int notification_template_icon_group = 2130903149;
|
||||
public const int notification_template_custom_big = 2130903149;
|
||||
|
||||
// aapt resource value: 0x7f03006e
|
||||
public const int notification_template_lines_media = 2130903150;
|
||||
public const int notification_template_icon_group = 2130903150;
|
||||
|
||||
// aapt resource value: 0x7f03006f
|
||||
public const int notification_template_media = 2130903151;
|
||||
public const int notification_template_lines_media = 2130903151;
|
||||
|
||||
// aapt resource value: 0x7f030070
|
||||
public const int notification_template_media_custom = 2130903152;
|
||||
public const int notification_template_media = 2130903152;
|
||||
|
||||
// aapt resource value: 0x7f030071
|
||||
public const int notification_template_part_chronometer = 2130903153;
|
||||
public const int notification_template_media_custom = 2130903153;
|
||||
|
||||
// aapt resource value: 0x7f030072
|
||||
public const int notification_template_part_time = 2130903154;
|
||||
public const int notification_template_part_chronometer = 2130903154;
|
||||
|
||||
// aapt resource value: 0x7f030073
|
||||
public const int NoYtPlaylist = 2130903155;
|
||||
public const int notification_template_part_time = 2130903155;
|
||||
|
||||
// aapt resource value: 0x7f030074
|
||||
public const int NumberPicker = 2130903156;
|
||||
public const int NoYtPlaylist = 2130903156;
|
||||
|
||||
// aapt resource value: 0x7f030075
|
||||
public const int player = 2130903157;
|
||||
public const int NumberPicker = 2130903157;
|
||||
|
||||
// aapt resource value: 0x7f030076
|
||||
public const int playerInfo = 2130903158;
|
||||
public const int player = 2130903158;
|
||||
|
||||
// aapt resource value: 0x7f030077
|
||||
public const int PlaylistHeader = 2130903159;
|
||||
public const int playerInfo = 2130903159;
|
||||
|
||||
// aapt resource value: 0x7f030078
|
||||
public const int PlaylistItem = 2130903160;
|
||||
public const int PlaylistHeader = 2130903160;
|
||||
|
||||
// aapt resource value: 0x7f030079
|
||||
public const int PlaylistList = 2130903161;
|
||||
public const int PlaylistItem = 2130903161;
|
||||
|
||||
// aapt resource value: 0x7f03007a
|
||||
public const int PlaylistSmallHeader = 2130903162;
|
||||
public const int PlaylistList = 2130903162;
|
||||
|
||||
// aapt resource value: 0x7f03007b
|
||||
public const int preference = 2130903163;
|
||||
public const int PlaylistSmallHeader = 2130903163;
|
||||
|
||||
// aapt resource value: 0x7f03007c
|
||||
public const int preference_category = 2130903164;
|
||||
public const int preference = 2130903164;
|
||||
|
||||
// aapt resource value: 0x7f03007d
|
||||
public const int preference_category_material = 2130903165;
|
||||
public const int preference_category = 2130903165;
|
||||
|
||||
// aapt resource value: 0x7f03007e
|
||||
public const int preference_dialog_edittext = 2130903166;
|
||||
public const int preference_category_material = 2130903166;
|
||||
|
||||
// aapt resource value: 0x7f03007f
|
||||
public const int preference_dropdown = 2130903167;
|
||||
public const int preference_dialog_edittext = 2130903167;
|
||||
|
||||
// aapt resource value: 0x7f030080
|
||||
public const int preference_dropdown_material = 2130903168;
|
||||
public const int preference_dropdown = 2130903168;
|
||||
|
||||
// aapt resource value: 0x7f030081
|
||||
public const int preference_information = 2130903169;
|
||||
public const int preference_dropdown_material = 2130903169;
|
||||
|
||||
// aapt resource value: 0x7f030082
|
||||
public const int preference_information_material = 2130903170;
|
||||
public const int preference_information = 2130903170;
|
||||
|
||||
// aapt resource value: 0x7f030083
|
||||
public const int preference_list_fragment = 2130903171;
|
||||
public const int preference_information_material = 2130903171;
|
||||
|
||||
// aapt resource value: 0x7f030084
|
||||
public const int preference_material = 2130903172;
|
||||
public const int preference_list_fragment = 2130903172;
|
||||
|
||||
// aapt resource value: 0x7f030085
|
||||
public const int preference_recyclerview = 2130903173;
|
||||
public const int preference_material = 2130903173;
|
||||
|
||||
// aapt resource value: 0x7f030086
|
||||
public const int preference_widget_checkbox = 2130903174;
|
||||
public const int preference_recyclerview = 2130903174;
|
||||
|
||||
// aapt resource value: 0x7f030087
|
||||
public const int preference_widget_seekbar = 2130903175;
|
||||
public const int preference_widget_checkbox = 2130903175;
|
||||
|
||||
// aapt resource value: 0x7f030088
|
||||
public const int preference_widget_seekbar_material = 2130903176;
|
||||
public const int preference_widget_seekbar = 2130903176;
|
||||
|
||||
// aapt resource value: 0x7f030089
|
||||
public const int preference_widget_switch = 2130903177;
|
||||
public const int preference_widget_seekbar_material = 2130903177;
|
||||
|
||||
// aapt resource value: 0x7f03008a
|
||||
public const int preference_widget_switch_compat = 2130903178;
|
||||
public const int preference_widget_switch = 2130903178;
|
||||
|
||||
// aapt resource value: 0x7f03008b
|
||||
public const int PreferenceCategory = 2130903179;
|
||||
public const int preference_widget_switch_compat = 2130903179;
|
||||
|
||||
// aapt resource value: 0x7f03008c
|
||||
public const int PreferenceRoot = 2130903180;
|
||||
public const int PreferenceCategory = 2130903180;
|
||||
|
||||
// aapt resource value: 0x7f03008d
|
||||
public const int Preferences = 2130903181;
|
||||
public const int PreferenceRoot = 2130903181;
|
||||
|
||||
// aapt resource value: 0x7f03008e
|
||||
public const int QueueFooter = 2130903182;
|
||||
public const int Preferences = 2130903182;
|
||||
|
||||
// aapt resource value: 0x7f03008f
|
||||
public const int RecyclerFragment = 2130903183;
|
||||
public const int QueueCurrent = 2130903183;
|
||||
|
||||
// aapt resource value: 0x7f030090
|
||||
public const int SaveAPlaylist = 2130903184;
|
||||
public const int QueueFooter = 2130903184;
|
||||
|
||||
// aapt resource value: 0x7f030091
|
||||
public const int search_layout = 2130903185;
|
||||
public const int RecyclerFragment = 2130903185;
|
||||
|
||||
// aapt resource value: 0x7f030092
|
||||
public const int SearchLayout = 2130903186;
|
||||
public const int SaveAPlaylist = 2130903186;
|
||||
|
||||
// aapt resource value: 0x7f030093
|
||||
public const int SeekbarPreference = 2130903187;
|
||||
public const int search_layout = 2130903187;
|
||||
|
||||
// aapt resource value: 0x7f030094
|
||||
public const int select_dialog_item_material = 2130903188;
|
||||
public const int SearchLayout = 2130903188;
|
||||
|
||||
// aapt resource value: 0x7f030095
|
||||
public const int select_dialog_multichoice_material = 2130903189;
|
||||
public const int SeekbarPreference = 2130903189;
|
||||
|
||||
// aapt resource value: 0x7f030096
|
||||
public const int select_dialog_singlechoice_material = 2130903190;
|
||||
public const int select_dialog_item_material = 2130903190;
|
||||
|
||||
// aapt resource value: 0x7f030097
|
||||
public const int SmallEmptyView = 2130903191;
|
||||
public const int select_dialog_multichoice_material = 2130903191;
|
||||
|
||||
// aapt resource value: 0x7f030098
|
||||
public const int smallLoading = 2130903192;
|
||||
public const int select_dialog_singlechoice_material = 2130903192;
|
||||
|
||||
// aapt resource value: 0x7f030099
|
||||
public const int SongList = 2130903193;
|
||||
public const int SmallEmptyView = 2130903193;
|
||||
|
||||
// aapt resource value: 0x7f03009a
|
||||
public const int SuggestionLayout = 2130903194;
|
||||
public const int smallLoading = 2130903194;
|
||||
|
||||
// aapt resource value: 0x7f03009b
|
||||
public const int support_simple_spinner_dropdown_item = 2130903195;
|
||||
public const int SongList = 2130903195;
|
||||
|
||||
// aapt resource value: 0x7f03009c
|
||||
public const int tabs = 2130903196;
|
||||
public const int SuggestionLayout = 2130903196;
|
||||
|
||||
// aapt resource value: 0x7f03009d
|
||||
public const int TimerLayout = 2130903197;
|
||||
public const int support_simple_spinner_dropdown_item = 2130903197;
|
||||
|
||||
// aapt resource value: 0x7f03009e
|
||||
public const int TwoLineLayout = 2130903198;
|
||||
public const int tabs = 2130903198;
|
||||
|
||||
// aapt resource value: 0x7f03009f
|
||||
public const int ViewPager = 2130903199;
|
||||
public const int TimerLayout = 2130903199;
|
||||
|
||||
// aapt resource value: 0x7f0300a0
|
||||
public const int YtList = 2130903200;
|
||||
public const int TwoLineLayout = 2130903200;
|
||||
|
||||
// aapt resource value: 0x7f0300a1
|
||||
public const int ViewPager = 2130903201;
|
||||
|
||||
// aapt resource value: 0x7f0300a2
|
||||
public const int YtList = 2130903202;
|
||||
|
||||
static Layout()
|
||||
{
|
||||
|
||||
5
MusicApp/Resources/layout/Empty.xml
Normal file
5
MusicApp/Resources/layout/Empty.xml
Normal file
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<View
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1px" />
|
||||
106
MusicApp/Resources/layout/QueueCurrent.xml
Normal file
106
MusicApp/Resources/layout/QueueCurrent.xml
Normal file
@@ -0,0 +1,106 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical" >
|
||||
<View
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="1dp"
|
||||
android:background="#ffffff"
|
||||
android:layout_marginStart="3dp"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:id="@+id/topDivider" />
|
||||
<RelativeLayout
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="78dp"
|
||||
android:id="@+id/songView" >
|
||||
<ImageView
|
||||
android:id="@+id/albumArt"
|
||||
android:layout_width="70dp"
|
||||
android:layout_height="70dp"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:paddingLeft="8dp"
|
||||
android:padding="5dp"
|
||||
android:src="@drawable/MusicIcon" />
|
||||
<LinearLayout
|
||||
android:orientation="vertical"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="78dp"
|
||||
android:gravity="center_vertical"
|
||||
android:paddingLeft="10dp"
|
||||
android:id="@+id/textLayout"
|
||||
android:layout_toRightOf="@id/albumArt"
|
||||
android:layout_toLeftOf="@+id/rightButtons" >
|
||||
<TextView
|
||||
android:id="@+id/title"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="fill_parent"
|
||||
android:gravity="center_vertical"
|
||||
android:textSize="14dip"
|
||||
android:textColor="#ffffff"
|
||||
android:ellipsize="end"
|
||||
android:maxLines="2"
|
||||
android:textStyle="bold" />
|
||||
<TextView
|
||||
android:id="@+id/isLive"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:visibility="gone"
|
||||
android:text="LIVE"
|
||||
android:textSize="14dip"
|
||||
android:textStyle="bold"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:paddingBottom="7dp"
|
||||
android:gravity="bottom"
|
||||
android:textColor="#ff0000" />
|
||||
</LinearLayout>
|
||||
<TextView
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:textSize="11dp"
|
||||
android:id="@id/status"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:gravity="right"
|
||||
android:textColor="#f4511e"
|
||||
android:paddingRight="20dp"
|
||||
android:paddingBottom="10dp" />
|
||||
<LinearLayout
|
||||
android:orientation="horizontal"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:id="@+id/rightButtons">
|
||||
<ImageView
|
||||
android:id="@+id/youtubeIcon"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
android:padding="5dp"
|
||||
android:background="@null"
|
||||
android:src="@drawable/PublicIcon"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:visibility="visible" />
|
||||
<ImageView
|
||||
android:id="@+id/moreButton"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="70dp"
|
||||
android:paddingLeft="5dp"
|
||||
android:paddingRight="5dp"
|
||||
android:paddingTop="25dp"
|
||||
android:paddingBottom="25dp"
|
||||
android:clickable="true"
|
||||
android:background="@null"
|
||||
android:src="@drawable/More"
|
||||
android:gravity="center_vertical" />
|
||||
</LinearLayout>
|
||||
</RelativeLayout>
|
||||
<View
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="1dp"
|
||||
android:background="#ffffff"
|
||||
android:layout_marginStart="3dp"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:id="@+id/bottomDivider" />
|
||||
</LinearLayout>
|
||||
Reference in New Issue
Block a user