mirror of
https://github.com/zoriya/Opus.git
synced 2025-12-06 06:26:15 +00:00
Adding dark background on the buttons of the queue and changing the padding.
This commit is contained in:
@@ -252,6 +252,8 @@ namespace Opus.Resources.Portable_Class
|
||||
|
||||
queue?.Clear();
|
||||
currentID = -1;
|
||||
Queue.instance?.Refresh();
|
||||
Home.instance?.RefreshQueue();
|
||||
|
||||
Song song = null;
|
||||
if (title == null)
|
||||
|
||||
@@ -123,6 +123,9 @@ namespace Opus.Resources.Portable_Class
|
||||
holder.youtubeIcon.SetColorFilter(Color.White);
|
||||
holder.reorder.Visibility = ViewStates.Visible;
|
||||
holder.more.Visibility = ViewStates.Gone;
|
||||
holder.RightButtons.SetBackgroundResource(Resource.Drawable.darkLinear);
|
||||
((RelativeLayout.LayoutParams)holder.RightButtons.LayoutParameters).RightMargin = MainActivity.instance.DpToPx(5);
|
||||
holder.TextLayout.SetPadding(5, 0, 5, 0);
|
||||
if (position == MusicPlayer.CurrentID())
|
||||
{
|
||||
holder.status.Visibility = ViewStates.Visible;
|
||||
@@ -375,8 +378,6 @@ namespace Opus.Resources.Portable_Class
|
||||
fromPosition--;
|
||||
toPosition--;
|
||||
|
||||
Console.WriteLine("&From: " + fromPosition + " To: " + toPosition + " CurrentID:" + MusicPlayer.CurrentID());
|
||||
|
||||
if (MusicPlayer.CurrentID() > fromPosition && MusicPlayer.CurrentID() <= toPosition)
|
||||
MusicPlayer.currentID--;
|
||||
|
||||
@@ -386,8 +387,6 @@ namespace Opus.Resources.Portable_Class
|
||||
else if (MusicPlayer.CurrentID() == fromPosition)
|
||||
MusicPlayer.currentID = toPosition;
|
||||
|
||||
Console.WriteLine("&Updated! From: " + fromPosition + " To: " + toPosition + " CurrentID:" + MusicPlayer.CurrentID());
|
||||
|
||||
if (MusicPlayer.UseCastPlayer)
|
||||
{
|
||||
int nextItemID = MusicPlayer.RemotePlayer.MediaQueue.ItemCount > toPosition ? MusicPlayer.RemotePlayer.MediaQueue.ItemIdAtIndex(toPosition + 1) : 0; //0 = InvalidItemID = end of the queue
|
||||
|
||||
@@ -16,8 +16,9 @@ namespace Opus.Resources.Portable_Class
|
||||
public ImageView youtubeIcon;
|
||||
public ImageView more;
|
||||
public TextView status;
|
||||
public CheckBox checkBox;
|
||||
public Button action;
|
||||
public View RightButtons;
|
||||
public View TextLayout;
|
||||
|
||||
public RecyclerHolder(View itemView, Action<int> listener, Action<int> longListener) : base(itemView)
|
||||
{
|
||||
@@ -28,8 +29,9 @@ namespace Opus.Resources.Portable_Class
|
||||
AlbumArt = itemView.FindViewById<ImageView>(Resource.Id.albumArt);
|
||||
youtubeIcon = itemView.FindViewById<ImageView>(Resource.Id.youtubeIcon);
|
||||
more = itemView.FindViewById<ImageView>(Resource.Id.moreButton);
|
||||
RightButtons = itemView.FindViewById(Resource.Id.rightButtons);
|
||||
TextLayout = itemView.FindViewById(Resource.Id.textLayout);
|
||||
status = itemView.FindViewById<TextView>(Resource.Id.status);
|
||||
checkBox = itemView.FindViewById<CheckBox>(Resource.Id.checkBox);
|
||||
action = itemView.FindViewById<Button>(Resource.Id.action);
|
||||
|
||||
itemView.Click += (sender, e) => listener(AdapterPosition);
|
||||
|
||||
@@ -29,7 +29,8 @@
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="78dp"
|
||||
android:gravity="center_vertical"
|
||||
android:paddingLeft="10dp"
|
||||
android:paddingLeft="5dp"
|
||||
android:paddingRight="5dp"
|
||||
android:id="@+id/textLayout"
|
||||
android:layout_toRightOf="@id/albumArt"
|
||||
android:layout_toLeftOf="@+id/rightButtons" >
|
||||
@@ -72,6 +73,8 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:background="@drawable/darkLinear"
|
||||
android:layout_marginRight="5dp"
|
||||
android:id="@+id/rightButtons">
|
||||
<ImageView
|
||||
android:id="@+id/youtubeIcon"
|
||||
@@ -85,11 +88,8 @@
|
||||
<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:layout_height="30dp"
|
||||
android:padding="5dp"
|
||||
android:clickable="true"
|
||||
android:background="@null"
|
||||
android:src="@drawable/More"
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
<ImageView
|
||||
android:id="@+id/reorder"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_height="30dp"
|
||||
android:padding="5dp"
|
||||
android:clickable="true"
|
||||
android:visibility="gone"
|
||||
@@ -89,11 +89,8 @@
|
||||
<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:layout_height="30dp"
|
||||
android:padding="5dp"
|
||||
android:clickable="true"
|
||||
android:background="@null"
|
||||
android:src="@drawable/More"
|
||||
|
||||
Reference in New Issue
Block a user