Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a6cd4e03 authored by Romain Guy's avatar Romain Guy
Browse files

Fix NPE at boot.

parent fe0daa7d
Loading
Loading
Loading
Loading
+30 −28
Original line number Diff line number Diff line
@@ -3711,6 +3711,7 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
            // for each compound drawable in onDraw(). Make sure to update each section
            // accordingly.
            final TextView.Drawables drawables = mDrawables;
            if (drawables != null) {
                if (drawable == drawables.mDrawableLeft) {
                    final int compoundPaddingTop = getCompoundPaddingTop();
                    final int compoundPaddingBottom = getCompoundPaddingBottom();
@@ -3740,6 +3741,7 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
                    scrollX += compoundPaddingLeft + (hspace - drawables.mDrawableWidthBottom) / 2;
                    scrollY += (mBottom - mTop - mPaddingBottom - drawables.mDrawableSizeBottom);
                }
            }

            invalidate(dirty.left + scrollX, dirty.top + scrollY,
                    dirty.right + scrollX, dirty.bottom + scrollY);