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

Commit 5ce80a03 authored by Siyamed Sinir's avatar Siyamed Sinir Committed by android-build-merger
Browse files

Merge "Request re-layout after setText if layout width is 0" into nyc-dev

am: d01e6f90

* commit 'd01e6f90':
  Request re-layout after setText if layout width is 0

Change-Id: Ia2ad9975ecbc3ebf2b468f515fcbf82a9bc4bb2d
parents f5b74b07 d01e6f90
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -7310,7 +7310,7 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
        // If we have a fixed width, we can just swap in a new text layout
        // If we have a fixed width, we can just swap in a new text layout
        // if the text height stays the same or if the view height is fixed.
        // if the text height stays the same or if the view height is fixed.


        if ((mLayoutParams.width != LayoutParams.WRAP_CONTENT ||
        if (((mLayoutParams.width != LayoutParams.WRAP_CONTENT && mLayoutParams.width != 0) ||
                (mMaxWidthMode == mMinWidthMode && mMaxWidth == mMinWidth)) &&
                (mMaxWidthMode == mMinWidthMode && mMaxWidth == mMinWidth)) &&
                (mHint == null || mHintLayout != null) &&
                (mHint == null || mHintLayout != null) &&
                (mRight - mLeft - getCompoundPaddingLeft() - getCompoundPaddingRight() > 0)) {
                (mRight - mLeft - getCompoundPaddingLeft() - getCompoundPaddingRight() > 0)) {