package com.ss.android.ugc.aweme.setting.page.authmanager;

import X.0HH;
import X.2OR;
import X.7he;
import X.C0295Crj;
import X.C5720F4a;
import X.C5741F4v;
import X.C5743F4x;
import X.C5744F4y;
import X.D1G;
import X.F4S;
import X.F4T;
import X.KEM;
import X.M12;
import X.OQg;
import android.os.Bundle;
import android.util.SparseArray;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import com.bytedance.covode.number.Covode;
import com.ss.android.ugc.aweme.base.arch.JediBaseFragment;
import com.ss.android.ugc.aweme.global.config.settings.pojo.IESSettingsProxy;
import com.ss.android.ugc.aweme.global.config.settings.pojo.UgAwemeActivitySetting;
import com.ss.android.ugc.aweme.setting.viewmodel.AuthListViewModel;
import kotlin.h.b.n;

public final class AuthAppInfoFragment extends JediBaseFragment {
    public static String LIZIZ = "";
    public static String LIZJ = "";
    public static String LIZLLL = "";
    public static String LJ;
    public static final C5743F4x LJIIIZ = new C5743F4x((byte) 0);
    public final C0295Crj LJIIJ;
    public final C0295Crj LJIIJJI = 7he.LIZ(new C5741F4v(this));
    public SparseArray LJIIL;

    public final View LIZJ(int i) {
        if (this.LJIIL == null) {
            this.LJIIL = new SparseArray();
        }
        View view = (View) this.LJIIL.get(i);
        if (view != null) {
            return view;
        }
        View view2 = getView();
        if (view2 == null) {
            return null;
        }
        View findViewById = view2.findViewById(i);
        this.LJIIL.put(i, findViewById);
        return findViewById;
    }

    public final AuthListViewModel LIZJ() {
        return (AuthListViewModel) this.LJIIJ.getValue();
    }

    public final OQg LIZLLL() {
        return (OQg) this.LJIIJJI.getValue();
    }

    public final void cb_() {
        SparseArray sparseArray = this.LJIIL;
        if (sparseArray != null) {
            sparseArray.clear();
        }
    }

    public final /* synthetic */ void onDestroyView() {
        AuthAppInfoFragment.super.onDestroyView();
        cb_();
    }

    static {
        Covode.recordClassIndex(105912);
    }

    public final boolean LJ() {
        try {
            IESSettingsProxy iESSettingsProxy = 2OR.LIZ.LIZIZ;
            n.LIZIZ(iESSettingsProxy, "");
            UgAwemeActivitySetting awemeActivitySetting = iESSettingsProxy.getAwemeActivitySetting();
            n.LIZIZ(awemeActivitySetting, "");
            Boolean isNewUser = awemeActivitySetting.getIsNewUser();
            n.LIZIZ(isNewUser, "");
            return isNewUser.booleanValue();
        } catch (Exception unused) {
            return false;
        }
    }

    public AuthAppInfoFragment() {
        D1G LIZ = KEM.LIZ.LIZ(AuthListViewModel.class);
        this.LJIIJ = 7he.LIZ(new F4T(this, LIZ, LIZ));
    }

    public final void onViewCreated(View view, Bundle bundle) {
        M12.LIZ(view);
        AuthAppInfoFragment.super.onViewCreated(view, bundle);
        LIZJ(2131362572).setOnClickListener(new F4S(this));
        LIZJ(2131362937).setOnClickListener(new C5720F4a(this));
        LIZJ().LIZIZ.observe(this, new C5744F4y(this));
    }

    public final View onCreateView(LayoutInflater layoutInflater, ViewGroup viewGroup, Bundle bundle) {
        M12.LIZ(layoutInflater);
        return 0HH.LIZ(layoutInflater, 2131561269, viewGroup, false);
    }
}
