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

Commit cd45913f authored by Adam Powell's avatar Adam Powell Committed by Android (Google) Code Review
Browse files

Merge "Fix view foreground tinting" into mnc-dev

parents 597059d5 cec5f733
Loading
Loading
Loading
Loading
+9 −6
Original line number Diff line number Diff line
@@ -17564,13 +17564,16 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
     * @see Drawable#setTintMode(PorterDuff.Mode)
     */
    public void setForegroundTintMode(@Nullable PorterDuff.Mode tintMode) {
        if (mBackgroundTint == null) {
            mBackgroundTint = new TintInfo();
        if (mForegroundInfo == null) {
            mForegroundInfo = new ForegroundInfo();
        }
        mBackgroundTint.mTintMode = tintMode;
        mBackgroundTint.mHasTintMode = true;
        if (mForegroundInfo.mTintInfo == null) {
            mForegroundInfo.mTintInfo = new TintInfo();
        }
        mForegroundInfo.mTintInfo.mTintMode = tintMode;
        mForegroundInfo.mTintInfo.mHasTintMode = true;
        applyBackgroundTint();
        applyForegroundTint();
    }
    /**
@@ -17580,7 +17583,7 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
     * @return the blending mode used to apply the tint to the foreground
     *         drawable
     * @attr ref android.R.styleable#View_foregroundTintMode
     * @see #setBackgroundTintMode(PorterDuff.Mode)
     * @see #setForegroundTintMode(PorterDuff.Mode)
     */
    @Nullable
    public PorterDuff.Mode getForegroundTintMode() {