From e19cc141c388c7190a1582f0ee72c9ba67569a2d Mon Sep 17 00:00:00 2001 From: Jason Monk Date: Wed, 1 Jun 2016 10:25:01 -0400 Subject: [PATCH] QS: Protect against crash with no icon Change-Id: I65d594c9bf15190418d96cc6d2c426df00fed212 Fixes: 28941131 --- packages/SystemUI/src/com/android/systemui/qs/QSIconView.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSIconView.java b/packages/SystemUI/src/com/android/systemui/qs/QSIconView.java index 6c224f70f42f8..9c4a1498e9e58 100644 --- a/packages/SystemUI/src/com/android/systemui/qs/QSIconView.java +++ b/packages/SystemUI/src/com/android/systemui/qs/QSIconView.java @@ -80,7 +80,7 @@ public class QSIconView extends ViewGroup { Drawable d = state.icon != null ? iv.isShown() && mAnimationEnabled ? state.icon.getDrawable(mContext) : state.icon.getInvisibleDrawable(mContext) : null; - int padding = state.icon != null ? state.icon.getPadding() : null; + int padding = state.icon != null ? state.icon.getPadding() : 0; if (d != null && state.autoMirrorDrawable) { d.setAutoMirrored(true); }