package defpackage;

import android.content.res.ColorStateList;
import android.content.res.Resources;
import android.content.res.TypedArray;
import android.content.res.XmlResourceParser;
import android.graphics.Paint;
import android.os.Build;
import android.text.TextDirectionHeuristic;
import android.text.TextDirectionHeuristics;
import android.text.TextPaint;
import android.text.method.PasswordTransformationMethod;
import android.util.Base64;
import android.util.Xml;
import android.view.ActionMode;
import android.widget.TextView;
import java.io.IOException;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
import java.util.concurrent.TimeUnit;
import org.xmlpull.v1.XmlPullParser;
import org.xmlpull.v1.XmlPullParserException;

/* renamed from: ˀʒˎʿ, reason: contains not printable characters */
/* loaded from: classes3.dex */
public abstract class AbstractC0494 {

    /* renamed from: ˎˏʜʾ, reason: contains not printable characters */
    public static ᵺᐧʝ f2609;

    /* renamed from: ˏˋٴ, reason: contains not printable characters */
    public static volatile boolean f2610;

    /* renamed from: ᵥᵯˎ, reason: contains not printable characters */
    public static C4957 f2612;

    /* renamed from: ᵴᵳ, reason: contains not printable characters */
    public static boolean f2613;

    /* renamed from: ᵻᵢﹳᵰ, reason: contains not printable characters */
    public static volatile boolean f2614;

    /* renamed from: ˏᵙ, reason: contains not printable characters */
    public static final String[] f2611 = {"standard", "accelerate", "decelerate", "linear"};

    /* renamed from: ˇʼʤˎ, reason: contains not printable characters */
    public static final ᵡᵗᵪ f2608 = new ᵡᵗᵪ(1, 2, 27);

    /* renamed from: ˀᵗᵝᵭ, reason: contains not printable characters */
    public static ActionMode.Callback m2142(ActionMode.Callback callback) {
        return (!(callback instanceof ActionModeCallbackC4238) || Build.VERSION.SDK_INT < 26) ? callback : ((ActionModeCallbackC4238) callback).f15875;
    }

    /* renamed from: ˇʼʤˎ, reason: contains not printable characters */
    public static byte[] m2143(byte[] bArr) {
        if (bArr.length != 16) {
            ᵹˉᵞ.ˌᵜᵹᵩ("value must be a block.");
            return null;
        }
        byte[] bArr2 = new byte[16];
        for (int i = 0; i < 16; i++) {
            byte b = (byte) ((bArr[i] << 1) & 254);
            bArr2[i] = b;
            if (i < 15) {
                bArr2[i] = (byte) (((byte) ((bArr[i + 1] >> 7) & 1)) | b);
            }
        }
        bArr2[15] = (byte) (((byte) ((bArr[0] >> 7) & 135)) ^ bArr2[15]);
        return bArr2;
    }

    /* renamed from: ˌʾˀ, reason: contains not printable characters */
    public static final Object m2144(InterfaceC3759 interfaceC3759) {
        Thread.interrupted();
        return ᵮʛˀ.ˀᵗᵝᵭ(C4555.f16926, new ᵖˀᵟ(interfaceC3759, (InterfaceC4943) null, 21));
    }

    /* renamed from: ˌᵜᵹᵩ, reason: contains not printable characters */
    public static InterfaceC0919 m2145(XmlResourceParser xmlResourceParser, Resources resources) throws Throwable {
        int next;
        int i;
        int i2;
        int i3;
        TypedArray typedArray;
        do {
            next = xmlResourceParser.next();
            i = 2;
            if (next == 2) {
                break;
            }
        } while (next != 1);
        if (next != 2) {
            throw new XmlPullParserException("No start tag found");
        }
        xmlResourceParser.require(2, null, "font-family");
        if (!xmlResourceParser.getName().equals("font-family")) {
            m2150(xmlResourceParser);
            return null;
        }
        TypedArray typedArrayObtainAttributes = resources.obtainAttributes(Xml.asAttributeSet(xmlResourceParser), AbstractC4763.f17704);
        int i4 = 0;
        String string = typedArrayObtainAttributes.getString(0);
        String string2 = typedArrayObtainAttributes.getString(5);
        String string3 = typedArrayObtainAttributes.getString(6);
        String string4 = typedArrayObtainAttributes.getString(2);
        int resourceId = typedArrayObtainAttributes.getResourceId(1, 0);
        int i5 = 3;
        int integer = typedArrayObtainAttributes.getInteger(3, 1);
        int integer2 = typedArrayObtainAttributes.getInteger(4, 500);
        String string5 = typedArrayObtainAttributes.getString(7);
        typedArrayObtainAttributes.recycle();
        if (string == null || string2 == null) {
            ArrayList arrayList = new ArrayList();
            while (xmlResourceParser.next() != 3) {
                if (xmlResourceParser.getEventType() == 2) {
                    if (xmlResourceParser.getName().equals("font")) {
                        TypedArray typedArrayObtainAttributes2 = resources.obtainAttributes(Xml.asAttributeSet(xmlResourceParser), AbstractC4763.f17702);
                        int i6 = typedArrayObtainAttributes2.getInt(typedArrayObtainAttributes2.hasValue(8) ? 8 : 1, 400);
                        boolean z = 1 == typedArrayObtainAttributes2.getInt(typedArrayObtainAttributes2.hasValue(6) ? 6 : 2, 0);
                        int i7 = typedArrayObtainAttributes2.hasValue(9) ? 9 : 3;
                        String string6 = typedArrayObtainAttributes2.getString(typedArrayObtainAttributes2.hasValue(7) ? 7 : 4);
                        int i8 = typedArrayObtainAttributes2.getInt(i7, 0);
                        int i9 = typedArrayObtainAttributes2.hasValue(5) ? 5 : 0;
                        int resourceId2 = typedArrayObtainAttributes2.getResourceId(i9, 0);
                        String string7 = typedArrayObtainAttributes2.getString(i9);
                        typedArrayObtainAttributes2.recycle();
                        while (xmlResourceParser.next() != 3) {
                            m2150(xmlResourceParser);
                        }
                        arrayList.add(new C1389(string7, i6, z, string6, i8, resourceId2));
                    } else {
                        m2150(xmlResourceParser);
                    }
                }
            }
            if (arrayList.isEmpty()) {
                return null;
            }
            return new C1449((C1389[]) arrayList.toArray(new C1389[0]));
        }
        List listM2162 = m2162(resources, resourceId);
        ArrayList arrayList2 = new ArrayList();
        while (xmlResourceParser.next() != i5) {
            if (xmlResourceParser.getEventType() == i) {
                if (xmlResourceParser.getName().equals("fallback")) {
                    TypedArray typedArrayObtainAttributes3 = resources.obtainAttributes(Xml.asAttributeSet(xmlResourceParser), AbstractC4763.f17705);
                    try {
                        String string8 = typedArrayObtainAttributes3.getString(i4);
                        String string9 = typedArrayObtainAttributes3.getString(1);
                        i3 = integer;
                        String string10 = typedArrayObtainAttributes3.getString(i);
                        if (string8 == null) {
                            typedArray = typedArrayObtainAttributes3;
                            throw new XmlPullParserException("query attribute must be set in fallback element");
                        }
                        while (xmlResourceParser.next() != i5) {
                            m2150(xmlResourceParser);
                        }
                        try {
                            typedArray = typedArrayObtainAttributes3;
                            i2 = i5;
                            try {
                                C3831 c3831 = new C3831(string, string2, string8, listM2162, string9, string10);
                                typedArray.recycle();
                                arrayList2.add(c3831);
                            } catch (Throwable th) {
                                th = th;
                            }
                        } catch (Throwable th2) {
                            th = th2;
                            typedArray = typedArrayObtainAttributes3;
                        }
                        th = th;
                    } catch (Throwable th3) {
                        th = th3;
                        typedArray = typedArrayObtainAttributes3;
                    }
                    typedArray.recycle();
                    throw th;
                }
                i2 = i5;
                i3 = integer;
                m2150(xmlResourceParser);
                i5 = i2;
                integer = i3;
                i = 2;
                i4 = 0;
            }
        }
        int i10 = integer;
        if (!arrayList2.isEmpty()) {
            return new C4097(arrayList2, i10, integer2, string5);
        }
        if (string3 == null) {
            ᵹˉᵞ.ˌᵜᵹᵩ("The provider font XML requires query attribute or fallback children.");
            return null;
        }
        arrayList2.add(new C3831(string, string2, string3, listM2162, null, null));
        if (string4 != null) {
            arrayList2.add(new C3831(string, string2, string4, listM2162, null, null));
        }
        return new C4097(arrayList2, i10, integer2, string5);
    }

    /* renamed from: ˎˏʜʾ, reason: contains not printable characters */
    public static final InterfaceC2262 m2146(InterfaceC2262 interfaceC2262, InterfaceC2262 interfaceC22622, boolean z) {
        Boolean bool = Boolean.FALSE;
        int i = 3;
        boolean zBooleanValue = ((Boolean) interfaceC2262.mo1765(bool, new C1246(i))).booleanValue();
        boolean zBooleanValue2 = ((Boolean) interfaceC22622.mo1765(bool, new C1246(i))).booleanValue();
        if (!zBooleanValue && !zBooleanValue2) {
            return interfaceC2262.mo1762(interfaceC22622);
        }
        C1246 c1246 = new C1246(4);
        C4555 c4555 = C4555.f16926;
        InterfaceC2262 interfaceC22623 = (InterfaceC2262) interfaceC2262.mo1765(c4555, c1246);
        Object objMo1765 = interfaceC22622;
        if (zBooleanValue2) {
            objMo1765 = interfaceC22622.mo1765(c4555, new C1246(5));
        }
        return interfaceC22623.mo1762((InterfaceC2262) objMo1765);
    }

    /* renamed from: ˏˋٴ, reason: contains not printable characters */
    public static final long m2147(long j) {
        long j2 = (j << 1) + 1;
        C1058.f4589.getClass();
        int i = AbstractC4989.f18524;
        return j2;
    }

    /* JADX WARN: Removed duplicated region for block: B:7:0x0013  */
    /* renamed from: ˏᵙ, reason: contains not printable characters */
    /*
        Code decompiled incorrectly, please refer to instructions dump.
        To view partially-correct add '--show-bad-code' argument
    */
    public static final java.lang.Object m2148(defpackage.C1828 r4, defpackage.InterfaceC4622 r5, defpackage.AbstractC1989 r6) {
        /*
            boolean r0 = r6 instanceof defpackage.C3562
            if (r0 == 0) goto L13
            r0 = r6
            ᵦˁ r0 = (defpackage.C3562) r0
            int r1 = r0.f13341
            r2 = -2147483648(0xffffffff80000000, float:-0.0)
            r3 = r1 & r2
            if (r3 == 0) goto L13
            int r1 = r1 - r2
            r0.f13341 = r1
            goto L18
        L13:
            ᵦˁ r0 = new ᵦˁ
            r0.<init>(r6)
        L18:
            java.lang.Object r6 = r0.f13342
            int r1 = r0.f13341
            r2 = 0
            r3 = 1
            if (r1 == 0) goto L30
            if (r1 != r3) goto L2a
            ᵴʘ r5 = r0.f13343
            ʼٴ.ᵺᵠ(r6)     // Catch: java.lang.Throwable -> L28
            goto L61
        L28:
            r4 = move-exception
            goto L67
        L2a:
            java.lang.String r4 = "call to 'resume' before 'invoke' with coroutine"
            ᵹˉᵞ.ᵳٴᵶ(r4)
            return r2
        L30:
            ʼٴ.ᵺᵠ(r6)
            ᵔⁱʨˉ r6 = r0.f7997
            ʾᵠᵦ r1 = ʾᵠᵦ.ᵾᵬ
            ˈˆ r6 = r6.mo1764(r1)
            if (r6 != r4) goto L6b
            r0.f13343 = r5     // Catch: java.lang.Throwable -> L28
            r0.f13341 = r3     // Catch: java.lang.Throwable -> L28
            ᵱʽ r6 = new ᵱʽ     // Catch: java.lang.Throwable -> L28
            ᵸʚˑ r0 = ᵱᵞᵪ.ᵞʡ(r0)     // Catch: java.lang.Throwable -> L28
            r6.<init>(r3, r0)     // Catch: java.lang.Throwable -> L28
            r6.m9415()     // Catch: java.lang.Throwable -> L28
            ᵖᵽᵨ r0 = new ᵖᵽᵨ     // Catch: java.lang.Throwable -> L28
            r1 = 3
            r0.<init>(r1, r6)     // Catch: java.lang.Throwable -> L28
            ᵫʖˏ r4 = r4.f7422     // Catch: java.lang.Throwable -> L28
            r4.m8690(r0)     // Catch: java.lang.Throwable -> L28
            java.lang.Object r4 = r6.m9405()     // Catch: java.lang.Throwable -> L28
            ᵣˊᵛ r6 = defpackage.EnumC3346.f12524
            if (r4 != r6) goto L61
            return r6
        L61:
            r5.mo1401()
            ᵧˈᵽᵰ r4 = defpackage.C3637.f13536
            return r4
        L67:
            r5.mo1401()
            throw r4
        L6b:
            java.lang.String r4 = "awaitClose() can only be invoked from the producer context"
            ᵹˉᵞ.ᵳٴᵶ(r4)
            return r2
        */
        throw new UnsupportedOperationException("Method not decompiled: defpackage.AbstractC0494.m2148(ˏˆᵥ, ᵴʘ, ːᵱ):java.lang.Object");
    }

    /* renamed from: ˑᵥˁ, reason: contains not printable characters */
    public static ActionMode.Callback m2149(ActionMode.Callback callback, TextView textView) {
        int i = Build.VERSION.SDK_INT;
        return (i < 26 || i > 27 || (callback instanceof ActionModeCallbackC4238) || callback == null) ? callback : new ActionModeCallbackC4238(callback, textView);
    }

    /* renamed from: ˑᵱ, reason: contains not printable characters */
    public static void m2150(XmlPullParser xmlPullParser) throws XmlPullParserException, IOException {
        int i = 1;
        while (i > 0) {
            int next = xmlPullParser.next();
            if (next == 2) {
                i++;
            } else if (next == 3) {
                i--;
            }
        }
    }

    /* renamed from: ᵝᵵᵺ, reason: contains not printable characters */
    public static final Object m2151(C1173 c1173, C4661 c4661, Serializable serializable) {
        Object objCopyOf = c1173.f4988.get(c4661);
        if (objCopyOf instanceof byte[]) {
            byte[] bArr = (byte[]) objCopyOf;
            objCopyOf = Arrays.copyOf(bArr, bArr.length);
        }
        return objCopyOf == null ? serializable : objCopyOf;
    }

    /* renamed from: ᵞʡ, reason: contains not printable characters */
    public static void m2152(TextView textView, int i) {
        if (i < 0) {
            ᵨᴵᵺ.ᵻᵢﹳᵰ();
            return;
        }
        Paint.FontMetricsInt fontMetricsInt = textView.getPaint().getFontMetricsInt();
        int i2 = textView.getIncludeFontPadding() ? fontMetricsInt.bottom : fontMetricsInt.descent;
        if (i > Math.abs(i2)) {
            textView.setPadding(textView.getPaddingLeft(), textView.getPaddingTop(), textView.getPaddingRight(), i - i2);
        }
    }

    /* JADX WARN: Multi-variable type inference failed */
    /* renamed from: ᵡʠ, reason: contains not printable characters */
    public static void m2153(TextView textView, ColorStateList colorStateList) {
        textView.getClass();
        if (Build.VERSION.SDK_INT >= 24) {
            textView.setCompoundDrawableTintList(colorStateList);
        } else if (textView instanceof InterfaceC4415) {
            ((InterfaceC4415) textView).setSupportCompoundDrawablesTintList(colorStateList);
        }
    }

    /* renamed from: ᵡˎ, reason: contains not printable characters */
    public static final C0189 m2154(InterfaceC4943 interfaceC4943, InterfaceC2262 interfaceC2262, Object obj) {
        C0189 c0189 = null;
        if ((interfaceC4943 instanceof InterfaceC0571) && interfaceC2262.mo1764(C5489.f20587) != null) {
            InterfaceC0571 interfaceC0571Mo2414 = (InterfaceC0571) interfaceC4943;
            while (true) {
                if ((interfaceC0571Mo2414 instanceof C0809) || (interfaceC0571Mo2414 = interfaceC0571Mo2414.mo2414()) == null) {
                    break;
                }
                if (interfaceC0571Mo2414 instanceof C0189) {
                    c0189 = (C0189) interfaceC0571Mo2414;
                    break;
                }
            }
            if (c0189 != null) {
                c0189.m1421(interfaceC2262, obj);
            }
        }
        return c0189;
    }

    /* renamed from: ᵡⁱᵥ, reason: contains not printable characters */
    public static final long m2155(long j, EnumC0171 enumC0171) {
        TimeUnit timeUnit = enumC0171.f1599;
        TimeUnit timeUnit2 = TimeUnit.NANOSECONDS;
        long jConvert = timeUnit.convert(4611686018426999999L, timeUnit2);
        if ((-jConvert) <= j && j <= jConvert) {
            long jConvert2 = timeUnit2.convert(j, timeUnit);
            ʾᵚᵱ r9 = C1058.f4589;
            long j2 = jConvert2 << 1;
            int i = AbstractC4989.f18524;
            return j2;
        }
        if (enumC0171.compareTo(EnumC0171.MILLISECONDS) < 0) {
            return m2147(ᵕˏᵛ.ˎˏʜʾ(TimeUnit.MILLISECONDS.convert(j, timeUnit), -4611686018427387903L, 4611686018427387903L));
        }
        long jSignum = Long.signum(j);
        if (j < -9223372036854775807L) {
            j = -9223372036854775807L;
        }
        return m2147(ᵯᵽᵦ.ˎˏʜʾ(Math.abs(j), enumC0171) * jSignum);
    }

    /* renamed from: ᵢˇᵭ, reason: contains not printable characters */
    public static void m2156(C4089 c4089) {
        int iM8966;
        int iM89662 = c4089.m8966(2);
        if (iM89662 == 0) {
            c4089.m8956(6);
            return;
        }
        int iM2161 = m2161(c4089, 5, 8, 16) + 1;
        if (iM89662 == 1) {
            c4089.m8956(iM2161 * 7);
            return;
        }
        if (iM89662 == 2) {
            boolean zM8964 = c4089.m8964();
            int i = zM8964 ? 1 : 5;
            int i2 = zM8964 ? 7 : 5;
            int i3 = zM8964 ? 8 : 6;
            int i4 = 0;
            while (i4 < iM2161) {
                if (c4089.m8964()) {
                    c4089.m8956(7);
                    iM8966 = 0;
                } else {
                    if (c4089.m8966(2) == 3 && c4089.m8966(i2) * i != 0) {
                        c4089.m8965();
                    }
                    iM8966 = c4089.m8966(i3) * i;
                    if (iM8966 != 0 && iM8966 != 180) {
                        c4089.m8965();
                    }
                    c4089.m8965();
                }
                if (iM8966 != 0 && iM8966 != 180 && c4089.m8964()) {
                    i4++;
                }
                i4++;
            }
        }
    }

    /* renamed from: ᵤᵙᵷ, reason: contains not printable characters */
    public static final long m2157(int i, EnumC0171 enumC0171) {
        if (enumC0171.compareTo(EnumC0171.SECONDS) > 0) {
            return m2155(i, enumC0171);
        }
        long jConvert = TimeUnit.NANOSECONDS.convert(i, enumC0171.f1599);
        ʾᵚᵱ r0 = C1058.f4589;
        long j = jConvert << 1;
        int i2 = AbstractC4989.f18524;
        return j;
    }

    /* renamed from: ᵥᵯˎ, reason: contains not printable characters */
    public static C3920 m2158(int i, int i2, int i3) {
        if ((i3 & 2) != 0) {
            i2 = 1;
        }
        if (i == -2) {
            if (i2 != 1) {
                return new C4406(1, i2);
            }
            InterfaceC2817.f10858.getClass();
            return new C3920(C2711.f10522);
        }
        if (i != -1) {
            return i != 0 ? i != Integer.MAX_VALUE ? i2 == 1 ? new C3920(i) : new C4406(i, i2) : new C3920(Integer.MAX_VALUE) : i2 == 1 ? new C3920(0) : new C4406(1, i2);
        }
        if (i2 == 1) {
            return new C4406(1, 2);
        }
        ᵹˉᵞ.ˌᵜᵹᵩ("CONFLATED capacity cannot be used with non-default onBufferOverflow");
        return null;
    }

    /* renamed from: ᵧᵾˀˈ, reason: contains not printable characters */
    public static void m2159(C4089 c4089) {
        c4089.m8956(3);
        c4089.m8956(8);
        boolean zM8964 = c4089.m8964();
        boolean zM89642 = c4089.m8964();
        if (zM8964) {
            c4089.m8956(5);
        }
        if (zM89642) {
            c4089.m8956(6);
        }
    }

    /* renamed from: ᵨᵳʝ, reason: contains not printable characters */
    public static void m2160(TextView textView, int i) {
        if (i < 0) {
            ᵨᴵᵺ.ᵻᵢﹳᵰ();
            return;
        }
        if (i != textView.getPaint().getFontMetricsInt(null)) {
            textView.setLineSpacing(i - r0, 1.0f);
        }
    }

    /* renamed from: ᵪʩ, reason: contains not printable characters */
    public static int m2161(C4089 c4089, int i, int i2, int i3) {
        ᵛᵾˏ.ᵯٴᵦ(Math.max(Math.max(i, i2), i3) <= 31);
        int i4 = (1 << i) - 1;
        int i5 = (1 << i2) - 1;
        ᵺᵣᵬ.ˏᵙ(ᵺᵣᵬ.ˏᵙ(i4, i5), 1 << i3);
        if (c4089.m8963() < i) {
            return -1;
        }
        int iM8966 = c4089.m8966(i);
        if (iM8966 == i4) {
            if (c4089.m8963() < i2) {
                return -1;
            }
            int iM89662 = c4089.m8966(i2);
            iM8966 += iM89662;
            if (iM89662 == i5) {
                if (c4089.m8963() < i3) {
                    return -1;
                }
                return c4089.m8966(i3) + iM8966;
            }
        }
        return iM8966;
    }

    /* renamed from: ᵯٴᵦ, reason: contains not printable characters */
    public static List m2162(Resources resources, int i) throws Resources.NotFoundException {
        if (i == 0) {
            return Collections.EMPTY_LIST;
        }
        TypedArray typedArrayObtainTypedArray = resources.obtainTypedArray(i);
        try {
            if (typedArrayObtainTypedArray.length() == 0) {
                return Collections.EMPTY_LIST;
            }
            ArrayList arrayList = new ArrayList();
            if (typedArrayObtainTypedArray.getType(0) == 1) {
                for (int i2 = 0; i2 < typedArrayObtainTypedArray.length(); i2++) {
                    int resourceId = typedArrayObtainTypedArray.getResourceId(i2, 0);
                    if (resourceId != 0) {
                        String[] stringArray = resources.getStringArray(resourceId);
                        ArrayList arrayList2 = new ArrayList();
                        for (String str : stringArray) {
                            arrayList2.add(Base64.decode(str, 0));
                        }
                        arrayList.add(arrayList2);
                    }
                }
            } else {
                String[] stringArray2 = resources.getStringArray(i);
                ArrayList arrayList3 = new ArrayList();
                for (String str2 : stringArray2) {
                    arrayList3.add(Base64.decode(str2, 0));
                }
                arrayList.add(arrayList3);
            }
            return arrayList;
        } finally {
            typedArrayObtainTypedArray.recycle();
        }
    }

    /* renamed from: ᵳٴᵶ, reason: contains not printable characters */
    public static final void m2163(String str) {
        System.err.println("SLF4J: ".concat(str));
    }

    /* renamed from: ᵴᵳ, reason: contains not printable characters */
    public static final long m2164(long j, long j2) {
        if (j != 4611686018427387903L && j != -4611686018427387903L) {
            return (j2 == 4611686018427387903L || j2 == -4611686018427387903L) ? j2 : ᵕˏᵛ.ˎˏʜʾ(j + j2, -4611686018427387903L, 4611686018427387903L);
        }
        if ((-4611686018427387903L >= j2 || j2 >= 4611686018427387903L) && (j2 ^ j) < 0) {
            return 9223372036854759646L;
        }
        return j;
    }

    /* renamed from: ᵶᵷᵕ, reason: contains not printable characters */
    public static C4124 m2165(C0998 c0998) {
        int i = Build.VERSION.SDK_INT;
        if (i >= 28) {
            return new C4124(AbstractC3502.m7993(c0998));
        }
        TextPaint textPaint = new TextPaint(c0998.getPaint());
        TextDirectionHeuristic textDirectionHeuristic = TextDirectionHeuristics.FIRSTSTRONG_LTR;
        int breakStrategy = c0998.getBreakStrategy();
        int hyphenationFrequency = c0998.getHyphenationFrequency();
        if (c0998.getTransformationMethod() instanceof PasswordTransformationMethod) {
            textDirectionHeuristic = TextDirectionHeuristics.LTR;
        } else {
            if (i < 28 || (c0998.getInputType() & 15) != 3) {
                boolean z = c0998.getLayoutDirection() == 1;
                switch (c0998.getTextDirection()) {
                    case 2:
                        textDirectionHeuristic = TextDirectionHeuristics.ANYRTL_LTR;
                        break;
                    case 3:
                        textDirectionHeuristic = TextDirectionHeuristics.LTR;
                        break;
                    case 4:
                        textDirectionHeuristic = TextDirectionHeuristics.RTL;
                        break;
                    case 5:
                        textDirectionHeuristic = TextDirectionHeuristics.LOCALE;
                        break;
                    case C1339.STRING_SET_FIELD_NUMBER /* 6 */:
                        break;
                    case C1339.DOUBLE_FIELD_NUMBER /* 7 */:
                        textDirectionHeuristic = TextDirectionHeuristics.FIRSTSTRONG_RTL;
                        break;
                    default:
                        if (z) {
                            textDirectionHeuristic = TextDirectionHeuristics.FIRSTSTRONG_RTL;
                            break;
                        }
                        break;
                }
            } else {
                byte directionality = Character.getDirectionality(AbstractC3502.m7988(AbstractC2602.m6543(c0998.getTextLocale()))[0].codePointAt(0));
                textDirectionHeuristic = (directionality == 1 || directionality == 2) ? TextDirectionHeuristics.RTL : TextDirectionHeuristics.LTR;
            }
        }
        return new C4124(textPaint, textDirectionHeuristic, breakStrategy, hyphenationFrequency);
    }

    /* renamed from: ᵸʓᵠ, reason: contains not printable characters */
    public static void m2166(TextView textView, int i) {
        if (i < 0) {
            ᵨᴵᵺ.ᵻᵢﹳᵰ();
            return;
        }
        if (Build.VERSION.SDK_INT >= 28) {
            AbstractC3502.m8011(textView, i);
            return;
        }
        Paint.FontMetricsInt fontMetricsInt = textView.getPaint().getFontMetricsInt();
        int i2 = textView.getIncludeFontPadding() ? fontMetricsInt.top : fontMetricsInt.ascent;
        if (i > Math.abs(i2)) {
            textView.setPadding(textView.getPaddingLeft(), i + i2, textView.getPaddingRight(), textView.getPaddingBottom());
        }
    }

    /* renamed from: ᵸˑ, reason: contains not printable characters */
    public static final InterfaceC2262 m2167(InterfaceC0320 interfaceC0320, InterfaceC2262 interfaceC2262) {
        InterfaceC2262 interfaceC2262M2146 = m2146(interfaceC0320.mo1703(), interfaceC2262, true);
        C1980 c1980 = AbstractC4021.f15114;
        return (interfaceC2262M2146 == c1980 || interfaceC2262M2146.mo1764(ˉːᵡ.ᵿʗᵝʽ) != null) ? interfaceC2262M2146 : interfaceC2262M2146.mo1762(c1980);
    }

    /* renamed from: ᵹᵝᵶ, reason: contains not printable characters */
    public static final C3084 m2168(C3887 c3887) {
        return new C3084(c3887.f14484, c3887.f14482);
    }

    /* renamed from: ᵻᵢﹳᵰ, reason: contains not printable characters */
    public static final void m2169(int i, int i2) {
        String strM8596;
        if (i <= 0 || i2 <= 0) {
            if (i != i2) {
                strM8596 = "Both size " + i + " and step " + i2 + " must be greater than zero.";
            } else {
                strM8596 = AbstractC3915.m8596(i, "size ", " must be greater than zero.");
            }
            ᵹˉᵞ.ᵸˑ(strM8596);
        }
    }

    /* renamed from: ᵾᵬ, reason: contains not printable characters */
    public static final C2977 m2170(C2977 c2977) {
        C0446 c0446M7285 = c2977.m7285();
        AbstractC3866 abstractC3866 = c2977.f11499;
        c0446M7285.f2492 = new C2469(abstractC3866.mo3787(), abstractC3866.mo3788());
        return c0446M7285.m2055();
    }

    /* renamed from: ᵿʗᵝʽ, reason: contains not printable characters */
    public static final void m2171(ᵼᵽ r7, long j, boolean z) {
        if (!z) {
            ᵮʛˀ.ᵞʡ(ᵹˉ.ˀᵗᵩ(r7), (InterfaceC2262) null, 0, new ᵠᵷᵞ(j, r7, (InterfaceC4943) null, 3), 3);
            return;
        }
        AbstractComponentCallbacksC3693 abstractComponentCallbacksC3693 = r7.f13750;
        AbstractC1477 abstractC1477 = abstractComponentCallbacksC3693 instanceof AbstractC1477 ? (AbstractC1477) abstractComponentCallbacksC3693 : null;
        if (abstractC1477 != null) {
            ˇˌ r72 = new ˇˌ();
            r72.m8306(ˉˇʨ.ᵻᵢﹳᵰ(new C2836[]{new C2836("args", new ᵲᵼ(false, j))}));
            abstractC1477.m4388(r72);
        }
    }
}
