From 23c61dd30cd2f4a96ab2b01a5878badc79380c6a Mon Sep 17 00:00:00 2001 From: John Reck Date: Wed, 28 Sep 2011 15:02:24 -0700 Subject: Update folder asset usage Bug: 5066431 Change-Id: Icc4ea38e64881d0f67d3cbbd0b6bda7138f4a0b4 --- src/com/android/browser/BrowserBookmarksAdapter.java | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/com/android/browser/BrowserBookmarksAdapter.java') diff --git a/src/com/android/browser/BrowserBookmarksAdapter.java b/src/com/android/browser/BrowserBookmarksAdapter.java index b3f8d98..2fd880c 100644 --- a/src/com/android/browser/BrowserBookmarksAdapter.java +++ b/src/com/android/browser/BrowserBookmarksAdapter.java @@ -25,6 +25,7 @@ import android.view.View; import android.view.ViewGroup; import android.widget.CursorAdapter; import android.widget.ImageView; +import android.widget.ImageView.ScaleType; import android.widget.TextView; public class BrowserBookmarksAdapter extends CursorAdapter { @@ -65,6 +66,7 @@ public class BrowserBookmarksAdapter extends CursorAdapter { if (cursor.getInt(BookmarksLoader.COLUMN_INDEX_IS_FOLDER) != 0) { // folder thumb.setImageResource(R.drawable.thumb_bookmark_widget_folder_holo); + thumb.setScaleType(ScaleType.FIT_END); thumb.setBackgroundDrawable(null); } else { byte[] thumbData = cursor.getBlob(BookmarksLoader.COLUMN_INDEX_THUMBNAIL); @@ -73,6 +75,7 @@ public class BrowserBookmarksAdapter extends CursorAdapter { thumbBitmap = BitmapFactory.decodeByteArray(thumbData, 0, thumbData.length); } + thumb.setScaleType(ScaleType.CENTER_CROP); if (thumbBitmap == null) { thumb.setImageResource(R.drawable.browser_thumbnail); } else { -- cgit v1.1