package com.bytedance.tiktok.homepage.mainfragment.inflate;

import X.9Ft;
import X.9Fx;
import X.9GB;
import X.C4723Elb;
import X.M12;
import X.OD2;
import android.app.Activity;
import android.content.Context;
import android.view.View;
import android.widget.ImageView;
import com.bytedance.covode.number.Covode;
import com.ss.android.ugc.aweme.main.uiApiImpl.HomePageUIFrameServiceImpl;
import java.util.List;

public final class MainFragmentTopRightIconInflate implements 9GB {
    public View LIZ;
    public ImageView LIZIZ;
    public OD2 LIZJ;
    public ImageView LIZLLL;

    static {
        Covode.recordClassIndex(38515);
    }

    public final boolean meetTrigger() {
        return true;
    }

    public final String prefix() {
        return "inflate_";
    }

    public final void run(Context context) {
    }

    public final int targetProcess() {
        return 1048575;
    }

    public final List triggerOtherLegoComponents() {
        return null;
    }

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

    public final 9Ft triggerType() {
        return 9Ft.INFLATE;
    }

    public final Class<? extends Activity> LIZ() {
        return HomePageUIFrameServiceImpl.LJ().LIZ();
    }

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

    public final void LIZ(Context context, Activity activity) {
        Activity activity2;
        Activity activity3;
        M12.LIZ(context);
        C4723Elb elb = C4723Elb.LIZ;
        if (activity != null) {
            activity2 = activity;
        } else {
            activity2 = context;
        }
        this.LIZIZ = (ImageView) elb.LIZLLL(activity2);
        C4723Elb elb2 = C4723Elb.LIZ;
        if (activity != null) {
            activity3 = activity;
        } else {
            activity3 = context;
        }
        this.LIZJ = elb2.LIZJ(activity3);
        C4723Elb elb3 = C4723Elb.LIZ;
        if (activity != null) {
            context = activity;
        }
        this.LIZLLL = (ImageView) elb3.LJ(context);
    }

    public final View LIZ(Context context, int i) {
        View view;
        M12.LIZ(context);
        if (i == 3) {
            View view2 = this.LIZ;
            if (view2 == null) {
                view2 = C4723Elb.LIZ.LIZIZ(context);
            }
            this.LIZ = null;
        } else if (i == 4) {
            View view3 = this.LIZIZ;
            if (view3 == null) {
                view3 = C4723Elb.LIZ.LIZLLL(context);
            }
            this.LIZIZ = null;
        } else if (i != 5) {
            view = this.LIZLLL;
            if (view == null) {
                view = C4723Elb.LIZ.LJ(context);
            }
            this.LIZLLL = null;
        } else {
            View view4 = this.LIZJ;
            if (view4 == null) {
                view4 = C4723Elb.LIZ.LIZJ(context);
            }
            this.LIZJ = null;
        }
        return view;
    }
}
