Idle Egg Factory v2.1.5版本的 MD5 值为:7d2ba6677008ca521af0101bb927d72a
以下内容为反编译后的 a.java 源代码,内容仅作参考
package com.mbridge.msdk.foundation.webview;
import android.content.Context;
import android.content.Intent;
import android.graphics.Bitmap;
import android.net.Uri;
import android.os.Handler;
import android.os.Looper;
import android.text.TextUtils;
import android.webkit.WebView;
import com.facebook.gamingservices.cloudgaming.internal.SDKConstants;
import com.facebook.gamingservices.internal.TournamentShareDialogURIBuilder;
import com.google.android.gms.drive.DriveFile;
import com.mbridge.msdk.click.CommonJumpLoader;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.tools.v;
import com.mbridge.msdk.foundation.tools.z;
import com.mbridge.msdk.foundation.webview.BrowserView;
import com.mbridge.msdk.out.BaseTrackingListener;
import com.safedk.android.analytics.brandsafety.BrandSafetyUtils;
import com.safedk.android.analytics.brandsafety.creatives.e;
import com.safedk.android.internal.partials.MintegralNetworkBridge;
import com.safedk.android.utils.Logger;
import com.safedk.android.utils.f;
public class a implements BrowserView.a {
private static String f6107a = a.class.getSimpleName();
private Context b;
private BaseTrackingListener c;
private CampaignEx d;
private BrowserView f;
private com.mbridge.msdk.click.a h;
private long i;
private int j;
private CommonJumpLoader.JumpLoaderResult l;
private String m;
private boolean n;
private boolean e = true;
private boolean k = false;
private final Runnable o = new Runnable() {
@Override
public final void run() {
v.d(a.f6107a, "webview js!超时上限:" + a.this.j + "ms");
if (a.this.h != null && a.this.l != null) {
a.this.l.setSuccess(false);
a.this.l.setUrl(a.this.m);
a.this.l.setType(2);
a.this.l.setExceptionMsg("linktype 8 time out");
a.this.h.a(a.this.l, a.this.d, 1, false);
}
a aVar = a.this;
if (aVar.d(null, aVar.m) && !a.this.k) {
a.this.k = true;
a aVar2 = a.this;
aVar2.a(aVar2.b, a.this.m, a.this.d);
}
if (a.this.c != null) {
a.this.c.onFinishRedirection(a.this.d, a.this.m);
}
}
};
private Handler g = new Handler(Looper.getMainLooper());
public static void safedk_Context_startActivity_97cb3195734cf5c9cc3418feeafa6dd6(Context p0, Intent p1) {
Logger.d("SafeDK-Special|SafeDK: Call> Landroid/content/Context;->startActivity(Landroid/content/Intent;)V");
if (p1 == null) {
return;
}
BrandSafetyUtils.detectAdClick(p1, f.o);
p0.startActivity(p1);
}
@Override
public final void a() {
}
public a(Context context, CampaignEx campaignEx, com.mbridge.msdk.click.a aVar, BrowserView browserView, BaseTrackingListener baseTrackingListener) {
this.j = 10000;
this.l = null;
this.b = context;
this.d = campaignEx;
this.f = browserView;
this.c = baseTrackingListener;
com.mbridge.msdk.c.a b = com.mbridge.msdk.c.b.a().b(com.mbridge.msdk.foundation.controller.a.d().g());
b = b == null ? com.mbridge.msdk.c.b.a().b() : b;
this.h = aVar;
this.l = new CommonJumpLoader.JumpLoaderResult();
this.j = (int) b.V();
}
@Override
public final void a(WebView webView, String str) {
if (this.i == 0) {
this.i = System.currentTimeMillis();
if (!this.n) {
this.n = true;
c();
}
}
this.m = str;
this.e = true;
}
@Override
public final void a(WebView webView, String str, Bitmap bitmap) {
if (this.i == 0) {
this.i = System.currentTimeMillis();
if (!this.n) {
this.n = true;
c();
}
this.k = false;
}
this.m = str;
this.e = true;
}
@Override
public final boolean b(WebView webView, final String str) {
v.d(f6107a, "shouldOverrideUrlLoading1 " + str);
this.e = false;
if (z.a.a(str) && z.a.a(this.b, str, null)) {
this.k = true;
}
boolean e = e(webView, str);
if (e) {
this.i = 0L;
this.e = false;
d();
com.mbridge.msdk.foundation.same.f.b.b().execute(new Runnable() {
@Override
public final void run() {
if (a.this.h != null && a.this.l != null) {
a.this.l.setSuccess(true);
a.this.l.setUrl(str);
a.this.l.setType(2);
a.this.h.a(a.this.l, a.this.d, 1, true);
}
if (a.this.c != null) {
a.this.c.onFinishRedirection(a.this.d, str);
}
}
});
}
return e;
}
@Override
public final void c(WebView webView, final String str) {
v.d(f6107a, "onPageFinished1 " + str);
if (this.e) {
this.i = 0L;
this.e = false;
com.mbridge.msdk.foundation.same.f.b.b().execute(new Runnable() {
@Override
public final void run() {
if (a.this.c != null) {
a.this.c.onFinishRedirection(a.this.d, str);
}
if (a.this.h == null || a.this.l == null) {
return;
}
a.this.l.setSuccess(true);
a.this.l.setUrl(str);
a.this.l.setType(2);
a.this.h.a(a.this.l, a.this.d, 1, true);
}
});
if (TextUtils.isEmpty(str)) {
return;
}
d();
Uri parse = Uri.parse(str);
if (!(parse.getScheme().equals(e.e) || parse.getScheme().equals(TournamentShareDialogURIBuilder.scheme)) || this.k) {
return;
}
this.k = true;
a(this.b, str, this.d);
}
}
@Override
public final void a(WebView webView, int i, final String str, final String str2) {
v.c(f6107a, str);
d();
com.mbridge.msdk.foundation.same.f.b.b().execute(new Runnable() {
@Override
public final void run() {
if (a.this.c != null) {
a.this.c.onFinishRedirection(a.this.d, str2);
}
if (a.this.h == null || a.this.l == null) {
return;
}
a.this.l.setSuccess(false);
a.this.l.setUrl(str2);
a.this.l.setType(2);
a.this.l.setExceptionMsg(str);
a.this.h.a(a.this.l, a.this.d, 1, true);
}
});
if (!d(webView, str2) || this.k) {
return;
}
this.k = true;
a(this.b, str2, this.d);
}
public void a(Context context, String str, CampaignEx campaignEx) {
if (context == null) {
return;
}
try {
Class.forName("com.mbridge.msdk.activity.MBCommonActivity");
Intent intent = new Intent(context, Class.forName("com.mbridge.msdk.activity.MBCommonActivity"));
if (TextUtils.isEmpty(str)) {
return;
}
b.f6112a.put(str, this.f);
if (z.a.b(str)) {
str = "https://play.google.com/store/apps/details?id=" + str.replace("market://details?id=", "");
}
intent.putExtra("url", str);
v.b("url", "webview url = " + str);
intent.setFlags(DriveFile.MODE_READ_WRITE);
intent.putExtra("mvcommon", campaignEx);
safedk_Context_startActivity_97cb3195734cf5c9cc3418feeafa6dd6(context, intent);
} catch (Exception unused) {
z.a(context, str, this.c);
}
}
public boolean d(WebView webView, String str) {
boolean z;
boolean z2;
try {
if (TextUtils.isEmpty(str)) {
return true;
}
Uri parse = Uri.parse(str);
if (!parse.getScheme().equals(e.e) && !parse.getScheme().equals(TournamentShareDialogURIBuilder.scheme)) {
z = false;
if (!z) {
return true;
}
if (parse.getScheme().equals(SDKConstants.PARAM_INTENT)) {
Intent parseUri = Intent.parseUri(str, 1);
try {
String str2 = parseUri.getPackage();
if (!TextUtils.isEmpty(str2)) {
if (this.b.getPackageManager().getLaunchIntentForPackage(str2) != null) {
return false;
}
}
} catch (Throwable th) {
v.d(f6107a, th.getMessage());
}
try {
String stringExtra = parseUri.getStringExtra("browser_fallback_url");
if (!TextUtils.isEmpty(stringExtra)) {
Uri parse2 = Uri.parse(str);
if (!parse2.getScheme().equals(e.e)) {
if (!parse2.getScheme().equals(TournamentShareDialogURIBuilder.scheme)) {
z2 = false;
if (!z2) {
return true;
}
str = stringExtra;
}
}
z2 = true;
if (!z2) {
}
}
} catch (Throwable th2) {
v.d(f6107a, th2.getMessage());
}
}
if (!com.mbridge.msdk.click.b.d(this.b, str)) {
return true;
}
v.d(f6107a, "openDeepLink");
return false;
}
z = true;
if (!z) {
}
} catch (Throwable th3) {
v.d(f6107a, th3.getMessage());
return true;
}
}
private boolean e(WebView webView, String str) {
boolean z;
boolean z2;
try {
if (TextUtils.isEmpty(str)) {
return false;
}
Uri parse = Uri.parse(str);
if (!parse.getScheme().equals(e.e) && !parse.getScheme().equals(TournamentShareDialogURIBuilder.scheme)) {
z = false;
if (!z) {
return false;
}
if (parse.getScheme().equals(SDKConstants.PARAM_INTENT)) {
Intent parseUri = Intent.parseUri(str, 1);
try {
String str2 = parseUri.getPackage();
if (!TextUtils.isEmpty(str2) && this.b.getPackageManager().getLaunchIntentForPackage(str2) != null) {
parseUri.setFlags(DriveFile.MODE_READ_ONLY);
safedk_Context_startActivity_97cb3195734cf5c9cc3418feeafa6dd6(this.b, parseUri);
this.k = true;
return true;
}
} catch (Throwable th) {
v.d(f6107a, th.getMessage());
}
try {
String stringExtra = parseUri.getStringExtra("browser_fallback_url");
if (!TextUtils.isEmpty(stringExtra)) {
Uri parse2 = Uri.parse(str);
if (!parse2.getScheme().equals(e.e) && !parse2.getScheme().equals(TournamentShareDialogURIBuilder.scheme)) {
z2 = false;
if (!z2) {
MintegralNetworkBridge.webviewLoadUrl(webView, stringExtra);
return false;
}
str = stringExtra;
}
z2 = true;
if (!z2) {
}
}
} catch (Throwable th2) {
v.d(f6107a, th2.getMessage());
}
}
if (!com.mbridge.msdk.click.b.d(this.b, str)) {
return false;
}
v.d(f6107a, "openDeepLink");
this.k = true;
return true;
}
z = true;
if (!z) {
}
} catch (Throwable th3) {
v.d(f6107a, th3.getMessage());
return false;
}
}
private void c() {
this.g.postDelayed(this.o, this.j);
}
private void d() {
this.g.removeCallbacks(this.o);
}
}