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

Commit ded80508 authored by Alan Viverette's avatar Alan Viverette Committed by android-build-merger
Browse files

Merge "Ensure nine-patch uses the best available target density" into nyc-dev

am: 7899d4d7

* commit '7899d4d7':
  Ensure nine-patch uses the best available target density
parents 9b5b5e1c 7899d4d7
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -748,7 +748,14 @@ public class NinePatchDrawable extends Drawable {
            setDither(state.mDither);
        }

        // The nine-patch may have been created without a Resources object, in
        // which case we should try to match the density of the nine patch (if
        // available).
        if (res == null && state.mNinePatch != null) {
            mTargetDensity = state.mNinePatch.getDensity();
        } else {
            mTargetDensity = Drawable.resolveDensity(res, mTargetDensity);
        }
        mTintFilter = updateTintFilter(mTintFilter, state.mTint, state.mTintMode);
        computeBitmapSize();
    }