aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--subsonic-android/src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java2
-rw-r--r--subsonic-android/src/github/daneren2005/dsub/fragments/SubsonicFragment.java2
2 files changed, 3 insertions, 1 deletions
diff --git a/subsonic-android/src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java b/subsonic-android/src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java
index 63c41546..192f5ea0 100644
--- a/subsonic-android/src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java
+++ b/subsonic-android/src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java
@@ -623,7 +623,7 @@ public class SelectDirectoryFragment extends SubsonicFragment implements Adapter
View header = LayoutInflater.from(context).inflate(R.layout.select_album_header, entryList, false);
View coverArtView = header.findViewById(R.id.select_album_art);
- getImageLoader().loadImage(coverArtView, entries.get(0), true, true);
+ getImageLoader().loadImage(coverArtView, entries.get(random.nextInt(entries.size())), true, true);
TextView titleView = (TextView) header.findViewById(R.id.select_album_title);
if(playlistName != null) {
diff --git a/subsonic-android/src/github/daneren2005/dsub/fragments/SubsonicFragment.java b/subsonic-android/src/github/daneren2005/dsub/fragments/SubsonicFragment.java
index 1284a99a..46e4f8c4 100644
--- a/subsonic-android/src/github/daneren2005/dsub/fragments/SubsonicFragment.java
+++ b/subsonic-android/src/github/daneren2005/dsub/fragments/SubsonicFragment.java
@@ -67,6 +67,7 @@ import java.util.ArrayList;
import java.util.Arrays;
import java.util.LinkedList;
import java.util.List;
+import java.util.Random;
public class SubsonicFragment extends SherlockFragment {
private static final String TAG = SubsonicFragment.class.getSimpleName();
@@ -75,6 +76,7 @@ public class SubsonicFragment extends SherlockFragment {
protected View rootView;
protected boolean primaryFragment = false;
protected boolean invalidated = false;
+ protected static Random random = new Random();
@Override
public void onCreate(Bundle bundle) {