OurPlay v5.5.9版本的 MD5 值为:d4e139798f4c2243a1145c8af5e21046
以下内容为反编译后的 b.java 源代码,内容仅作参考
package com.excelliance.kxqp.gs.j;
import android.app.Dialog;
import android.content.Context;
import android.content.Intent;
import android.os.Build;
import android.os.Handler;
import android.text.TextUtils;
import android.util.Log;
import android.view.View;
import androidx.core.app.NotificationManagerCompat;
import androidx.room.RoomDatabase;
import com.excelliance.kxqp.GameUtil;
import com.excelliance.kxqp.VersionManager;
import com.excelliance.kxqp.gs.bean.GoodsBean;
import com.excelliance.kxqp.gs.bean.VipGoodsBean;
import com.excelliance.kxqp.gs.bean.VipGoodsBeanWrapper;
import com.excelliance.kxqp.gs.dialog.f;
import com.excelliance.kxqp.gs.g.aa;
import com.excelliance.kxqp.gs.listener.h;
import com.excelliance.kxqp.gs.listener.i;
import com.excelliance.kxqp.gs.main.MainActivity;
import com.excelliance.kxqp.gs.sdk.a.a;
import com.excelliance.kxqp.gs.sdk.a.d;
import com.excelliance.kxqp.gs.thpool.tp;
import com.excelliance.kxqp.gs.ui.gaccount.GAccountActivity;
import com.excelliance.kxqp.gs.ui.gameaccount.BuyGameAccountActivity;
import com.excelliance.kxqp.gs.ui.googlecard.bean.CardBean;
import com.excelliance.kxqp.gs.util.ab;
import com.excelliance.kxqp.gs.util.as;
import com.excelliance.kxqp.gs.util.az;
import com.excelliance.kxqp.gs.util.bx;
import com.excelliance.kxqp.gs.util.by;
import com.excelliance.kxqp.gs.util.bz;
import com.excelliance.kxqp.gs.util.cd;
import com.excelliance.kxqp.gs.util.cg;
import com.excelliance.kxqp.gs.util.w;
import com.excelliance.kxqp.gs.zhifu.c;
import com.excelliance.kxqp.sdk.StatisticsGS;
import com.excelliance.kxqp.task.model.AliOrderItem;
import com.excelliance.kxqp.task.model.ResponseData;
import com.excelliance.kxqp.task.model.WechatOrderItem;
import com.excelliance.kxqp.task.model.YLOderItem;
import com.tencent.connect.common.Constants;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.net.HttpURLConnection;
import java.net.URL;
import java.net.URLConnection;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.List;
import org.json.JSONObject;
public class b extends com.excelliance.kxqp.gs.j.c<h.b> {
private int f6488b;
private String c;
private int d;
private Context e;
private com.excelliance.kxqp.gs.zhifu.c f;
private InterfaceC0243b g;
private c.InterfaceC0490c h;
private io.reactivex.b.b i;
private i j;
private int k;
private float l;
private GoodsBean m;
private int n;
public interface InterfaceC0243b {
void a(int i, int i2, int i3);
}
public b(Context context) {
this(context, 4);
}
public b(Context context, int i) {
this.e = context;
this.j = i.a();
this.k = i;
Log.d("PayPresenter", "PayPresenter: mCurrentPayment::" + this.k);
this.f = new com.excelliance.kxqp.gs.zhifu.c(this.e);
if (this.j != null) {
com.chinaums.pppay.a.b.a(context).a(this.j);
}
this.i = com.excelliance.kxqp.bitmap.ui.b.a().a(d.class).b((io.reactivex.d.d) new io.reactivex.d.d<d>() {
@Override
public void accept(d dVar) throws Exception {
String str = dVar.f6515a;
String str2 = dVar.f6516b;
int i2 = dVar.c;
az.d("PayPresenter", " accept: currentPayment::" + i2 + ",mCurrentPayment:" + b.this.k);
if (TextUtils.isEmpty(str) || TextUtils.isEmpty(str2) || b.this.k != i2) {
return;
}
b.this.a(str, str2, i2);
}
});
}
public void a(int i) {
this.k = i;
if (this.j != null) {
this.j.a(i);
}
}
public void a(Context context) {
StringBuilder sb = new StringBuilder();
sb.append("checkUnifyPayPluginCallBack: UnifyPayPlugin.getInstance(context).getListener() == null ");
sb.append(com.chinaums.pppay.a.b.a(context).a() == null);
Log.d("PayPresenter", sb.toString());
if (com.chinaums.pppay.a.b.a(context).a() == null) {
if (this.j != null) {
com.chinaums.pppay.a.b.a(context).a(this.j);
} else {
this.j = i.a();
com.chinaums.pppay.a.b.a(context).a(this.j);
}
}
}
public int a() {
return this.k;
}
public void a(CardBean cardBean, int i) {
double totalMoney = cardBean.getTotalMoney();
int a2 = com.excelliance.kxqp.gs.sdk.a.a.b.a(new int[]{cardBean.getOrderNum(), cardBean.getCid(), 3});
Log.d("PayPresenter", "toGoogleCardPay flag: " + a2 + " totalMoney: " + totalMoney + " orderedCard: " + cardBean);
a(a2, i, String.valueOf(totalMoney));
}
public void a(int i, int i2, double d2, int i3, int i4, int i5) {
a(i, i2, d2, i3, i4, i5, "");
}
public void a(int i, int i2, double d2, int i3, int i4, int i5, String str) {
int[] iArr = new int[3];
iArr[0] = i3;
iArr[1] = i2;
if (i5 <= 0) {
iArr[2] = 4;
} else {
iArr[2] = i5;
}
a(com.excelliance.kxqp.gs.sdk.a.a.b.a(iArr), i, String.valueOf(cd.a(d2, 2)), i4, i5, i2, str);
}
public void a(int i, int i2, double d2) {
a(com.excelliance.kxqp.gs.sdk.a.a.b.a(new int[]{i2, 5}), i, String.valueOf(d2));
}
public static boolean a(Context context, int i, int i2, float f) {
return ((float) Math.round((Float.parseFloat(c(com.excelliance.kxqp.gs.sdk.a.a.b.b(i, i2))) - f) * 100.0f)) / 100.0f > 0.0f;
}
public void a(int i, int i2, int i3, float f) {
if (a(this.e, i2, i3, f)) {
a(com.excelliance.kxqp.gs.sdk.a.a.b.b(i2, i3), i, String.valueOf(Math.round((Float.parseFloat(c(r3)) - f) * 100.0f) / 100.0f));
}
}
public void a(int i, int i2) {
int o = com.excelliance.kxqp.gs.sdk.a.a.b.o(i2);
a(o, i, b(o));
}
public void b(int i, int i2) {
a(i, i2, (String) null);
}
public void a(int i, int i2, String str) {
a(i, i2, str, 0, 0, "");
}
public void a(int i, int i2, String str, int i3, int i4, String str2) {
a(i, i2, str, i3, i4, 1, str2);
}
public void a(int i, int i2, String str, int i3, int i4, int i5, String str2) {
StringBuilder sb = new StringBuilder();
sb.append("toPay payType: ");
sb.append(i2);
sb.append(" totalMoney: ");
String str3 = str;
sb.append(str);
sb.append(" goodsid: ");
sb.append(i3);
sb.append(" gtype:");
sb.append(i4);
sb.append(" count:");
sb.append(i5);
sb.append(" flag:");
sb.append(i);
az.d("PayPresenter", sb.toString());
if (i_()) {
Context context = ((h.b) this.f6517a.get()).getContext();
this.f6488b = i;
switch (i2) {
case 1:
String str4 = null;
if (!com.excelliance.kxqp.gs.sdk.a.a.b.a(i)) {
if (com.excelliance.kxqp.gs.sdk.a.a.b.b(i)) {
str4 = i(i);
} else if (!com.excelliance.kxqp.gs.sdk.a.a.b.c(i)) {
if (!com.excelliance.kxqp.gs.sdk.a.a.b.d(i)) {
if (!com.excelliance.kxqp.gs.sdk.a.a.b.e(i)) {
if (!com.excelliance.kxqp.gs.sdk.a.a.b.f(i)) {
if (!com.excelliance.kxqp.gs.sdk.a.a.b.g(i)) {
break;
}
}
}
}
}
str3 = str4;
}
Log.d("PayPresenter", "toPay money: " + str3);
if (!TextUtils.isEmpty(str3)) {
a(i, context, str3, i3, i4, i5, str2);
}
this.n = i2;
return;
case 2:
a(context, i, str, i3, i4, i5, str2);
this.n = i2;
return;
case 3:
b(context, i, str, i3, i4, i5, str2);
this.n = i2;
return;
case 4:
c(context, i, str, i3, i4, i5, str2);
this.n = i2;
return;
default:
return;
}
}
}
public void a(final GoodsBean goodsBean) {
tp.f(new Runnable() {
@Override
public void run() {
b.this.n = 3;
b.this.n = goodsBean.payMethod;
if (TextUtils.isEmpty(goodsBean.getVtype())) {
goodsBean.setVtype(String.valueOf(goodsBean.flag));
}
b.this.m = goodsBean;
YLOderItem a2 = b.this.f.a(goodsBean, b.this.h, "");
b.this.l = a2.actualPrice;
b.this.j.a(b.this.k);
}
});
}
public GoodsBean b() {
return this.m;
}
private void a(final Context context, final int i, final String str, final int i2, final int i3, final int i4, final String str2) {
final com.excelliance.kxqp.gs.sdk.a.d dVar;
boolean z;
az.d("PayPresenter", "wchatPay");
try {
dVar = new com.excelliance.kxqp.gs.sdk.a.d(context);
} catch (Exception e) {
e = e;
}
try {
c cVar = new c();
if (!com.excelliance.kxqp.gs.sdk.a.a.b.g(i) && !com.excelliance.kxqp.gs.sdk.a.a.b.d(i) && !com.excelliance.kxqp.gs.sdk.a.a.b.h(i)) {
z = false;
cVar.a(z);
dVar.a(cVar);
tp.f(new Runnable() {
@Override
public void run() {
ResponseData<VipGoodsBeanWrapper> a2;
int i5 = i3;
int i6 = i2;
if (i5 == 0) {
i5 = com.excelliance.kxqp.gs.sdk.a.a.a.i(i);
}
if (i6 == 0 && com.excelliance.kxqp.gs.sdk.a.a.b.c(i)) {
i6 = com.excelliance.kxqp.gs.sdk.a.a.b.a(i, 2);
}
if ((i6 == 0 || i5 == 0) && (a2 = com.excelliance.kxqp.gs.ui.pay.e.a(context).a(2)) != null && a2.data != null) {
List<VipGoodsBean> list = a2.data.list;
int size = list.size();
for (int i7 = 0; i7 < size; i7++) {
VipGoodsBean vipGoodsBean = list.get(i7);
az.d("PayPresenter", "wchatPay queryVipGoodsList: getFlag = " + vipGoodsBean.getFlag() + ", getId = " + vipGoodsBean.getId() + ", getGoodsType = " + vipGoodsBean.getGoodsType() + ", flag = " + i);
if (vipGoodsBean.flag == i) {
vipGoodsBean.getId();
if (i6 == 0) {
try {
i6 = Integer.parseInt(vipGoodsBean.getId());
} catch (Exception unused) {
}
}
if (i5 == 0) {
i5 = vipGoodsBean.getGoodsType();
}
}
}
}
int i8 = i5;
int i9 = i6;
az.d("PayPresenter", "wchatPay flag = " + i + ", gId = " + i9 + ", orderType = " + i8);
WechatOrderItem b2 = b.this.f.b(str, i9, i8, i, i4, str2);
StringBuilder sb = new StringBuilder();
sb.append("wchatPay orderInfo: ");
sb.append(b2);
az.d("PayPresenter", sb.toString());
b.this.l = b2.actualPrice;
try {
if (b2 != null) {
if (com.excelliance.kxqp.gs.sdk.a.a.b.g(i) || com.excelliance.kxqp.gs.sdk.a.a.b.d(i)) {
bz.a().a(context, 159000, 3, "GP账号页面-吊起微信");
}
az.d("PayPresenter", "wchatPay orderInfo: " + b2.appId + ", partnerId = " + b2.partnerId + ", prepayId = " + b2.prepayId + ", nonceStr = " + b2.nonceStr + ", timeStamp = " + b2.timeStamp + ", packageValue = " + b2.packageValue + ", sign = " + b2.sign + ", extData = " + b2.extData);
dVar.a(b2.appId, b2.partnerId, b2.prepayId, b2.nonceStr, b2.timeStamp, b2.packageValue, b2.sign, b2.extData);
return;
}
cg.a(context, "Order Info Error");
} catch (Exception e2) {
Log.e("PayPresenter", "wchatPay toPay error:" + e2);
}
}
});
}
z = true;
cVar.a(z);
dVar.a(cVar);
tp.f(new Runnable() {
@Override
public void run() {
ResponseData<VipGoodsBeanWrapper> a2;
int i5 = i3;
int i6 = i2;
if (i5 == 0) {
i5 = com.excelliance.kxqp.gs.sdk.a.a.a.i(i);
}
if (i6 == 0 && com.excelliance.kxqp.gs.sdk.a.a.b.c(i)) {
i6 = com.excelliance.kxqp.gs.sdk.a.a.b.a(i, 2);
}
if ((i6 == 0 || i5 == 0) && (a2 = com.excelliance.kxqp.gs.ui.pay.e.a(context).a(2)) != null && a2.data != null) {
List<VipGoodsBean> list = a2.data.list;
int size = list.size();
for (int i7 = 0; i7 < size; i7++) {
VipGoodsBean vipGoodsBean = list.get(i7);
az.d("PayPresenter", "wchatPay queryVipGoodsList: getFlag = " + vipGoodsBean.getFlag() + ", getId = " + vipGoodsBean.getId() + ", getGoodsType = " + vipGoodsBean.getGoodsType() + ", flag = " + i);
if (vipGoodsBean.flag == i) {
vipGoodsBean.getId();
if (i6 == 0) {
try {
i6 = Integer.parseInt(vipGoodsBean.getId());
} catch (Exception unused) {
}
}
if (i5 == 0) {
i5 = vipGoodsBean.getGoodsType();
}
}
}
}
int i8 = i5;
int i9 = i6;
az.d("PayPresenter", "wchatPay flag = " + i + ", gId = " + i9 + ", orderType = " + i8);
WechatOrderItem b2 = b.this.f.b(str, i9, i8, i, i4, str2);
StringBuilder sb = new StringBuilder();
sb.append("wchatPay orderInfo: ");
sb.append(b2);
az.d("PayPresenter", sb.toString());
b.this.l = b2.actualPrice;
try {
if (b2 != null) {
if (com.excelliance.kxqp.gs.sdk.a.a.b.g(i) || com.excelliance.kxqp.gs.sdk.a.a.b.d(i)) {
bz.a().a(context, 159000, 3, "GP账号页面-吊起微信");
}
az.d("PayPresenter", "wchatPay orderInfo: " + b2.appId + ", partnerId = " + b2.partnerId + ", prepayId = " + b2.prepayId + ", nonceStr = " + b2.nonceStr + ", timeStamp = " + b2.timeStamp + ", packageValue = " + b2.packageValue + ", sign = " + b2.sign + ", extData = " + b2.extData);
dVar.a(b2.appId, b2.partnerId, b2.prepayId, b2.nonceStr, b2.timeStamp, b2.packageValue, b2.sign, b2.extData);
return;
}
cg.a(context, "Order Info Error");
} catch (Exception e2) {
Log.e("PayPresenter", "wchatPay toPay error:" + e2);
}
}
});
} catch (Exception e2) {
e = e2;
e.printStackTrace();
Log.e("PayPresenter", "wchatPay reflect to pay error...");
}
}
private void b(final Context context, final int i, String str, final int i2, final int i3, final int i4, final String str2) {
az.d("PayPresenter", "wechatYlPay");
try {
tp.f(new Runnable() {
@Override
public void run() {
ResponseData<VipGoodsBeanWrapper> a2;
int i5 = i3;
int i6 = i2;
if (i5 == 0) {
i5 = com.excelliance.kxqp.gs.sdk.a.a.a.i(i);
}
if (i6 == 0 && com.excelliance.kxqp.gs.sdk.a.a.b.c(i)) {
i6 = com.excelliance.kxqp.gs.sdk.a.a.b.a(i, 2);
}
if ((i6 == 0 || i5 == 0) && (a2 = com.excelliance.kxqp.gs.ui.pay.e.a(context).a(2)) != null && a2.data != null) {
List<VipGoodsBean> list = a2.data.list;
int size = list.size();
for (int i7 = 0; i7 < size; i7++) {
VipGoodsBean vipGoodsBean = list.get(i7);
az.d("PayPresenter", "wechatYlPay queryVipGoodsList: getFlag = " + vipGoodsBean.getFlag() + ", getId = " + vipGoodsBean.getId() + ", getGoodsType = " + vipGoodsBean.getGoodsType() + ", flag = " + i);
if (vipGoodsBean.flag == i) {
vipGoodsBean.getId();
if (i6 == 0) {
try {
i6 = Integer.parseInt(vipGoodsBean.getId());
} catch (Exception unused) {
}
}
if (i5 == 0) {
i5 = vipGoodsBean.getGoodsType();
}
}
}
}
az.d("PayPresenter", "wechatYlPay flag = " + i + ", gId = " + i6 + ", orderType = " + i5);
GoodsBean goodsBean = new GoodsBean();
goodsBean.count = i4;
goodsBean.goodsType = i5;
goodsBean.vtype = String.valueOf(i);
goodsBean.id = String.valueOf(i2);
goodsBean.payMethod = 3;
az.d("PayPresenter", "payYL count " + i4 + " goodsType:" + goodsBean.goodsType + " vtype:" + goodsBean.vtype + " id:" + goodsBean.id + " payMethod:" + goodsBean.payMethod);
if (com.excelliance.kxqp.gs.sdk.a.a.b.g(i) || com.excelliance.kxqp.gs.sdk.a.a.b.d(i)) {
bz.a().a(context, 159000, 3, "GP账号页面-吊起微信");
}
b.this.l = b.this.f.a(goodsBean, b.this.h, str2).actualPrice;
b.this.j.a(b.this.k);
}
});
} catch (Exception e) {
e.printStackTrace();
Log.e("PayPresenter", "wechatYlPay reflect to pay error...");
}
}
private void c(final Context context, final int i, String str, final int i2, final int i3, final int i4, final String str2) {
az.d("PayPresenter", "aliYlPay");
try {
tp.f(new Runnable() {
@Override
public void run() {
ResponseData<VipGoodsBeanWrapper> a2;
int i5 = i3;
int i6 = i2;
if (i5 == 0) {
i5 = com.excelliance.kxqp.gs.sdk.a.a.a.i(i);
}
if (i6 == 0 && com.excelliance.kxqp.gs.sdk.a.a.b.c(i)) {
i6 = com.excelliance.kxqp.gs.sdk.a.a.b.a(i, 2);
}
if ((i6 == 0 || i5 == 0) && (a2 = com.excelliance.kxqp.gs.ui.pay.e.a(context).a(2)) != null && a2.data != null) {
List<VipGoodsBean> list = a2.data.list;
int size = list.size();
for (int i7 = 0; i7 < size; i7++) {
VipGoodsBean vipGoodsBean = list.get(i7);
az.d("PayPresenter", "aliYlPay queryVipGoodsList: getFlag = " + vipGoodsBean.getFlag() + ", getId = " + vipGoodsBean.getId() + ", getGoodsType = " + vipGoodsBean.getGoodsType() + ", flag = " + i);
if (vipGoodsBean.flag == i) {
vipGoodsBean.getId();
if (i6 == 0) {
try {
i6 = Integer.parseInt(vipGoodsBean.getId());
} catch (Exception unused) {
}
}
if (i5 == 0) {
i5 = vipGoodsBean.getGoodsType();
}
}
}
}
az.d("PayPresenter", "aliYlPay flag = " + i + ", gId = " + i6 + ", orderType = " + i5);
GoodsBean goodsBean = new GoodsBean();
goodsBean.count = i4;
goodsBean.goodsType = i5;
goodsBean.vtype = String.valueOf(i);
goodsBean.id = String.valueOf(i2);
goodsBean.payMethod = 4;
az.d("PayPresenter", "aliYlPay count " + i4 + " goodsType:" + goodsBean.goodsType + " vtype:" + goodsBean.vtype + " id:" + goodsBean.id + " payMethod:" + goodsBean.payMethod);
if (com.excelliance.kxqp.gs.sdk.a.a.b.g(i) || com.excelliance.kxqp.gs.sdk.a.a.b.d(i)) {
bz.a().a(context, 159000, 3, "GP账号页面-吊起支付宝");
}
b.this.l = b.this.f.a(goodsBean, b.this.h, str2).actualPrice;
b.this.j.a(b.this.k);
}
});
} catch (Exception e) {
e.printStackTrace();
Log.e("PayPresenter", "aliYlPay reflect to pay error...");
}
}
private void a(final int i, final Context context, final String str, final int i2, final int i3, final int i4, final String str2) {
final String k = k(i);
final String a2 = a(i, context);
final String f = VersionManager.getInstance().f();
final String a3 = bx.a().a(context);
try {
h_().showProgress(w.e(context, "vip_alipay_loading"));
tp.f(new Runnable() {
@Override
public void run() {
ResponseData<VipGoodsBeanWrapper> a4;
int i5 = i3;
int i6 = i2;
if (i5 == 0) {
i5 = com.excelliance.kxqp.gs.sdk.a.a.a.i(i);
}
if (i6 == 0 && com.excelliance.kxqp.gs.sdk.a.a.b.c(i)) {
i6 = com.excelliance.kxqp.gs.sdk.a.a.b.a(i, 2);
}
if ((i6 == 0 || i5 == 0) && (a4 = com.excelliance.kxqp.gs.ui.pay.e.a(context).a(2)) != null && a4.data != null) {
List<VipGoodsBean> list = a4.data.list;
int size = list.size();
for (int i7 = 0; i7 < size; i7++) {
VipGoodsBean vipGoodsBean = list.get(i7);
az.d("PayPresenter", "alipay queryVipGoodsList: getFlag = " + vipGoodsBean.getFlag() + ", getId = " + vipGoodsBean.getId() + ", getGoodsType = " + vipGoodsBean.getGoodsType() + ", flag = " + i);
if (vipGoodsBean.flag == i) {
vipGoodsBean.getId();
if (i6 == 0) {
try {
i6 = Integer.parseInt(vipGoodsBean.getId());
} catch (Exception unused) {
}
}
if (i5 == 0) {
i5 = vipGoodsBean.getGoodsType();
}
}
}
}
int i8 = i5;
int i9 = i6;
az.d("PayPresenter", "alipay orderType: " + i8 + ", gId = " + i9 + ", flag = " + i);
if ((a3 != null && !"".equals(a3)) || !com.excelliance.kxqp.gs.sdk.a.a.b.a(i)) {
AliOrderItem a5 = b.this.f.a(str, i9, i8, i, i4, str2);
b.this.l = a5.actualPrice;
String str3 = a5.order;
az.d("PayPresenter", "alipay orderInfo: " + str3);
try {
a aVar = new a();
com.excelliance.kxqp.gs.sdk.a.a aVar2 = new com.excelliance.kxqp.gs.sdk.a.a(context, str, i);
if (com.excelliance.kxqp.gs.sdk.a.a.b.g(i) || com.excelliance.kxqp.gs.sdk.a.a.b.d(i)) {
bz.a().a(context, 159000, 1, "GP账号页面-吊起支付宝");
aVar.a(true);
}
if (str3 != null && str3.length() > 0) {
aVar2.c(a2).b(k).d(f).e(a3).a(aVar).a().a(str3);
return;
} else {
cg.a(context, "Order Info Error");
return;
}
} catch (Exception e) {
Log.e("PayPresenter", "alipay toPay error:" + e);
return;
}
}
az.d("PayPresenter", "Error with rid, cancel the VIP Order! rid info : " + a3);
cg.a(b.this.h_().getContext(), "账号异常,请尝试重新登录");
b.this.h_().showProgress(null);
}
});
} catch (Exception unused) {
Log.e("PayPresenter", "reflect to pay error...");
}
}
public class c implements d.a {
private boolean f6514b;
private c() {
this.f6514b = false;
}
public void a(boolean z) {
this.f6514b = z;
}
@Override
public void a(int i, String str) {
Log.d("PayPresenter", "result = " + i + ", payId = " + str);
String str2 = "";
if (b.this.g != null) {
b.this.g.a(i, 2, 4);
}
if (i == com.excelliance.kxqp.gs.sdk.a.b.f8108a) {
str2 = com.excelliance.kxqp.swipe.a.a.getString(b.this.e, "pay_over_success");
b.this.d(b.this.f6488b);
} else if (i == com.excelliance.kxqp.gs.sdk.a.b.f8109b) {
str2 = com.excelliance.kxqp.swipe.a.a.getString(b.this.e, "pay_cancel");
if (this.f6514b) {
bz.a().a(((h.b) b.this.f6517a.get()).getContext(), 159000, 4, "GP账号页面-吊起微信取消");
}
} else if (i == com.excelliance.kxqp.gs.sdk.a.b.c) {
str2 = com.excelliance.kxqp.swipe.a.a.getString(b.this.e, "pay_over_exception1");
}
if (TextUtils.isEmpty(str2)) {
return;
}
cg.a(b.this.e, str2);
}
}
private class a implements a.c {
private boolean f6512b;
private a() {
this.f6512b = false;
}
public void a(boolean z) {
this.f6512b = z;
}
@Override
public void a() {
b.this.h_().showProgress(null);
}
@Override
public void a(com.excelliance.kxqp.gs.sdk.a.c cVar) {
b.this.h_().showProgress(null);
String i = cVar.i();
String g = cVar.g();
String h = cVar.h();
String f = cVar.f();
az.d("PayPresenter", "onSuccess resultStatus: " + i + " sign: " + g + " content: " + h + " timestamp: " + f + " timestamp: " + f + " aliTrade: " + cVar.d() + " ourTrade: " + cVar.e() + " amount: " + cVar.c());
if (TextUtils.equals(i, "9000")) {
if (TextUtils.isEmpty(g) || TextUtils.isEmpty(h)) {
return;
}
if (b.this.g != null) {
b.this.g.a(com.excelliance.kxqp.gs.sdk.a.b.f8108a, 1, 4);
}
b.this.d(b.this.f6488b);
return;
}
if (TextUtils.equals(i, "8000") || TextUtils.equals(i, "6004")) {
b.this.h_().showProgress("vip_alipay_loading2");
b.this.d = 0;
b.this.h(b.this.f6488b);
} else {
if (TextUtils.equals(i, "6001")) {
if (b.this.g != null) {
b.this.g.a(com.excelliance.kxqp.gs.sdk.a.b.f8109b, 1, 4);
}
b.this.c("vip_exception_error");
if (this.f6512b) {
bz.a().a(((h.b) b.this.f6517a.get()).getContext(), 159000, 2, "GP账号页面-吊起支付宝取消");
return;
}
return;
}
if (b.this.g != null) {
b.this.g.a(com.excelliance.kxqp.gs.sdk.a.b.c, 1, 4);
}
b.this.c("vip_exception_error");
}
}
@Override
public void a(a.C0327a c0327a) {
String str;
az.d("PayPresenter", "onFail:" + c0327a.getMessage());
az.d("PayPresenter", "onFail:" + c0327a);
if ("sign error".equals(c0327a.getMessage())) {
str = "vip_exception_sign";
} else {
str = "net error".equals(c0327a.getMessage()) ? "vip_exception_net" : "vip_exception_error";
}
b.this.c(str);
}
}
public void d(int i) {
c("vip_success");
boolean b2 = bx.a().b(this.e);
if (com.excelliance.kxqp.gs.sdk.a.a.b.a(i)) {
bz.a().a(this.e, 34000, 3, "支付成功");
if (b2) {
g(i);
j(i);
e(i);
return;
}
as.a(this.e, true);
return;
}
if (com.excelliance.kxqp.gs.sdk.a.a.b.b(i)) {
f(i);
j(i);
e(i);
return;
}
if (com.excelliance.kxqp.gs.sdk.a.a.b.c(i)) {
return;
}
if (com.excelliance.kxqp.gs.sdk.a.a.b.d(i)) {
if (h_() != null) {
bz.a().l(h_().getContext());
h_().updateView();
return;
}
return;
}
if (com.excelliance.kxqp.gs.sdk.a.a.b.e(i)) {
h();
return;
}
if (com.excelliance.kxqp.gs.sdk.a.a.b.f(i)) {
if (h_() instanceof h.c) {
tp.i(new Runnable() {
@Override
public void run() {
((h.c) b.this.h_()).a("vip_success", null);
}
});
}
} else if (com.excelliance.kxqp.gs.sdk.a.a.b.g(i)) {
a(!b2);
} else if (com.excelliance.kxqp.gs.sdk.a.a.b.h(i)) {
a(!b2);
}
}
private void h() {
h.b bVar;
if (this.f6517a == null || (bVar = (h.b) this.f6517a.get()) == null) {
return;
}
bVar.updateView();
}
private void e(int i) {
Log.d("PayPresenter", "showGuideToShareDialog: " + i);
if (i_()) {
final Context context = h_().getContext();
final String str = "";
if (com.excelliance.kxqp.gs.sdk.a.a.b.b(i)) {
str = String.format(w.e(context, "flow_pay_suc_tips_format_text"), Integer.valueOf(com.excelliance.kxqp.gs.sdk.a.a.b.j(i)));
} else if (com.excelliance.kxqp.gs.sdk.a.a.b.a(i)) {
String e = w.e(context, "vip_pay_suc_tips_format_text");
String str2 = "";
if (com.excelliance.kxqp.gs.sdk.a.a.b.l(i)) {
str2 = w.e(context, "one_month");
} else if (com.excelliance.kxqp.gs.sdk.a.a.b.k(i)) {
str2 = w.e(context, "one_year");
}
str = String.format(e, str2);
}
Log.d("PayPresenter", "showGuideToShareDialog: " + str);
h_().getHandler().post(new Runnable() {
@Override
public void run() {
new f.b(context).d(w.e(context, "pay_success")).e(str).a(w.e(context, "confirm")).b(w.e(context, "share_get_bonus")).a(new f.a() {
@Override
public void a(View view, Dialog dialog) {
dialog.dismiss();
}
}).b(new f.a() {
@Override
public void a(View view, Dialog dialog) {
dialog.dismiss();
String m = GameUtil.m(context);
az.d("PayPresenter", "topActivity:" + m);
if ("com.excelliance.kxqp.gs.main.MainActivity".equals(m)) {
Intent intent = new Intent(context.getPackageName() + ".action.switch.fragment");
intent.putExtra("index", 1);
intent.putExtra("childIndex", 2);
context.sendBroadcast(intent);
return;
}
Intent intent2 = new Intent(context, (Class<?>) MainActivity.class);
intent2.putExtra("makeMoney", true);
context.startActivity(intent2);
}
}).b();
}
});
az.d("PayPresenter", "showGuideToShareDialog: end");
}
}
private void f(int i) {
az.d("PayPresenter", "markFastFlow:" + i);
if (i_()) {
StatisticsGS.getInstance().uploadUserAction(h_().getContext(), 120, i, 1);
com.excelliance.kxqp.gs.ui.flow.b.INSTANCE.a(h_().getContext(), "markTotalFastFlow", String.valueOf(com.excelliance.kxqp.gs.ui.flow.b.INSTANCE.b("markTotalFastFlow") + com.excelliance.kxqp.gs.sdk.a.a.b.j(i)));
}
}
private void a(boolean z) {
by.a(this.e, ".sp.common.disposable.flag.info").a("sp_key_should_show_bind_dialog_after_combine_bought", z);
}
public void g(final int i) {
if (i_()) {
try {
StatisticsGS.getInstance().uploadUserAction(h_().getContext(), 124, i, 1);
final Context context = h_().getContext();
tp.f(new Runnable() {
@Override
public void run() {
b.this.a(context, i);
}
});
} catch (Exception e) {
e.printStackTrace();
}
}
}
public void a(Context context, int i) {
long j;
int i2;
int i3;
String str;
StringBuilder sb;
int i4;
bx a2 = bx.a();
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
long parseLong = Long.parseLong(a2.t(context)) * 1000;
Calendar calendar = Calendar.getInstance();
try {
try {
URLConnection openConnection = new URL("http://ourplay.com.cn/").openConnection();
openConnection.connect();
calendar.setTimeInMillis(openConnection.getDate());
j = calendar.getTimeInMillis();
} catch (Throwable th) {
th = th;
j = 0;
}
} catch (Exception e) {
e = e;
}
try {
az.d("PayPresenter", "网络时间:" + simpleDateFormat.format(calendar.getTime()));
az.d("PayPresenter", "currentEndTime:" + parseLong + " netTime:" + j);
if (parseLong > j) {
az.d("PayPresenter", "还没过期,则直接延续");
calendar.clear();
calendar.setTimeInMillis(parseLong);
}
} catch (Exception e2) {
e = e2;
e.printStackTrace();
az.d("PayPresenter", "本地时间:" + simpleDateFormat.format(calendar.getTime()));
long currentTimeMillis = System.currentTimeMillis();
az.d("PayPresenter", "currentEndTime:" + parseLong + " netTime:" + currentTimeMillis);
if (parseLong > currentTimeMillis) {
az.d("PayPresenter", "还没过期,则直接延续");
calendar.clear();
calendar.setTimeInMillis(parseLong);
}
if (com.excelliance.kxqp.gs.sdk.a.a.b.a(i)) {
int a3 = com.excelliance.kxqp.gs.sdk.a.a.b.a(i, 2);
az.d("PayPresenter", "markNewEndTime dimensN: " + a3);
switch (a3) {
case 1:
i3 = 1;
az.d("PayPresenter", "加一个月");
calendar.add(2, 1);
break;
case 2:
i3 = 1;
az.d("PayPresenter", "加一年");
calendar.add(1, 1);
break;
case 3:
az.d("PayPresenter", "加一天");
i3 = 1;
calendar.add(5, 1);
break;
case 4:
calendar.add(2, 3);
i3 = 1;
break;
case 5:
calendar.add(2, 6);
i3 = 1;
break;
default:
i3 = 1;
break;
}
context.getSharedPreferences("USERINFO", Build.VERSION.SDK_INT < 11 ? 0 : 4);
aa.a(context).a(i3);
str = "PayPresenter";
sb = new StringBuilder();
sb.append("calendar.getTimeInMillis()");
sb.append(calendar.getTimeInMillis());
az.d(str, sb.toString());
a2.a(context, calendar.getTimeInMillis() / 1000);
h_().updateView();
}
return;
} catch (Throwable th2) {
th = th2;
az.d("PayPresenter", "currentEndTime:" + parseLong + " netTime:" + j);
if (parseLong > j) {
az.d("PayPresenter", "还没过期,则直接延续");
calendar.clear();
calendar.setTimeInMillis(parseLong);
}
if (com.excelliance.kxqp.gs.sdk.a.a.b.a(i)) {
int a4 = com.excelliance.kxqp.gs.sdk.a.a.b.a(i, 2);
az.d("PayPresenter", "markNewEndTime dimensN: " + a4);
switch (a4) {
case 1:
i2 = 1;
az.d("PayPresenter", "加一个月");
calendar.add(2, 1);
break;
case 2:
i2 = 1;
az.d("PayPresenter", "加一年");
calendar.add(1, 1);
break;
case 3:
az.d("PayPresenter", "加一天");
i2 = 1;
calendar.add(5, 1);
break;
case 4:
calendar.add(2, 3);
i2 = 1;
break;
case 5:
calendar.add(2, 6);
i2 = 1;
break;
default:
i2 = 1;
break;
}
context.getSharedPreferences("USERINFO", Build.VERSION.SDK_INT < 11 ? 0 : 4);
aa.a(context).a(i2);
az.d("PayPresenter", "calendar.getTimeInMillis()" + calendar.getTimeInMillis());
a2.a(context, calendar.getTimeInMillis() / 1000);
h_().updateView();
}
throw th;
}
if (com.excelliance.kxqp.gs.sdk.a.a.b.a(i)) {
int a5 = com.excelliance.kxqp.gs.sdk.a.a.b.a(i, 2);
az.d("PayPresenter", "markNewEndTime dimensN: " + a5);
switch (a5) {
case 1:
i4 = 1;
az.d("PayPresenter", "加一个月");
calendar.add(2, 1);
break;
case 2:
i4 = 1;
az.d("PayPresenter", "加一年");
calendar.add(1, 1);
break;
case 3:
az.d("PayPresenter", "加一天");
i4 = 1;
calendar.add(5, 1);
break;
case 4:
calendar.add(2, 3);
i4 = 1;
break;
case 5:
calendar.add(2, 6);
i4 = 1;
break;
default:
i4 = 1;
break;
}
context.getSharedPreferences("USERINFO", Build.VERSION.SDK_INT < 11 ? 0 : 4);
aa.a(context).a(i4);
str = "PayPresenter";
sb = new StringBuilder();
sb.append("calendar.getTimeInMillis()");
sb.append(calendar.getTimeInMillis());
az.d(str, sb.toString());
a2.a(context, calendar.getTimeInMillis() / 1000);
h_().updateView();
}
}
public void h(final int i) {
tp.f(new Runnable() {
@Override
public void run() {
try {
int[] i2 = b.this.i();
if (i2[0] <= 0 || i2[1] <= 0) {
b.this.c("vip_exception_unknow");
} else {
b.this.g(i);
b.this.c("vip_success");
}
} catch (Exception e) {
e.printStackTrace();
b.this.c("vip_exception_unknow");
}
}
});
}
public int[] i() {
int[] iArr = new int[2];
try {
Thread.sleep(2500L);
this.d++;
com.excelliance.kxqp.gs.sdk.a.c b2 = b(h_().getContext());
iArr[0] = b2.b();
iArr[1] = b2.a();
if ((iArr[0] <= 0 || iArr[1] <= 0) && this.d < 3) {
i();
}
} catch (Exception e) {
e.printStackTrace();
}
return iArr;
}
public com.excelliance.kxqp.gs.sdk.a.c b(Context context) throws Exception {
JSONObject jSONObject;
int optInt;
com.excelliance.kxqp.gs.sdk.a.c cVar = new com.excelliance.kxqp.gs.sdk.a.c();
GameUtil intance = GameUtil.getIntance();
intance.q(context);
VersionManager versionManager = VersionManager.getInstance();
versionManager.a(context);
GameUtil intance2 = GameUtil.getIntance();
intance2.q(context);
StringBuilder sb = new StringBuilder("https://sdk.ourplay.com.cn/alipay/alipayregrequest.php");
a(sb, "?sdkver=", Integer.valueOf(GameUtil.f(context)));
a(sb, "&vc=", Integer.valueOf(GameUtil.g(context)));
a(sb, "&vn=", GameUtil.h(context));
a(sb, "&compver=", versionManager.l());
a(sb, "&mainver=", intance.m());
a(sb, "&chid=", Integer.valueOf(GameUtil.d(context)));
a(sb, "&subchid=", Integer.valueOf(GameUtil.e(context)));
a(sb, "&uid=", versionManager.f());
a(sb, "&aid=", intance2.r(context));
a(sb, "&im=", intance2.v(context));
a(sb, "&rid=", bx.a().a(context));
Log.d("PayPresenter", "url:" + sb.toString());
String a2 = a(sb.toString());
Log.d("PayPresenter", "result:_" + a2);
if (!TextUtils.isEmpty(a2)) {
JSONObject jSONObject2 = new JSONObject(ab.a(a2, "utf-8"));
if (jSONObject2.length() > 0) {
String optString = jSONObject2.optString("alipay");
if (!TextUtils.isEmpty(optString) && (optInt = (jSONObject = new JSONObject(optString)).optInt("status")) != 0) {
int optInt2 = jSONObject.optInt("type");
cVar.a(jSONObject.optLong("time") + "");
cVar.b(optInt2);
cVar.a(optInt);
}
} else {
Log.d("PayPresenter", "jsonObject is null");
}
}
return cVar;
}
public String a(String str) throws Exception {
Throwable th;
HttpURLConnection httpURLConnection;
try {
httpURLConnection = (HttpURLConnection) new URL(str).openConnection();
try {
httpURLConnection.setRequestMethod("GET");
httpURLConnection.setReadTimeout(15000);
httpURLConnection.setConnectTimeout(15000);
if (httpURLConnection.getResponseCode() == 200) {
BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(httpURLConnection.getInputStream()));
StringBuffer stringBuffer = new StringBuffer();
while (true) {
String readLine = bufferedReader.readLine();
if (readLine == null) {
break;
}
stringBuffer.append(readLine);
}
String stringBuffer2 = stringBuffer.toString();
if (httpURLConnection != null) {
httpURLConnection.disconnect();
}
return stringBuffer2;
}
throw new Exception("responseCode !=200 ");
} catch (Throwable th2) {
th = th2;
if (httpURLConnection != null) {
httpURLConnection.disconnect();
}
throw th;
}
} catch (Throwable th3) {
th = th3;
httpURLConnection = null;
}
}
public void c(final String str) {
Handler handler;
if (i_() && (handler = h_().getHandler()) != null) {
handler.post(new Runnable() {
@Override
public void run() {
if (b.this.i_()) {
Context context = b.this.h_().getContext();
b.this.h_().showProgress(null);
String string = com.excelliance.kxqp.swipe.a.a.getString(context, str);
cg.a(context, string);
if ("vip_success".equals(str)) {
b.this.h_().updateView();
}
if (b.this.h_() instanceof h.c) {
((h.c) b.this.h_()).a(str, string);
}
}
}
});
}
}
private StringBuilder a(StringBuilder sb, String str, Object obj) {
if (sb == null || TextUtils.isEmpty(str) || TextUtils.isEmpty(String.valueOf(obj)) || String.valueOf(obj).equalsIgnoreCase("null")) {
return sb;
}
sb.append(str + obj);
return sb;
}
private StringBuilder a(StringBuilder sb, String str, String str2) {
if (sb == null || TextUtils.isEmpty(str) || TextUtils.isEmpty(str2) || str2.equalsIgnoreCase("null")) {
return sb;
}
sb.append(str + str2);
return sb;
}
public static String b(int i) {
if (com.excelliance.kxqp.gs.sdk.a.a.b.a(i)) {
int i2 = (i / 1000) & RoomDatabase.MAX_BIND_PARAMETER_CNT;
Log.d("PayPresenter", "caculateVipMoney: " + i2);
if (i2 == 1) {
return "28.8";
}
if (i2 == 2) {
return "188";
}
if (i2 == 3) {
return "0.1";
}
if (i2 == 4) {
return "78";
}
if (i2 == 5) {
return "128";
}
}
return null;
}
public static String c(int i) {
if (com.excelliance.kxqp.gs.sdk.a.a.b.a(i)) {
int i2 = (i / 1000) + NotificationManagerCompat.IMPORTANCE_UNSPECIFIED;
Log.d("PayPresenter", "caculateVipMoney: " + i2);
if (i2 == 1) {
return "28.8";
}
if (i2 == 2) {
return "188";
}
if (i2 == 3) {
return "0.1";
}
if (i2 == 4) {
return "78";
}
if (i2 == 5) {
return "128";
}
}
return null;
}
private String i(int i) {
if (com.excelliance.kxqp.gs.sdk.a.a.b.b(i)) {
int i2 = (i / 1000) & RoomDatabase.MAX_BIND_PARAMETER_CNT;
if (i2 == 1) {
return "1";
}
if (i2 == 2) {
return "3.98";
}
if (i2 == 3) {
return "6.8";
}
if (i2 == 4) {
return "16.8";
}
if (i2 == 5) {
return "50";
}
if (i2 == 6) {
return "0.1";
}
}
return null;
}
private void j(int i) {
if ((com.excelliance.kxqp.gs.sdk.a.a.b.m(i) || com.excelliance.kxqp.gs.sdk.a.a.b.l(i) || com.excelliance.kxqp.gs.sdk.a.a.b.k(i)) && i_()) {
bx.a().a(((h.b) this.f6517a.get()).getContext().getSharedPreferences("USERINFO", Build.VERSION.SDK_INT < 11 ? 0 : 4), "USER_FIRST_PAY", 2);
}
}
private String k(int i) {
if (com.excelliance.kxqp.gs.sdk.a.a.b.k(i)) {
return com.excelliance.kxqp.swipe.a.a.getString(this.e, "vip_alipay_title_quarter");
}
if (com.excelliance.kxqp.gs.sdk.a.a.b.l(i)) {
return com.excelliance.kxqp.swipe.a.a.getString(this.e, "vip_alipay_title_month");
}
if (com.excelliance.kxqp.gs.sdk.a.a.b.b(i)) {
return com.excelliance.kxqp.swipe.a.a.getString(this.e, "flow_alipay_title");
}
return com.excelliance.kxqp.gs.sdk.a.a.b.c(i) ? com.excelliance.kxqp.swipe.a.a.getString(this.e, "googlecard_alipay_title") : "OurPlay";
}
private String a(int i, Context context) {
return com.excelliance.kxqp.gs.sdk.a.a.b.a(i) ? com.excelliance.kxqp.swipe.a.a.getString(context, "vip_alipay_body") : "";
}
public void a(InterfaceC0243b interfaceC0243b) {
this.g = interfaceC0243b;
}
public void a(c.InterfaceC0490c interfaceC0490c) {
this.h = interfaceC0490c;
}
public void b(String str) {
this.c = str;
}
public void a(String str, String str2, int i) {
az.d("PayPresenter", "onResult resultCode=" + str + ", resultInfo=" + str2);
String str3 = "";
char c2 = 65535;
if (TextUtils.equals(str, "0000")) {
str3 = com.excelliance.kxqp.swipe.a.a.getString(this.e, "pay_over_success");
if (this.g != null) {
this.g.a(com.excelliance.kxqp.gs.sdk.a.b.f8108a, this.n, i);
}
Log.d("PayPresenter", "onResult: currentflag::" + this.f6488b);
if (com.excelliance.kxqp.gs.sdk.a.a.b.d(this.f6488b) || com.excelliance.kxqp.gs.sdk.a.a.b.g(this.f6488b) || com.excelliance.kxqp.gs.sdk.a.a.b.h(this.f6488b)) {
if (this.h != null) {
this.h.a(com.excelliance.kxqp.gs.sdk.a.b.f8108a);
}
if (h_() != null) {
bz.a().l(h_().getContext());
h_().updateView();
}
if (!j()) {
l();
}
} else if (com.excelliance.kxqp.gs.sdk.a.a.b.f(this.f6488b)) {
if (this.h != null) {
this.h.a(com.excelliance.kxqp.gs.sdk.a.b.f8108a);
}
if (h_() != null) {
h_().updateView();
}
if (!TextUtils.isEmpty(this.c)) {
String str4 = this.c;
int hashCode = str4.hashCode();
if (hashCode != -651787850) {
if (hashCode == 1488099780 && str4.equals("BuyGameAccountActivity")) {
c2 = 0;
}
} else if (str4.equals("GameMallFragment")) {
c2 = 1;
}
switch (c2) {
case 0:
l(1);
break;
case 1:
m();
break;
}
}
}
} else if (TextUtils.equals(str, Constants.DEFAULT_UIN)) {
str3 = com.excelliance.kxqp.swipe.a.a.getString(this.e, "pay_cancel");
if (this.g != null) {
this.g.a(com.excelliance.kxqp.gs.sdk.a.b.f8109b, this.n, i);
}
if (com.excelliance.kxqp.gs.sdk.a.a.b.d(this.f6488b) || com.excelliance.kxqp.gs.sdk.a.a.b.g(this.f6488b) || com.excelliance.kxqp.gs.sdk.a.a.b.h(this.f6488b)) {
if (TextUtils.isEmpty(this.c)) {
l();
} else {
String str5 = this.c;
int hashCode2 = str5.hashCode();
if (hashCode2 != -651787850) {
if (hashCode2 == 1488099780 && str5.equals("BuyGameAccountActivity")) {
c2 = 0;
}
} else if (str5.equals("GameMallFragment")) {
c2 = 1;
}
switch (c2) {
case 0:
l(0);
break;
case 1:
m();
break;
}
}
} else if (com.excelliance.kxqp.gs.sdk.a.a.b.f(this.f6488b)) {
k();
}
} else if (TextUtils.equals(str, "2003")) {
str3 = com.excelliance.kxqp.swipe.a.a.getString(this.e, "pay_over_exception1");
if (this.g != null) {
this.g.a(com.excelliance.kxqp.gs.sdk.a.b.c, this.n, i);
}
if (com.excelliance.kxqp.gs.sdk.a.a.b.d(this.f6488b) || com.excelliance.kxqp.gs.sdk.a.a.b.g(this.f6488b) || com.excelliance.kxqp.gs.sdk.a.a.b.h(this.f6488b)) {
if (TextUtils.isEmpty(this.c)) {
l();
} else {
String str6 = this.c;
int hashCode3 = str6.hashCode();
if (hashCode3 != -651787850) {
if (hashCode3 == 1488099780 && str6.equals("BuyGameAccountActivity")) {
c2 = 0;
}
} else if (str6.equals("GameMallFragment")) {
c2 = 1;
}
switch (c2) {
case 0:
l(0);
break;
case 1:
m();
break;
}
}
} else if (com.excelliance.kxqp.gs.sdk.a.a.b.f(this.f6488b)) {
k();
}
}
if (TextUtils.isEmpty(str3)) {
return;
}
cg.a(this.e, str3);
}
private boolean j() {
return this.k == 8;
}
private void k() {
if ("BuyGameAccountActivity".equals(this.c)) {
l(1);
} else if ("GameMallFragment".equals(this.c)) {
m();
}
}
private void l() {
try {
Intent intent = new Intent();
intent.setClass(this.e, GAccountActivity.class);
intent.setPackage(this.e.getPackageName());
intent.putExtra("src", 102);
intent.setFlags(268566528);
this.e.getApplicationContext().startActivity(intent);
az.d("PayPresenter", "start accountactivity ");
} catch (Exception e) {
az.d("PayPresenter", "start accountactivity fail ");
e.printStackTrace();
}
}
private void l(int i) {
try {
Intent intent = new Intent();
intent.setClass(this.e, BuyGameAccountActivity.class);
intent.setPackage(this.e.getPackageName());
intent.putExtra("src", i);
intent.setFlags(268566528);
this.e.getApplicationContext().startActivity(intent);
az.d("PayPresenter", "start accountactivity ");
} catch (Exception e) {
az.d("PayPresenter", "start accountactivity fail ");
e.printStackTrace();
}
}
private void m() {
try {
Intent intent = new Intent();
intent.setClass(this.e, MainActivity.class);
intent.putExtra("shortcut", "openGameMall");
this.e.startActivity(intent);
} catch (Exception e) {
az.d("PayPresenter", "start accountactivity fail ");
e.printStackTrace();
}
}
@Override
public void c() {
super.c();
if (this.i != null && !this.i.b()) {
this.i.a();
}
if (this.j != null) {
com.chinaums.pppay.a.b.a(this.e).a((com.chinaums.pppay.a.a) null);
}
}
public static class d {
String f6515a;
String f6516b;
int c;
public d(String str, String str2, int i) {
this.f6515a = str;
this.f6516b = str2;
this.c = i;
}
}
public float d() {
return this.l;
}
public int e() {
return this.n;
}
}