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

Commit 5af44736 authored by Fabrice Di Meglio's avatar Fabrice Di Meglio Committed by Android (Google) Code Review
Browse files

Merge "Fix bug #5387832 [UI/Visual] Address of the website is not displayed...

Merge "Fix bug #5387832 [UI/Visual] Address of the website is not displayed properly(second line of the address is partly shown)"
parents ea427b0c caa8c06d
Loading
Loading
Loading
Loading
+7 −5
Original line number Diff line number Diff line
@@ -6095,13 +6095,18 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
        int physicalWidth = width;

        if (mHorizontallyScrolling) {
            width = VERY_WIDE;
            width = getTextWidth();
        }

        makeNewLayout(width, physicalWidth, UNKNOWN_BORING, UNKNOWN_BORING,
                      physicalWidth, false);
    }

    private int getTextWidth() {
        final int length = mText.length();
        return (length == 0) ? 0 : (int) (getPaint().measureText(mText, 0, length) + 0.5f);
    }

    @Override
    protected void resetResolvedLayoutDirection() {
        super.resetResolvedLayoutDirection();
@@ -6547,7 +6552,7 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
        int want = width - getCompoundPaddingLeft() - getCompoundPaddingRight();
        int unpaddedWidth = want;

        if (mHorizontallyScrolling) want = VERY_WIDE;
        if (mHorizontallyScrolling) want = getTextWidth();

        int hintWant = want;
        int hintWidth = (mHintLayout == null) ? hintWant : mHintLayout.getWidth();
@@ -11530,9 +11535,6 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
    private boolean                 mHighlightPathBogus = true;
    private static final RectF      sTempRect = new RectF();

    // XXX should be much larger
    private static final int        VERY_WIDE = 1024*1024;

    private static final int        BLINK = 500;

    private static final int ANIMATED_SCROLL_GAP = 250;