package com.ss.android.ugc.aweme.legoImp.task;

import X.7lW;
import X.8Zd;
import X.8Ze;
import X.8ec;
import X.8lp;
import X.9EH;
import X.9FG;
import X.9FH;
import X.9Ft;
import X.9Fx;
import X.9H6;
import X.C0185Jue;
import X.C2178Kob;
import X.C2179Koc;
import X.C4097LeS;
import X.C4116Lel;
import X.LAO;
import X.LAP;
import X.LAQ;
import X.LB2;
import X.M12;
import X.NuT;
import X.To0;
import android.content.Context;
import android.text.TextUtils;
import com.bytedance.covode.number.Covode;
import com.ss.android.ugc.aweme.setting.services.SettingServiceImpl;
import java.util.List;
import java.util.Map;

public class FontTask implements 9FH, 9FG, 8Ze {
    public long LIZ = 500;

    static {
        Covode.recordClassIndex(90439);
    }

    public final boolean LIZ() {
        return true;
    }

    public String[] deps() {
        return null;
    }

    public boolean meetTrigger() {
        return true;
    }

    public String prefix() {
        return "task_";
    }

    public int priority() {
        return 1;
    }

    public boolean serialExecute() {
        return false;
    }

    public int targetProcess() {
        return 1;
    }

    public List triggerOtherLegoComponents() {
        return null;
    }

    public 9Ft triggerType() {
        return 8Zd.LIZ(this);
    }

    public final long LIZIZ() {
        return this.LIZ;
    }

    public 9Fx scenesType() {
        return 9Fx.DEFAULT;
    }

    public String key() {
        return getClass().getSimpleName();
    }

    public 8lp threadType() {
        if (((Boolean) To0.LJIIZILJ.getValue()).booleanValue()) {
            return 8lp.IO;
        }
        return 8lp.CPU;
    }

    public 8ec type() {
        if ((9H6.LJIIIZ.LIZ() & 9H6.LJFF) == 9H6.LJFF) {
            return 8ec.IDLE;
        }
        return 8ec.BACKGROUND;
    }

    public final void LIZ(Long l) {
        this.LIZ = l.longValue();
    }

    public void run(Context context) {
        List LIZIZ;
        if (!TextUtils.equals(SettingServiceImpl.LJIJJ().LIZ(9EH.LJJIFFI.LIZ()).LIZIZ(), "th")) {
            NuT.LIZ().LIZ(context, LB2.LIZ);
            LAP LIZ2 = LAP.LIZ();
            Map<String, String> map = LB2.LIZ;
            if (context != null) {
                Context applicationContext = context.getApplicationContext();
                if (7lW.LIZJ && applicationContext == null) {
                    applicationContext = 7lW.LIZ;
                }
                LIZ2.LIZIZ = applicationContext;
            }
            LIZ2.LIZ = map;
            C2178Kob.LIZ().LIZ((C2179Koc) new LAO());
        }
        M12.LIZ((Object) context);
        if (LAQ.LIZ()) {
            LIZIZ = C4116Lel.INSTANCE;
        } else {
            LIZIZ = C4097LeS.LIZIZ((T[]) new String[]{"font/ProximaNova-Bold.otf", "font/ProximaNova-Semibold.otf", "font/ProximaNova-Reg.otf"});
        }
        C0185Jue.LIZ.LIZ(context, LIZIZ);
    }
}
