Commit 167b53d7 authored by Geoffrey Métais's avatar Geoffrey Métais
Browse files

Shuffle option only for 3+ songs playlists

parent 2ea98b8d
...@@ -249,6 +249,7 @@ public class AudioPlayer extends Fragment implements IAudioPlayer { ...@@ -249,6 +249,7 @@ public class AudioPlayer extends Fragment implements IAudioPlayer {
@Override @Override
public void onItemRemoved(int position) { public void onItemRemoved(int position) {
mAudioController.remove(position); mAudioController.remove(position);
update();
} }
}); });
registerForContextMenu(mSongsList); registerForContextMenu(mSongsList);
...@@ -352,6 +353,8 @@ public class AudioPlayer extends Fragment implements IAudioPlayer { ...@@ -352,6 +353,8 @@ public class AudioPlayer extends Fragment implements IAudioPlayer {
mRepeat.setImageResource(Util.getResourceFromAttribute(act, R.attr.ic_repeat_pressed)); mRepeat.setImageResource(Util.getResourceFromAttribute(act, R.attr.ic_repeat_pressed));
break; break;
} }
mShuffle.setVisibility(mSongsListAdapter.getCount() > 2 ? View.VISIBLE : View.INVISIBLE);
if (mAudioController.hasNext()) if (mAudioController.hasNext())
mNext.setVisibility(ImageButton.VISIBLE); mNext.setVisibility(ImageButton.VISIBLE);
else else
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment