正在查看: 万能钥匙 v1.1.23 应用的 WXEntryActivity.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: 万能钥匙 v1.1.23 应用的 WXEntryActivity.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package com.wifitutu.widget.weixin;
import android.app.Activity;
import android.content.Intent;
import android.os.Build;
import android.os.Bundle;
import android.text.TextUtils;
import android.util.Base64;
import android.webkit.URLUtil;
import com.google.gson.reflect.TypeToken;
import com.meituan.robust.ChangeQuickRedirect;
import com.meituan.robust.PatchProxy;
import com.meituan.robust.PatchProxyResult;
import com.tencent.mm.opensdk.modelbase.BaseReq;
import com.tencent.mm.opensdk.modelbase.BaseResp;
import com.tencent.mm.opensdk.modelbiz.WXLaunchMiniProgram;
import com.tencent.mm.opensdk.modelbiz.WXOpenBusinessView;
import com.tencent.mm.opensdk.modelmsg.SendAuth;
import com.tencent.mm.opensdk.modelmsg.ShowMessageFromWX;
import com.tencent.mm.opensdk.modelmsg.WXMediaMessage;
import com.tencent.mm.opensdk.openapi.IWXAPI;
import com.tencent.mm.opensdk.openapi.IWXAPIEventHandler;
import com.tencent.mm.opensdk.openapi.WXAPIFactory;
import com.wifitutu.link.foundation.router.api.generate.PageLink;
import f60.d3;
import f60.e3;
import f60.f3;
import f60.f7;
import f60.h2;
import f60.h7;
import f60.n5;
import f60.w0;
import f60.x0;
import java.util.Arrays;
import java.util.Iterator;
import kotlin.Metadata;
import kotlin.jvm.internal.a0;
import kotlin.jvm.internal.f0;
import kotlin.jvm.internal.k0;
import kotlin.jvm.internal.n;
import kotlin.jvm.internal.p;
import lg0.e0;
import lg0.n;
import lg0.o;
import org.json.JSONObject;
import os.f2;
import os.g1;
import qs.C0465a;
import qs.b4;
import qs.d6;
import qs.g0;
import qs.h4;
import qs.j0;
import qs.u0;
import qs.x5;
import qs.y2;
import tj0.t;
@Metadata(d1 = {"\u0000T\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0002\b\u0003\n\u0002\u0018\u0002\n\u0002\b\u0003\n\u0002\u0018\u0002\n\u0002\b\u0005\n\u0002\u0010\u000e\n\u0000\n\u0002\u0010\u000b\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0002\b\n\n\u0002\u0018\u0002\n\u0002\b\u0003\u0018\u00002\u00020\u00012\u00020\u0002B\u0007¢\u0006\u0004\b\u0003\u0010\u0004J\u0019\u0010\b\u001a\u00020\u00072\b\u0010\u0006\u001a\u0004\u0018\u00010\u0005H\u0016¢\u0006\u0004\b\b\u0010\tJ\u0017\u0010\f\u001a\u00020\u00072\u0006\u0010\u000b\u001a\u00020\nH\u0014¢\u0006\u0004\b\f\u0010\rJ\u0017\u0010\u0010\u001a\u00020\u00072\u0006\u0010\u000f\u001a\u00020\u000eH\u0016¢\u0006\u0004\b\u0010\u0010\u0011J\u0017\u0010\u0014\u001a\u00020\u00072\u0006\u0010\u0013\u001a\u00020\u0012H\u0016¢\u0006\u0004\b\u0014\u0010\u0015J\u000f\u0010\u0016\u001a\u00020\u0007H\u0016¢\u0006\u0004\b\u0016\u0010\u0004J\u0017\u0010\u0017\u001a\u00020\u00072\u0006\u0010\u0013\u001a\u00020\u0012H\u0002¢\u0006\u0004\b\u0017\u0010\u0015J\u0017\u0010\u001b\u001a\u00020\u001a2\u0006\u0010\u0019\u001a\u00020\u0018H\u0002¢\u0006\u0004\b\u001b\u0010\u001cJ\u0019\u0010\u001f\u001a\u00020\u00182\b\u0010\u001e\u001a\u0004\u0018\u00010\u001dH\u0002¢\u0006\u0004\b\u001f\u0010 R\u001a\u0010$\u001a\u00020\u00188\u0006X\u0086D¢\u0006\f\n\u0004\b\u001f\u0010!\u001a\u0004\b\"\u0010#R\u001b\u0010'\u001a\u00020\u00188BX\u0082\u0084\u0002¢\u0006\f\n\u0004\b\"\u0010%\u001a\u0004\b&\u0010#R\u0018\u0010*\u001a\u0004\u0018\u00010(8\u0002@\u0002X\u0082\u000e¢\u0006\u0006\n\u0004\b&\u0010)¨\u0006+"}, d2 = {"Lcom/wifitutu/widget/weixin/WXEntryActivity;", "Landroid/app/Activity;", "Lcom/tencent/mm/opensdk/openapi/IWXAPIEventHandler;", "<init>", "()V", "Landroid/os/Bundle;", "savedInstanceState", "Llg0/e0;", "onCreate", "(Landroid/os/Bundle;)V", "Landroid/content/Intent;", "intent", "onNewIntent", "(Landroid/content/Intent;)V", "Lcom/tencent/mm/opensdk/modelbase/BaseReq;", "req", "onReq", "(Lcom/tencent/mm/opensdk/modelbase/BaseReq;)V", "Lcom/tencent/mm/opensdk/modelbase/BaseResp;", "resp", "onResp", "(Lcom/tencent/mm/opensdk/modelbase/BaseResp;)V", "finish", "e", "", "link", "", "d", "(Ljava/lang/String;)Z", "Lorg/json/JSONObject;", "paramsJSON", "a", "(Lorg/json/JSONObject;)Ljava/lang/String;", "Ljava/lang/String;", "b", "()Ljava/lang/String;", "TAG", "Llg0/h;", "c", "WX_APP_ID", "Lcom/tencent/mm/opensdk/openapi/IWXAPI;", "Lcom/tencent/mm/opensdk/openapi/IWXAPI;", "api", "widget-weixin_release"}, k = 1, mv = {1, 8, 0}, xi = 48)
public final class WXEntryActivity extends Activity implements IWXAPIEventHandler {
public static ChangeQuickRedirect changeQuickRedirect;
public final String TAG = "WXEntryActivity";
public final lg0.h WX_APP_ID = lg0.i.a(a.s);
public IWXAPI api;
@Metadata(d1 = {"\u0000\b\n\u0000\n\u0002\u0010\u000e\n\u0000\u0010\u0000\u001a\u00020\u0001H\n¢\u0006\u0002\b\u0002"}, d2 = {"<anonymous>", "", "invoke"}, k = 3, mv = {1, 8, 0}, xi = 48)
public static final class a extends p implements ah0.a<String> {
public static ChangeQuickRedirect changeQuickRedirect;
public static final a s = new a();
public a() {
super(0);
}
public Object invoke() {
PatchProxyResult proxy = PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51137, new Class[0], Object.class);
return proxy.isSupported ? proxy.result : m80invoke();
}
public final String m80invoke() {
PatchProxyResult proxy = PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51136, new Class[0], String.class);
return proxy.isSupported ? (String) proxy.result : h2.b(g1.a(f2.d())).n6();
}
}
@Metadata(d1 = {"\u0000\b\n\u0000\n\u0002\u0010\u000e\n\u0000\u0010\u0000\u001a\u0004\u0018\u00010\u0001H\n¢\u0006\u0002\b\u0002"}, d2 = {"<anonymous>", "", "invoke"}, k = 3, mv = {1, 8, 0}, xi = 48)
public static final class b extends p implements ah0.a<String> {
public static ChangeQuickRedirect changeQuickRedirect;
public final JSONObject s;
public b(JSONObject jSONObject) {
super(0);
this.s = jSONObject;
}
public Object invoke() {
PatchProxyResult proxy = PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51139, new Class[0], Object.class);
return proxy.isSupported ? proxy.result : m81invoke();
}
public final String m81invoke() {
PatchProxyResult proxy = PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51138, new Class[0], String.class);
return proxy.isSupported ? (String) proxy.result : this.s.toString();
}
}
@Metadata(d1 = {"\u0000\b\n\u0000\n\u0002\u0010\u0000\n\u0000\u0010\u0000\u001a\u0004\u0018\u00010\u0001H\n¢\u0006\u0002\b\u0002"}, d2 = {"<anonymous>", "", "invoke"}, k = 3, mv = {1, 8, 0}, xi = 48)
public static final class c extends p implements ah0.a<Object> {
public static ChangeQuickRedirect changeQuickRedirect;
public static final c s = new c();
public c() {
super(0);
}
public final Object invoke() {
return "finish";
}
}
@Metadata(d1 = {"\u0000\b\n\u0002\u0018\u0002\n\u0002\b\u0003\u0010\u0003\u001a\u00020\u0000H\n¢\u0006\u0004\b\u0001\u0010\u0002"}, d2 = {"Llg0/e0;", "invoke", "()V", "<anonymous>"}, k = 3, mv = {1, 8, 0})
public static final class d extends p implements ah0.a<e0> {
public static ChangeQuickRedirect changeQuickRedirect;
public final BaseReq s;
public final WXEntryActivity t;
public final f0<C0465a> u;
@Metadata(d1 = {"\u0000\u000b\n\u0000\n\u0002\u0018\u0002\n\u0000*\u0001\u0000\b\n\u0018\u00002\b\u0012\u0004\u0012\u00028\u00000\u0001¨\u0006\u0002"}, d2 = {"com/wifitutu/widget/weixin/WXEntryActivity$d$a", "Lcom/google/gson/reflect/TypeToken;", "lib-kernel_release"}, k = 1, mv = {1, 8, 0}, xi = 48)
public static final class a extends TypeToken<C0465a> {
}
public d(BaseReq baseReq, WXEntryActivity wXEntryActivity, f0<C0465a> f0Var) {
super(0);
this.s = baseReq;
this.t = wXEntryActivity;
this.u = f0Var;
}
public Object invoke() {
PatchProxyResult proxy = PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51141, new Class[0], Object.class);
if (proxy.isSupported) {
return proxy.result;
}
m82invoke();
return e0.a;
}
public final void m82invoke() {
Object obj;
if (PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51140, new Class[0], Void.TYPE).isSupported) {
return;
}
ShowMessageFromWX.Req req = this.s;
if (!(req instanceof ShowMessageFromWX.Req)) {
h4.l().debug(this.t.getTAG(), "WXEntryActivity req type error");
return;
}
WXMediaMessage wXMediaMessage = req.message;
h4.l().debug(this.t.getTAG(), "WXEntryActivity mediaMsg.messageExt ==>> " + wXMediaMessage.messageExt);
f0<C0465a> f0Var = this.u;
b4 b4Var = b4.c;
String str = wXMediaMessage.messageExt;
try {
Iterator it = x5.c().iterator();
while (true) {
if (!it.hasNext()) {
obj = null;
break;
}
obj = it.next();
g0 g0Var = (g0) obj;
if (n.d(kotlin.jvm.internal.g0.b(C0465a.class), g0Var) ? true : g0Var.b(kotlin.jvm.internal.g0.b(C0465a.class))) {
break;
}
}
f0Var.a = obj != null ? b4Var.b().g(str, new a().getType()) : b4Var.b().a(str, kotlin.jvm.internal.g0.b(C0465a.class));
y2 l = h4.l();
String tag = this.t.getTAG();
StringBuilder sb = new StringBuilder();
sb.append("WXEntryActivity extInfo ==>> ");
C0465a c0465a = this.u.a;
sb.append(c0465a != null ? c0465a.getType() : null);
sb.append(", ");
C0465a c0465a2 = this.u.a;
sb.append(c0465a2 != null ? c0465a2.getUrl() : null);
l.debug(tag, sb.toString());
} catch (Throwable th) {
ah0.l a2 = b4Var.a();
if (a2 != null) {
a2.invoke(th);
}
throw th;
}
}
}
@Metadata(d1 = {"\u0000\b\n\u0002\u0018\u0002\n\u0002\b\u0003\u0010\u0003\u001a\u00020\u0000H\n¢\u0006\u0004\b\u0001\u0010\u0002"}, d2 = {"Llg0/e0;", "invoke", "()V", "<anonymous>"}, k = 3, mv = {1, 8, 0})
public static final class e extends p implements ah0.a<e0> {
public static ChangeQuickRedirect changeQuickRedirect;
public final BaseResp t;
public e(BaseResp baseResp) {
super(0);
this.t = baseResp;
}
public Object invoke() {
PatchProxyResult proxy = PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51143, new Class[0], Object.class);
if (proxy.isSupported) {
return proxy.result;
}
m83invoke();
return e0.a;
}
public final void m83invoke() {
if (PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51142, new Class[0], Void.TYPE).isSupported) {
return;
}
WXEntryActivity.access$processResp(WXEntryActivity.this, this.t);
}
}
@Metadata(d1 = {"\u0000\b\n\u0002\u0018\u0002\n\u0002\b\u0003\u0010\u0003\u001a\u00020\u0000H\n¢\u0006\u0004\b\u0001\u0010\u0002"}, d2 = {"Llg0/e0;", "invoke", "()V", "<anonymous>"}, k = 3, mv = {1, 8, 0})
public static final class f extends p implements ah0.a<e0> {
public static ChangeQuickRedirect changeQuickRedirect;
public final String s;
public final a0 t;
public final WXEntryActivity u;
public final f0<String> v;
public f(String str, a0 a0Var, WXEntryActivity wXEntryActivity, f0<String> f0Var) {
super(0);
this.s = str;
this.t = a0Var;
this.u = wXEntryActivity;
this.v = f0Var;
}
public Object invoke() {
PatchProxyResult proxy = PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51145, new Class[0], Object.class);
if (proxy.isSupported) {
return proxy.result;
}
m84invoke();
return e0.a;
}
public final void m84invoke() {
if (PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51144, new Class[0], Void.TYPE).isSupported) {
return;
}
if (t.L(this.s, "intent:", false, 2, null) || t.L(this.s, "android-app://", false, 2, null)) {
Intent parseUri = Intent.parseUri(this.s, 1);
parseUri.addFlags(268435456);
this.t.a = u0.w(f2.c(f2.d()), parseUri, false, 2, (Object) null);
} else if (URLUtil.isNetworkUrl(this.s)) {
String value = PageLink.PAGE_ID.WEB_PAGE.getValue();
WXEntryActivity wXEntryActivity = this.u;
JSONObject jSONObject = new JSONObject();
String str = this.s;
JSONObject jSONObject2 = new JSONObject();
jSONObject2.put("url", str);
e0 e0Var = e0.a;
jSONObject.put("content", jSONObject2);
String access$buildData = WXEntryActivity.access$buildData(wXEntryActivity, jSONObject);
this.v.a = "wifitutu://deeplink/?router=true&pageid=" + value + "&data=" + access$buildData;
}
Intent parseUri2 = Intent.parseUri(this.v.a, 0);
parseUri2.addFlags(268435456);
parseUri2.setPackage(this.u.getPackageName());
this.t.a = u0.w(f2.c(f2.d()), parseUri2, false, 2, (Object) null);
}
}
@Metadata(d1 = {"\u0000\b\n\u0000\n\u0002\u0010\u0000\n\u0000\u0010\u0000\u001a\u0004\u0018\u00010\u0001H\n¢\u0006\u0002\b\u0002"}, d2 = {"<anonymous>", "", "invoke"}, k = 3, mv = {1, 8, 0}, xi = 48)
public static final class g extends p implements ah0.a<Object> {
public static ChangeQuickRedirect changeQuickRedirect;
public final int s;
public g(int i) {
super(0);
this.s = i;
}
public final Object invoke() {
PatchProxyResult proxy = PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51146, new Class[0], Object.class);
if (proxy.isSupported) {
return proxy.result;
}
return "WXEntryActivity onResp==>> type={" + this.s + '}';
}
}
@Metadata(d1 = {"\u0000\b\n\u0000\n\u0002\u0010\u0000\n\u0000\u0010\u0000\u001a\u0004\u0018\u00010\u0001H\n¢\u0006\u0002\b\u0002"}, d2 = {"<anonymous>", "", "invoke"}, k = 3, mv = {1, 8, 0}, xi = 48)
public static final class h extends p implements ah0.a<Object> {
public static ChangeQuickRedirect changeQuickRedirect;
public final BaseResp s;
public h(BaseResp baseResp) {
super(0);
this.s = baseResp;
}
public final Object invoke() {
PatchProxyResult proxy = PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51147, new Class[0], Object.class);
if (proxy.isSupported) {
return proxy.result;
}
return "WXEntryActivity onResp==>> info={" + this.s.businessType + ", " + this.s.errCode + ',' + this.s.errStr;
}
}
@Metadata(d1 = {"\u0000\b\n\u0000\n\u0002\u0010\u0000\n\u0000\u0010\u0000\u001a\u0004\u0018\u00010\u0001H\n¢\u0006\u0002\b\u0002"}, d2 = {"<anonymous>", "", "invoke"}, k = 3, mv = {1, 8, 0}, xi = 48)
public static final class i extends p implements ah0.a<Object> {
public static ChangeQuickRedirect changeQuickRedirect;
public final BaseResp s;
public i(BaseResp baseResp) {
super(0);
this.s = baseResp;
}
public final Object invoke() {
PatchProxyResult proxy = PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51148, new Class[0], Object.class);
if (proxy.isSupported) {
return proxy.result;
}
return "WXEntryActivity onResp==>>WX_MINI PROGRAM info={" + this.s.businessType + ", " + this.s.openId;
}
}
@Metadata(d1 = {"\u0000\b\n\u0000\n\u0002\u0010\u0000\n\u0000\u0010\u0000\u001a\u0004\u0018\u00010\u0001H\n¢\u0006\u0002\b\u0002"}, d2 = {"<anonymous>", "", "invoke"}, k = 3, mv = {1, 8, 0}, xi = 48)
public static final class j extends p implements ah0.a<Object> {
public static ChangeQuickRedirect changeQuickRedirect;
public final BaseResp s;
public j(BaseResp baseResp) {
super(0);
this.s = baseResp;
}
public final Object invoke() {
PatchProxyResult proxy = PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51149, new Class[0], Object.class);
if (proxy.isSupported) {
return proxy.result;
}
return "WXEntryActivity onResp==>>WX_MINI PROGRAM , info={" + this.s.openId + ',';
}
}
@Metadata(d1 = {"\u0000\b\n\u0000\n\u0002\u0010\u0000\n\u0000\u0010\u0000\u001a\u0004\u0018\u00010\u0001H\n¢\u0006\u0002\b\u0002"}, d2 = {"<anonymous>", "", "invoke"}, k = 3, mv = {1, 8, 0}, xi = 48)
public static final class k extends p implements ah0.a<Object> {
public static ChangeQuickRedirect changeQuickRedirect;
public final BaseResp s;
public k(BaseResp baseResp) {
super(0);
this.s = baseResp;
}
public final Object invoke() {
PatchProxyResult proxy = PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51150, new Class[0], Object.class);
if (proxy.isSupported) {
return proxy.result;
}
k0 k0Var = k0.a;
WXLaunchMiniProgram.Resp resp = this.s;
String format = String.format("openid=%s\nextMsg=%s\nerrStr=%s\nerrCode=%s", Arrays.copyOf(new Object[]{((BaseResp) resp).openId, resp.extMsg, ((BaseResp) resp).errStr, Integer.valueOf(((BaseResp) resp).errCode)}, 4));
n.h(format, "format(format, *args)");
return "WXEntryActivity onReq==>>WX_MINI PROGRAM info={" + format + '}';
}
}
@Metadata(d1 = {"\u0000\b\n\u0000\n\u0002\u0010\u0000\n\u0000\u0010\u0000\u001a\u0004\u0018\u00010\u0001H\n¢\u0006\u0002\b\u0002"}, d2 = {"<anonymous>", "", "invoke"}, k = 3, mv = {1, 8, 0}, xi = 48)
public static final class l extends p implements ah0.a<Object> {
public static ChangeQuickRedirect changeQuickRedirect;
public static final l s = new l();
public l() {
super(0);
}
public final Object invoke() {
return "Auth Finish";
}
}
public static final String access$buildData(WXEntryActivity wXEntryActivity, JSONObject jSONObject) {
PatchProxyResult proxy = PatchProxy.proxy(new Object[]{wXEntryActivity, jSONObject}, (Object) null, changeQuickRedirect, true, 51135, new Class[]{WXEntryActivity.class, JSONObject.class}, String.class);
return proxy.isSupported ? (String) proxy.result : wXEntryActivity.a(jSONObject);
}
public static final void access$processResp(WXEntryActivity wXEntryActivity, BaseResp baseResp) {
if (PatchProxy.proxy(new Object[]{wXEntryActivity, baseResp}, (Object) null, changeQuickRedirect, true, 51134, new Class[]{WXEntryActivity.class, BaseResp.class}, Void.TYPE).isSupported) {
return;
}
wXEntryActivity.e(baseResp);
}
public final String a(JSONObject paramsJSON) {
PatchProxyResult proxy = PatchProxy.proxy(new Object[]{paramsJSON}, this, changeQuickRedirect, false, 51133, new Class[]{JSONObject.class}, String.class);
if (proxy.isSupported) {
return (String) proxy.result;
}
String str = paramsJSON != null ? (String) d6.j((Object) null, new b(paramsJSON)) : null;
if (str == null) {
return "";
}
byte[] bytes = str.getBytes(tj0.c.UTF_8);
n.h(bytes, "this as java.lang.String).getBytes(charset)");
String d2 = j0.d(Base64.encodeToString(bytes, 0));
return d2 == null ? "" : d2;
}
public final String getTAG() {
return this.TAG;
}
public final String c() {
PatchProxyResult proxy = PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51125, new Class[0], String.class);
return proxy.isSupported ? (String) proxy.result : (String) this.WX_APP_ID.getValue();
}
public final boolean d(String link) {
PatchProxyResult proxy = PatchProxy.proxy(new Object[]{link}, this, changeQuickRedirect, false, 51132, new Class[]{String.class}, Boolean.TYPE);
if (proxy.isSupported) {
return ((Boolean) proxy.result).booleanValue();
}
f0 f0Var = new f0();
f0Var.a = link;
a0 a0Var = new a0();
d6.k(new f(link, a0Var, this, f0Var));
return a0Var.a;
}
public final void e(BaseResp resp) {
f3 f3Var;
if (PatchProxy.proxy(new Object[]{resp}, this, changeQuickRedirect, false, 51130, new Class[]{BaseResp.class}, Void.TYPE).isSupported) {
return;
}
int type = resp.getType();
h4.l().j(this.TAG, new g(type));
if (type == 1) {
n.g(resp, "null cannot be cast to non-null type com.tencent.mm.opensdk.modelmsg.SendAuth.Resp");
SendAuth.Resp resp2 = (SendAuth.Resp) resp;
d3 b2 = e3.b(g1.a(f2.d()));
f3Var = b2 instanceof f3 ? (f3) b2 : null;
if (f3Var != null) {
f3Var.q9(new h7(e3.c(Integer.valueOf(resp.errCode)), resp2.code, resp2.state));
}
h4.l().j(this.TAG, l.s);
return;
}
if (type == 19) {
n.g(resp, "null cannot be cast to non-null type com.tencent.mm.opensdk.modelbiz.WXLaunchMiniProgram.Resp");
WXLaunchMiniProgram.Resp resp3 = (WXLaunchMiniProgram.Resp) resp;
h4.l().j(this.TAG, new k(resp));
d3 b3 = e3.b(g1.a(f2.d()));
f3Var = b3 instanceof f3 ? (f3) b3 : null;
if (f3Var != null) {
f3Var.i8(new n5(resp.openId, resp3.extMsg, String.valueOf(resp.errCode), resp.errStr));
return;
}
return;
}
if (type == 25 || type == 26) {
n.g(resp, "null cannot be cast to non-null type com.tencent.mm.opensdk.modelbiz.WXOpenBusinessView.Resp");
WXOpenBusinessView.Resp resp4 = (WXOpenBusinessView.Resp) resp;
h4.l().j(this.TAG, new h(resp));
if (TextUtils.equals(resp4.businessType, "nativeOpenAdCanvas")) {
h4.l().j(this.TAG, new i(resp));
return;
}
if (TextUtils.equals(resp4.businessType, "requestMerchantTransfer")) {
d3 b4 = e3.b(g1.a(f2.d()));
f3Var = b4 instanceof f3 ? (f3) b4 : null;
if (f3Var != null) {
f3Var.b6(new f7(resp4.businessType, resp.errCode, resp.errStr));
return;
}
return;
}
h4.l().j(this.TAG, new j(resp));
Intent intent = getIntent();
intent.setClassName(this, "com.shengpay.aggregate.app.PaymentActivity");
try {
n.Companion companion = lg0.n.INSTANCE;
startActivity(intent);
lg0.n.b(e0.a);
} catch (Throwable th) {
n.Companion companion2 = lg0.n.INSTANCE;
lg0.n.b(o.a(th));
}
}
}
@Override
public void finish() {
if (PatchProxy.proxy(new Object[0], this, changeQuickRedirect, false, 51131, new Class[0], Void.TYPE).isSupported) {
return;
}
h4.l().j(this.TAG, c.s);
super.finish();
}
@Override
public void onCreate(Bundle savedInstanceState) {
if (PatchProxy.proxy(new Object[]{savedInstanceState}, this, changeQuickRedirect, false, 51126, new Class[]{Bundle.class}, Void.TYPE).isSupported) {
return;
}
super.onCreate(savedInstanceState);
if (Build.VERSION.SDK_INT != 26) {
setRequestedOrientation(1);
}
w0 b2 = x0.b(g1.a(f2.d()));
if (b2 != null) {
b2.E5(this, getIntent());
}
this.api = WXAPIFactory.createWXAPI(this, c(), false);
try {
n.Companion companion = lg0.n.INSTANCE;
Intent intent = getIntent();
IWXAPI iwxapi = this.api;
lg0.n.b(iwxapi != null ? Boolean.valueOf(iwxapi.handleIntent(intent, this)) : null);
} catch (Throwable th) {
n.Companion companion2 = lg0.n.INSTANCE;
lg0.n.b(o.a(th));
}
}
@Override
public void onNewIntent(Intent intent) {
if (PatchProxy.proxy(new Object[]{intent}, this, changeQuickRedirect, false, 51127, new Class[]{Intent.class}, Void.TYPE).isSupported) {
return;
}
super.onNewIntent(intent);
setIntent(intent);
w0 b2 = x0.b(g1.a(f2.d()));
if (b2 != null) {
b2.E5(this, intent);
}
IWXAPI iwxapi = this.api;
if (iwxapi != null) {
iwxapi.handleIntent(intent, this);
}
finish();
}
public void onReq(BaseReq req) {
if (PatchProxy.proxy(new Object[]{req}, this, changeQuickRedirect, false, 51128, new Class[]{BaseReq.class}, Void.TYPE).isSupported) {
return;
}
int type = req.getType();
h4.l().info(this.TAG, "WXEntryActivity onReq==>> code={" + type + '}');
if (type == 4) {
f0 f0Var = new f0();
d6.k(new d(req, this, f0Var));
C0465a c0465a = (C0465a) f0Var.a;
String url = c0465a != null ? c0465a.getUrl() : null;
if (url != null && url.length() > 0) {
C0465a c0465a2 = (C0465a) f0Var.a;
if (kotlin.jvm.internal.n.d(c0465a2 != null ? c0465a2.getType() : null, ExtType.OPEN_PAGE.getValue())) {
h4.l().debug(this.TAG, "WXEntryActivity open DeepLink");
d(url);
}
}
h4.l().debug(this.TAG, "WXEntryActivity open shengpay");
Intent intent = getIntent();
intent.setClassName(this, "com.shengpay.aggregate.app.PaymentActivity");
try {
n.Companion companion = lg0.n.INSTANCE;
startActivity(intent);
lg0.n.b(e0.a);
} catch (Throwable th) {
n.Companion companion2 = lg0.n.INSTANCE;
lg0.n.b(o.a(th));
}
}
finish();
}
public void onResp(BaseResp resp) {
if (PatchProxy.proxy(new Object[]{resp}, this, changeQuickRedirect, false, 51129, new Class[]{BaseResp.class}, Void.TYPE).isSupported) {
return;
}
d6.g(false, new e(resp), 1, (Object) null);
finish();
}
}