aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorScott Jackson <daneren2005@gmail.com>2013-06-12 21:32:30 -0700
committerScott Jackson <daneren2005@gmail.com>2013-06-12 21:32:30 -0700
commit3948efaa61af0a749101e5590205717e33c2904a (patch)
treee2808d12d180cca3e07113f6af0c6f29e6b30f41
parentb8a35fa41c8fef49046efe385a3755df9e843e20 (diff)
downloaddsub-3948efaa61af0a749101e5590205717e33c2904a.tar.gz
dsub-3948efaa61af0a749101e5590205717e33c2904a.tar.bz2
dsub-3948efaa61af0a749101e5590205717e33c2904a.zip
Fix low quality album art with larger widgets
-rw-r--r--subsonic-android/src/github/daneren2005/dsub/provider/DSubWidgetProvider.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/subsonic-android/src/github/daneren2005/dsub/provider/DSubWidgetProvider.java b/subsonic-android/src/github/daneren2005/dsub/provider/DSubWidgetProvider.java
index 321b0f88..7215040c 100644
--- a/subsonic-android/src/github/daneren2005/dsub/provider/DSubWidgetProvider.java
+++ b/subsonic-android/src/github/daneren2005/dsub/provider/DSubWidgetProvider.java
@@ -186,7 +186,12 @@ public class DSubWidgetProvider extends AppWidgetProvider {
// Set the cover art
try {
- int size = context.getResources().getDrawable(R.drawable.appwidget_art_default).getIntrinsicHeight();
+ int size;
+ if(getLayout() != R.layout.appwidget4x1 && getLayout() != R.layout.appwidget4x2) {
+ size = context.getResources().getDrawable(R.drawable.unknown_album_large).getIntrinsicHeight();
+ } else {
+ size = context.getResources().getDrawable(R.drawable.appwidget_art_default).getIntrinsicHeight();
+ }
Bitmap bitmap = currentPlaying == null ? null : FileUtil.getAlbumArtBitmap(context, currentPlaying, size);
if (bitmap == null) {