From a93b1854cfb3b7500e57fe5432f57903623bf696 Mon Sep 17 00:00:00 2001 From: likaid Date: Wed, 2 Sep 2015 17:15:22 +0800 Subject: SnapdragonCamera: Fix the preview thumbnail issue When set the preview thumbnail imageView to visible, it used the drawable resource in cache which was set since last time. That caused we still could see the preview thumbnail though the bitmap was invalid. Clear the drawable resource in cache when the preview thumbnail is invalid. Change-Id: Id37620d32b8dff8dd3cad0f33da678b8709e6ee1 CRs-Fixed: 899905 --- src/com/android/camera/CameraActivity.java | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/com/android/camera/CameraActivity.java b/src/com/android/camera/CameraActivity.java index fbdb38f5b..0064a0e25 100644 --- a/src/com/android/camera/CameraActivity.java +++ b/src/com/android/camera/CameraActivity.java @@ -813,6 +813,8 @@ public class CameraActivity extends Activity protected void onPostExecute(Bitmap bitmap) { if (bitmap == null) { if (mThumbnail != null) { + // Clear the image resource when the bitmap is invalid. + mThumbnail.setImageDrawable(null); mThumbnail.setVisibility(View.GONE); } } else { -- cgit v1.2.3