OSDN Git Service

Fixed an issue where we would access the wrong drawable
authorSelim Cinek <cinek@google.com>
Tue, 6 Feb 2018 23:24:25 +0000 (15:24 -0800)
committerSelim Cinek <cinek@google.com>
Tue, 6 Feb 2018 23:24:25 +0000 (15:24 -0800)
Quick follow up fix the inline images

Test: add notification with image
Change-Id: I21c149b0cd63bc93895eee34be5e68d3caef0298

core/java/com/android/internal/widget/MessagingImageMessage.java

index d5ebf9c..961f90a 100644 (file)
@@ -101,7 +101,7 @@ public class MessagingImageMessage extends ImageView implements MessagingMessage
             e.printStackTrace();
             return false;
         }
-        int intrinsicHeight = mDrawable.getIntrinsicHeight();
+        int intrinsicHeight = drawable.getIntrinsicHeight();
         if (intrinsicHeight == 0) {
             Log.w(TAG, "Drawable with 0 intrinsic height was returned");
             return false;