星辰影院解锁vip v1.0.4版本的 MD5 值为:3d99bbcbb0d5d5e568b9f6134424c24e
以下内容为反编译后的 PhonePrimaryDeviceUINew.java 源代码,内容仅作参考
package com.iqiyi.pexui.mdevice;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.TextView;
import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import com.iqiyi.passportsdk.mdevice.MdeviceApiNew;
import com.iqiyi.passportsdk.mdevice.f.a;
import com.iqiyi.passportsdk.mdevice.f.b;
import com.iqiyi.pexui.mdevice.VerifyCodeDialog;
import com.iqiyi.pexui.mdevice.d;
import com.iqiyi.psdk.exui.R$id;
import com.iqiyi.psdk.exui.R$layout;
import com.iqiyi.psdk.exui.R$string;
import com.iqiyi.pui.base.PUIPage;
import com.iqiyi.qyverificationcenter.bean.QYVerifyConstants;
import com.sensorsdata.analytics.android.sdk.SensorsDataAutoTrackHelper;
import com.sensorsdata.analytics.android.sdk.SensorsDataInstrumented;
import org.json.JSONObject;
import org.qiyi.android.video.ui.account.base.PUIPageActivity;
import psdk.v.PLL;
public class PhonePrimaryDeviceUINew extends PUIPage implements View.OnClickListener, d.b {
private View f7314c;
private LinearLayout f7315d;
private TextView f7316e;
private ImageView f7317f;
private TextView f7318g;
private TextView f7319h;
private LinearLayout f7320i;
private TextView f7321j;
private TextView f7322k;
private LinearLayout f7323l;
private TextView m;
private TextView n;
private LinearLayout o;
private TextView p;
private RecyclerView q;
private LinearLayout r;
private PLL s;
private PLL t;
private com.iqiyi.pexui.mdevice.d u;
private com.iqiyi.passportsdk.mdevice.f.a v;
private int w;
private VerifyCodeDialog y;
private b.C0197b x = new b.C0197b();
private boolean z = true;
public class a implements com.iqiyi.passportsdk.o.j.b<com.iqiyi.passportsdk.mdevice.f.a> {
a() {
}
@Override
public void b(com.iqiyi.passportsdk.mdevice.f.a aVar) {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
if (aVar == null) {
c(null);
return;
}
if (!QYVerifyConstants.VerifyResponCode.kSuccess.equals(aVar.a)) {
com.iqiyi.passportsdk.utils.d.e(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, aVar.f6811b);
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
return;
}
com.iqiyi.passportsdk.mdevice.b.a().e(aVar);
if (PhonePrimaryDeviceUINew.this.isAdded()) {
PhonePrimaryDeviceUINew.this.v = aVar;
PhonePrimaryDeviceUINew.this.J1();
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
}
}
}
@Override
public void c(Object obj) {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
PhonePrimaryDeviceUINew.this.J1();
com.iqiyi.passportsdk.utils.d.d(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, R$string.psdk_tips_network_fail_and_try);
}
}
}
class b implements View.OnClickListener {
final b.C0197b a;
b(b.C0197b c0197b) {
this.a = c0197b;
}
@Override
@SensorsDataInstrumented
public void onClick(View view) {
PhonePrimaryDeviceUINew.this.x = this.a;
PhonePrimaryDeviceUINew.this.y1(null, null, null, null);
SensorsDataAutoTrackHelper.trackViewOnClick(view);
}
}
public class c implements com.iqiyi.passportsdk.o.j.b<JSONObject> {
final VerifyCodeDialog a;
c(VerifyCodeDialog verifyCodeDialog) {
this.a = verifyCodeDialog;
}
@Override
public void b(JSONObject jSONObject) {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
String optString = jSONObject.optString("code");
if (QYVerifyConstants.VerifyResponCode.kSuccess.equals(optString)) {
PhonePrimaryDeviceUINew.this.u.v(PhonePrimaryDeviceUINew.this.x);
com.iqiyi.psdk.base.j.g.r("devlock-deltsus");
com.iqiyi.passportsdk.utils.d.d(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, R$string.psdk_delete_device_success);
VerifyCodeDialog verifyCodeDialog = this.a;
if (verifyCodeDialog != null) {
verifyCodeDialog.m0();
return;
}
return;
}
if ("P00159".equals(optString)) {
PhonePrimaryDeviceUINew.this.P1(com.iqiyi.psdk.base.b.m(), 29, null);
return;
}
com.iqiyi.passportsdk.utils.e.b("PhonePrimaryDeviceUI", "deleteDevice code is " + optString);
String optString2 = jSONObject.optString("msg");
if (com.iqiyi.psdk.base.j.k.h0(optString2)) {
com.iqiyi.passportsdk.utils.d.e(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, optString2);
} else {
com.iqiyi.passportsdk.utils.d.d(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, R$string.psdk_delete_device_fail);
}
VerifyCodeDialog verifyCodeDialog2 = this.a;
if (verifyCodeDialog2 != null) {
verifyCodeDialog2.m0();
}
}
}
@Override
public void c(Object obj) {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
com.iqiyi.passportsdk.utils.d.d(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, R$string.psdk_tips_network_fail_and_try);
VerifyCodeDialog verifyCodeDialog = this.a;
if (verifyCodeDialog != null) {
verifyCodeDialog.m0();
}
}
}
}
public static class d implements View.OnClickListener {
final PUIPageActivity a;
d(PUIPageActivity pUIPageActivity) {
this.a = pUIPageActivity;
}
@Override
@SensorsDataInstrumented
public void onClick(View view) {
PhonePrimaryDeviceUINew.E1(this.a);
SensorsDataAutoTrackHelper.trackViewOnClick(view);
}
}
public class e implements com.iqiyi.passportsdk.o.j.b<com.iqiyi.passportsdk.mdevice.f.b> {
e() {
}
@Override
public void b(com.iqiyi.passportsdk.mdevice.f.b bVar) {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
if (QYVerifyConstants.VerifyResponCode.kSuccess.equals(bVar.a)) {
PhonePrimaryDeviceUINew.this.L1(bVar);
} else {
com.iqiyi.passportsdk.utils.d.e(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, bVar.f6818b);
}
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
}
}
@Override
public void c(Object obj) {
com.iqiyi.passportsdk.utils.e.b("PhonePrimaryDeviceUI", "getTrustDevice failed: " + obj);
if (PhonePrimaryDeviceUINew.this.isAdded()) {
com.iqiyi.passportsdk.utils.d.d(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, R$string.psdk_tips_network_fail_and_try);
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
}
}
}
public class f implements VerifyCodeDialog.h {
final int a;
final String f7326b;
f(int i2, String str) {
this.a = i2;
this.f7326b = str;
}
@Override
public void a(String str) {
if (this.a == 29) {
PhonePrimaryDeviceUINew.this.y1(str, this.f7326b, com.iqiyi.psdk.base.b.n(), PhonePrimaryDeviceUINew.this.y);
}
}
@Override
public void onSuccess() {
if (this.a == 52) {
PhonePrimaryDeviceUINew.this.v.f(false);
com.iqiyi.psdk.base.j.g.r("devmng-maincls-scs");
com.iqiyi.passportsdk.utils.d.e(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, PhonePrimaryDeviceUINew.this.getString(R$string.psdk_primarydevice_closed));
} else {
PhonePrimaryDeviceUINew.this.v.f(true);
com.iqiyi.psdk.base.j.g.r("devmng-mainop-scs");
com.iqiyi.passportsdk.utils.d.e(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, PhonePrimaryDeviceUINew.this.getString(R$string.psdk_primarydevice_opened));
}
PhonePrimaryDeviceUINew.this.I1();
}
}
public class g implements View.OnClickListener {
g() {
}
@Override
@SensorsDataInstrumented
public void onClick(View view) {
PhonePrimaryDeviceUINew.this.O1(com.iqiyi.psdk.base.b.m(), 52);
SensorsDataAutoTrackHelper.trackViewOnClick(view);
}
}
public class h implements com.iqiyi.passportsdk.mdevice.e {
h() {
}
@Override
public void a(String str) {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
com.iqiyi.passportsdk.utils.d.e(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, str);
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
}
}
@Override
public void b(com.iqiyi.passportsdk.mdevice.f.b bVar) {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
PhonePrimaryDeviceUINew.this.N1(bVar, true);
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
}
}
@Override
public void c() {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
com.iqiyi.passportsdk.utils.d.d(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, R$string.psdk_tips_network_fail_and_try);
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
}
}
@Override
public void d() {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
if (PhonePrimaryDeviceUINew.this.v != null) {
PhonePrimaryDeviceUINew.this.v.g(true);
}
com.iqiyi.psdk.base.j.g.r("devlock-addsus");
PhonePrimaryDeviceUINew.this.K1();
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
}
}
}
public class i implements View.OnClickListener {
i() {
}
@Override
@SensorsDataInstrumented
public void onClick(View view) {
PhonePrimaryDeviceUINew.this.x1();
SensorsDataAutoTrackHelper.trackViewOnClick(view);
}
}
public class j implements com.iqiyi.passportsdk.o.j.b<JSONObject> {
j() {
}
@Override
public void b(JSONObject jSONObject) {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
String optString = jSONObject.optString("code");
if (QYVerifyConstants.VerifyResponCode.kSuccess.equals(optString)) {
PhonePrimaryDeviceUINew.this.N1(new com.iqiyi.passportsdk.mdevice.g.b().a(jSONObject), false);
return;
}
if ("P00920".equals(optString)) {
com.iqiyi.psdk.base.j.g.r("devlock-addcnf-hglim");
} else if ("P00917".equals(optString)) {
com.iqiyi.psdk.base.j.g.r("devlock-addcnf-nool");
}
com.iqiyi.passportsdk.utils.e.b("PhonePrimaryDeviceUI", "getOnlineTrust code is " + optString);
com.iqiyi.passportsdk.utils.d.e(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, jSONObject.optString("msg"));
}
}
@Override
public void c(Object obj) {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
com.iqiyi.passportsdk.utils.d.d(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, R$string.psdk_tips_network_fail_and_try);
}
}
}
public class k implements com.iqiyi.passportsdk.o.j.b<JSONObject> {
final boolean a;
final AddTrustDeviceDialog f7328b;
k(boolean z, AddTrustDeviceDialog addTrustDeviceDialog) {
this.a = z;
this.f7328b = addTrustDeviceDialog;
}
@Override
public void b(JSONObject jSONObject) {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
String optString = jSONObject.optString("code");
if (QYVerifyConstants.VerifyResponCode.kSuccess.equals(optString)) {
if (this.a) {
if (PhonePrimaryDeviceUINew.this.v != null) {
PhonePrimaryDeviceUINew.this.v.g(true);
}
com.iqiyi.psdk.base.j.g.c("devlock-addsus", PhonePrimaryDeviceUINew.this.C1());
} else {
com.iqiyi.psdk.base.j.g.r("devlock-addcnfsus");
}
PhonePrimaryDeviceUINew.this.K1();
} else {
com.iqiyi.passportsdk.utils.e.b("PhonePrimaryDeviceUI", "AddTrustDeviceDialog callback code is " + optString);
com.iqiyi.passportsdk.utils.d.e(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, jSONObject.optString("msg"));
}
this.f7328b.m0();
}
}
@Override
public void c(Object obj) {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
com.iqiyi.passportsdk.utils.d.d(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, R$string.psdk_tips_network_fail_and_try);
this.f7328b.m0();
}
}
}
public class l implements com.iqiyi.passportsdk.o.j.b<JSONObject> {
l() {
}
@Override
public void b(JSONObject jSONObject) {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
String optString = jSONObject.optString("code");
if (QYVerifyConstants.VerifyResponCode.kSuccess.equals(optString)) {
if (PhonePrimaryDeviceUINew.this.v != null) {
PhonePrimaryDeviceUINew.this.v.g(false);
}
PhonePrimaryDeviceUINew.this.K1();
com.iqiyi.psdk.base.j.g.r("devlock-clssus");
com.iqiyi.passportsdk.utils.d.d(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, R$string.psdk_protect_closed);
return;
}
com.iqiyi.passportsdk.utils.e.b("PhonePrimaryDeviceUI", "closeDeviceProtect code is " + optString);
com.iqiyi.passportsdk.utils.d.d(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, R$string.psdk_protect_close_failed);
}
}
@Override
public void c(Object obj) {
if (PhonePrimaryDeviceUINew.this.isAdded()) {
((PUIPage) PhonePrimaryDeviceUINew.this).f7612b.f0();
com.iqiyi.passportsdk.utils.d.d(((PUIPage) PhonePrimaryDeviceUINew.this).f7612b, R$string.psdk_tips_network_fail_and_try);
}
}
}
private void A1() {
PUIPageActivity pUIPageActivity = this.f7612b;
pUIPageActivity.Q0(pUIPageActivity.getString(R$string.psdk_loading_wait));
MdeviceApiNew.getMdeviceInfo(new a());
}
private void B1() {
PUIPageActivity pUIPageActivity = this.f7612b;
pUIPageActivity.Q0(pUIPageActivity.getString(R$string.psdk_loading_wait));
MdeviceApiNew.getOnlineTrust(new j());
}
public String C1() {
return "devmng";
}
private void D1() {
this.f7316e.setVisibility(0);
this.f7318g.setVisibility(0);
this.f7319h.setVisibility(0);
this.f7317f.setVisibility(0);
this.n.setVisibility(0);
this.f7322k.setVisibility(0);
this.o.setVisibility(0);
this.t.setVisibility(0);
this.s.setVisibility(8);
this.f7320i.setVisibility(8);
this.q.setVisibility(8);
this.p.setVisibility(8);
this.r.setVisibility(8);
this.f7323l.setVisibility(8);
this.f7315d.setOnClickListener(this);
this.f7322k.setOnClickListener(this);
this.o.setOnClickListener(this);
this.r.setOnClickListener(this);
M1(true);
this.f7316e.setText("");
this.q.setLayoutManager(new LinearLayoutManager(this.f7612b));
this.f7317f.setSelected(false);
this.m.setSelected(false);
}
public static void E1(PUIPageActivity pUIPageActivity) {
Bundle bundle = new Bundle();
bundle.putString("email", com.iqiyi.psdk.base.b.i());
bundle.putInt("page_action_vcode", 2);
bundle.putBoolean("isSetPrimaryDeviceToBind", true);
pUIPageActivity.b1(org.qiyi.android.video.ui.account.a.INSPECT_SAFE_PAGE.ordinal(), bundle);
}
private void F1(String str) {
Bundle bundle = new Bundle();
bundle.putString("action", "webview");
bundle.putString("title", this.f7612b.getString(R$string.psdk_onlie_device));
bundle.putString(QYVerifyConstants.IntentExtra.kUrl, str);
com.iqiyi.psdk.base.a.f().k(bundle);
}
private void G1() {
com.iqiyi.psdk.base.j.g.d("devmng-mainop", "Passport", C1());
if (u1(this.f7612b)) {
O1(com.iqiyi.psdk.base.b.m(), 24);
}
}
private void H1() {
com.iqiyi.psdk.base.j.g.d("devlock-op", "Passport", C1());
PUIPageActivity pUIPageActivity = this.f7612b;
pUIPageActivity.Q0(pUIPageActivity.getString(R$string.psdk_loading_wait));
MdeviceApiNew.openDeviceProtect(new h());
}
public void I1() {
com.iqiyi.passportsdk.x.h.y().t0("");
f.h.b.e.c.f(this.f7612b);
if (!com.iqiyi.psdk.base.a.m()) {
this.f7612b.finish();
} else {
A1();
}
}
public void J1() {
D1();
com.iqiyi.passportsdk.mdevice.f.a aVar = this.v;
if (aVar == null) {
com.iqiyi.passportsdk.utils.e.b("PhonePrimaryDeviceUI", "refreshView: mDeviceInfo is null");
return;
}
int e2 = aVar.e();
com.iqiyi.passportsdk.utils.e.b("PhonePrimaryDeviceUI", "refreshView: device type is " + e2);
if (e2 == 1) {
com.iqiyi.passportsdk.x.h.y().t0("1");
this.f7317f.setSelected(true);
this.f7316e.setText(getString(R$string.psdk_primary_device_is_current));
M1(false);
this.f7318g.setVisibility(8);
this.f7319h.setVisibility(8);
this.s.setVisibility(0);
a.c cVar = this.v.f6813d;
if (cVar != null && cVar.a == 1) {
this.f7323l.setVisibility(0);
this.t.setVisibility(8);
}
K1();
return;
}
if (e2 == 2) {
this.f7317f.setVisibility(8);
this.f7320i.setVisibility(0);
this.f7321j.setOnClickListener(this);
this.f7321j.setText(getString(R$string.psdk_account_as_primary_device));
this.f7316e.setText(getString(R$string.psdk_this_by_account_occupy, this.v.c()));
return;
}
if (e2 == 3 || e2 == 4) {
this.f7317f.setVisibility(8);
this.f7320i.setVisibility(0);
this.f7321j.setOnClickListener(this);
this.f7321j.setText(getString(R$string.psdk_device_as_primary_device));
this.f7316e.setText(getString(R$string.psdk_primary_device_is, this.v.d()));
this.f7322k.setVisibility(8);
this.o.setVisibility(8);
this.f7319h.setVisibility(8);
this.s.setVisibility(8);
this.t.setVisibility(8);
}
}
public void K1() {
a.d dVar;
com.iqiyi.passportsdk.mdevice.f.a aVar = this.v;
if (aVar != null && (dVar = aVar.f6812c) != null && dVar.a == 1) {
this.m.setSelected(true);
this.p.setVisibility(0);
this.q.setVisibility(0);
this.r.setVisibility(0);
this.n.setVisibility(8);
PUIPageActivity pUIPageActivity = this.f7612b;
pUIPageActivity.Q0(pUIPageActivity.getString(R$string.psdk_loading_wait));
MdeviceApiNew.getTrustDevice(new e());
return;
}
this.m.setSelected(false);
this.p.setVisibility(8);
this.q.setVisibility(8);
this.r.setVisibility(8);
this.n.setVisibility(0);
}
public void L1(com.iqiyi.passportsdk.mdevice.f.b bVar) {
com.iqiyi.pexui.mdevice.d dVar = this.u;
if (dVar == null) {
com.iqiyi.pexui.mdevice.d dVar2 = new com.iqiyi.pexui.mdevice.d(this.f7612b, bVar);
this.u = dVar2;
dVar2.y(this);
this.q.setAdapter(this.u);
return;
}
dVar.z(bVar);
this.u.h();
}
private void M1(boolean z) {
this.f7322k.setAlpha(z ? 0.3f : 1.0f);
this.o.setAlpha(z ? 0.3f : 1.0f);
this.t.setAlpha(z ? 0.3f : 1.0f);
this.f7322k.setEnabled(!z);
this.o.setEnabled(!z);
}
public void N1(com.iqiyi.passportsdk.mdevice.f.b bVar, boolean z) {
AddTrustDeviceDialog addTrustDeviceDialog = new AddTrustDeviceDialog();
addTrustDeviceDialog.M0(new k(z, addTrustDeviceDialog));
Bundle bundle = new Bundle();
bundle.putBoolean("init", z);
bundle.putParcelable("info", bVar);
addTrustDeviceDialog.setArguments(bundle);
addTrustDeviceDialog.w0(this.f7612b.o(), "AddTrustDeviceDialog");
}
public void O1(String str, int i2) {
P1(str, i2, null);
}
public void P1(String str, int i2, String str2) {
this.y = new VerifyCodeDialog();
this.w = i2;
Bundle bundle = new Bundle();
bundle.putString("phone", str);
bundle.putInt("type", i2);
b.C0197b c0197b = this.x;
if (c0197b != null) {
bundle.putString("key_to_delete_id", c0197b.a);
}
this.y.setArguments(bundle);
this.y.O0(new f(i2, str));
b.C0197b c0197b2 = this.x;
this.y.P0(i2, str, this.f7612b, this, str2, c0197b2 != null ? c0197b2.a : "");
}
public static void Q1(PUIPageActivity pUIPageActivity) {
if (u1(pUIPageActivity)) {
pUIPageActivity.a1(org.qiyi.android.video.ui.account.a.PRIMARYDEVICE.ordinal());
}
}
private static boolean u1(PUIPageActivity pUIPageActivity) {
if (com.iqiyi.passportsdk.utils.l.Y0()) {
com.iqiyi.pui.dialog.a.m(pUIPageActivity, pUIPageActivity.getString(R$string.psdk_account_phonenumber_root), null, "");
return false;
}
if (!com.iqiyi.psdk.base.j.k.h0(com.iqiyi.psdk.base.b.m())) {
return true;
}
com.iqiyi.pui.dialog.a.k(pUIPageActivity, pUIPageActivity.getString(R$string.psdk_phone_my_account_primarydevice_onlybind), pUIPageActivity.getString(R$string.psdk_btn_cancel), null, pUIPageActivity.getString(R$string.psdk_phone_my_account_primarydevice_bindbtn), new d(pUIPageActivity));
return false;
}
private void v1() {
com.iqiyi.psdk.base.j.g.d("devmng-maincls", "Passport", C1());
com.iqiyi.pui.dialog.a.d(this.f7612b, getString(R$string.psdk_phone_my_account_mustchangepsw0), getString(R$string.psdk_primarydevice_close_warn), getString(R$string.psdk_continue_close), new g(), getString(R$string.psdk_keep_on), null, "devmng-maincls-pop");
}
private void w1() {
com.iqiyi.pui.dialog.a.l(this.f7612b, getString(R$string.psdk_phone_my_account_mustchangepsw0), getString(R$string.psdk_protect_close_warn), getString(R$string.psdk_continue_close), new i(), getString(R$string.psdk_keep_on), null);
}
public void x1() {
PUIPageActivity pUIPageActivity = this.f7612b;
pUIPageActivity.Q0(pUIPageActivity.getString(R$string.psdk_loading_wait));
MdeviceApiNew.closeDeviceProtect(new l());
}
public void y1(String str, String str2, String str3, VerifyCodeDialog verifyCodeDialog) {
this.f7612b.Q0(getString(R$string.psdk_loading_wait));
MdeviceApiNew.deleteDevice(this.x.a, str, str2, str3, new c(verifyCodeDialog));
}
private void z1() {
this.f7315d = (LinearLayout) this.f7314c.findViewById(R$id.ll_primary_device_switch);
this.f7316e = (TextView) this.f7314c.findViewById(R$id.tv_primary_device_detail_text);
this.f7317f = (ImageView) this.f7314c.findViewById(R$id.iv_primary_device_switch);
TextView textView = (TextView) this.f7314c.findViewById(R$id.tv_psdk_primary_device_tips);
this.f7318g = textView;
f.h.b.e.c.m(textView);
this.f7319h = (TextView) this.f7314c.findViewById(R$id.tv_need_open_tips);
this.f7321j = (TextView) this.f7314c.findViewById(R$id.tv_set_primary_device);
this.f7320i = (LinearLayout) this.f7314c.findViewById(R$id.ll_set_primary_device);
TextView textView2 = (TextView) this.f7314c.findViewById(R$id.tv_online_device);
this.f7322k = textView2;
f.h.b.e.c.w(textView2);
this.f7323l = (LinearLayout) this.f7314c.findViewById(R$id.ll_device_overlimit_warn);
this.m = (TextView) this.f7314c.findViewById(R$id.tv_device_lock);
this.n = (TextView) this.f7314c.findViewById(R$id.tv_open_device_lock_tip);
this.o = (LinearLayout) this.f7314c.findViewById(R$id.ll_device_lock);
this.p = (TextView) this.f7314c.findViewById(R$id.tv_trust_list_title);
RecyclerView recyclerView = (RecyclerView) this.f7314c.findViewById(R$id.rcv_protect_device);
this.q = recyclerView;
f.h.b.e.c.m(recyclerView);
this.r = (LinearLayout) this.f7314c.findViewById(R$id.ll_add_protect_device);
this.s = (PLL) this.f7314c.findViewById(R$id.line1);
this.t = (PLL) this.f7314c.findViewById(R$id.line2);
ImageView imageView = (ImageView) this.f7314c.findViewById(R$id.iv_add_protect_device);
if (com.iqiyi.psdk.base.g.a.g()) {
int i2 = com.iqiyi.psdk.base.j.k.i(com.iqiyi.psdk.base.g.a.d(21.0f, 23.0f, 27.0f));
imageView.getLayoutParams().width = i2;
imageView.getLayoutParams().height = i2;
}
}
@Override
public void l0(b.C0197b c0197b) {
com.iqiyi.pui.dialog.a.d(this.f7612b, getString(R$string.psdk_delete_device), getString(R$string.psdk_delete_device_warn, c0197b.f6821b), getString(R$string.psdk_phone_my_account_cancel), null, getString(R$string.psdk_delete_device_continue), new b(c0197b), null);
}
@Override
public void onActivityResult(int i2, int i3, Intent intent) {
if (i2 == 9494 && i3 == -1) {
P1(com.iqiyi.psdk.base.b.m(), this.w, intent != null ? intent.getStringExtra(QYVerifyConstants.PingbackKeys.kToken) : null);
}
}
@Override
@SensorsDataInstrumented
public void onClick(View view) {
int id = view.getId();
if (id == R$id.ll_primary_device_switch) {
com.iqiyi.passportsdk.mdevice.f.a aVar = this.v;
if (aVar != null && aVar.e() != 1) {
G1();
} else if (this.v != null) {
v1();
} else {
I1();
}
} else if (id == R$id.tv_online_device) {
if (!com.iqiyi.psdk.base.j.k.k0(this.f7612b) && !com.iqiyi.psdk.base.j.k.s0(this.f7612b)) {
this.f7612b.a1(org.qiyi.android.video.ui.account.a.ONLINE_DEVICE.ordinal());
} else {
F1("https://www.iqiyi.com/mobile/online-devices.html");
}
} else if (id == R$id.tv_set_primary_device) {
if (u1(this.f7612b)) {
O1(com.iqiyi.psdk.base.b.m(), 25);
}
} else if (id == R$id.ll_device_lock) {
if (this.m.isSelected()) {
com.iqiyi.psdk.base.j.g.d("devlock-cls", "Passport", C1());
w1();
} else {
H1();
}
} else if (id == R$id.ll_add_protect_device) {
com.iqiyi.psdk.base.j.g.d("devlock-addcnf", "Passport", C1());
B1();
}
SensorsDataAutoTrackHelper.trackViewOnClick(view);
}
@Override
public void onHiddenChanged(boolean z) {
super.onHiddenChanged(z);
if (!z) {
I1();
}
VerifyCodeDialog verifyCodeDialog = this.y;
if (verifyCodeDialog == null || !verifyCodeDialog.isAdded()) {
return;
}
this.y.m0();
}
@Override
public void onResume() {
super.onResume();
if (!this.z) {
I1();
}
this.z = false;
}
@Override
public void onViewCreated(View view, Bundle bundle) {
super.onViewCreated(view, bundle);
this.f7314c = view;
z1();
D1();
com.iqiyi.psdk.base.j.g.r(C1());
I1();
f.h.d.i.b.a(this.f7612b);
f.h.b.e.c.o(this.f7314c);
}
@Override
protected int q0() {
return R$layout.psdk_primarydevice_new;
}
}