正在查看: Cantique de Louanges v12 应用的 CustomTabMainActivity.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: Cantique de Louanges v12 应用的 CustomTabMainActivity.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package com.facebook;
import android.app.Activity;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.content.IntentFilter;
import android.net.Uri;
import android.os.Bundle;
import com.facebook.internal.z0;
import kotlin.Metadata;
@Metadata(d1 = {"\u00002\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\u0010\b\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0002\b\u0005\n\u0002\u0010\u000b\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0002\b\u0007\u0018\u0000 \u00172\u00020\u0001:\u0001\u0007B\u0007¢\u0006\u0004\b\u0015\u0010\u0016J\u001a\u0010\u0007\u001a\u00020\u00062\u0006\u0010\u0003\u001a\u00020\u00022\b\u0010\u0005\u001a\u0004\u0018\u00010\u0004H\u0002J\u0012\u0010\n\u001a\u00020\u00062\b\u0010\t\u001a\u0004\u0018\u00010\bH\u0014J\u0010\u0010\f\u001a\u00020\u00062\u0006\u0010\u000b\u001a\u00020\u0004H\u0014J\b\u0010\r\u001a\u00020\u0006H\u0014R\u0016\u0010\u0010\u001a\u00020\u000e8\u0002@\u0002X\u0082\u000e¢\u0006\u0006\n\u0004\b\u0007\u0010\u000fR\u0018\u0010\u0014\u001a\u0004\u0018\u00010\u00118\u0002@\u0002X\u0082\u000e¢\u0006\u0006\n\u0004\b\u0012\u0010\u0013¨\u0006\u0018"}, d2 = {"Lcom/facebook/CustomTabMainActivity;", "Landroid/app/Activity;", "", "resultCode", "Landroid/content/Intent;", "resultIntent", "Lha/l0;", com.inmobi.commons.core.configs.a.d, "Landroid/os/Bundle;", "savedInstanceState", "onCreate", "intent", "onNewIntent", "onResume", "", "Z", "shouldCloseCustomTab", "Landroid/content/BroadcastReceiver;", "b", "Landroid/content/BroadcastReceiver;", "redirectReceiver", "<init>", "()V", "c", "facebook-common_release"}, k = 1, mv = {1, 5, 1})
public final class CustomTabMainActivity extends Activity {
public static final Companion INSTANCE = new Companion(null);
public static final String d = kotlin.jvm.internal.s.o(CustomTabMainActivity.class.getSimpleName(), ".extra_action");
public static final String e = kotlin.jvm.internal.s.o(CustomTabMainActivity.class.getSimpleName(), ".extra_params");
public static final String f = kotlin.jvm.internal.s.o(CustomTabMainActivity.class.getSimpleName(), ".extra_chromePackage");
public static final String g = kotlin.jvm.internal.s.o(CustomTabMainActivity.class.getSimpleName(), ".extra_url");
public static final String h = kotlin.jvm.internal.s.o(CustomTabMainActivity.class.getSimpleName(), ".extra_targetApp");
public static final String i = kotlin.jvm.internal.s.o(CustomTabMainActivity.class.getSimpleName(), ".action_refresh");
public static final String j = kotlin.jvm.internal.s.o(CustomTabMainActivity.class.getSimpleName(), ".no_activity_exception");
private boolean shouldCloseCustomTab = true;
private BroadcastReceiver redirectReceiver;
public static final class Companion {
private Companion() {
}
public Companion(kotlin.jvm.internal.k kVar) {
this();
}
public final Bundle b(String str) {
Uri parse = Uri.parse(str);
z0 z0Var = z0.a;
Bundle k0 = z0.k0(parse.getQuery());
k0.putAll(z0.k0(parse.getFragment()));
return k0;
}
}
public class b {
public static final int[] a;
static {
int[] iArr = new int[com.facebook.login.s.valuesCustom().length];
iArr[com.facebook.login.s.INSTAGRAM.ordinal()] = 1;
a = iArr;
}
}
private final void a(int i2, Intent intent) {
BroadcastReceiver broadcastReceiver = this.redirectReceiver;
if (broadcastReceiver != null) {
t0.a.b(this).e(broadcastReceiver);
}
if (intent != null) {
String stringExtra = intent.getStringExtra(g);
Bundle b2 = stringExtra != null ? INSTANCE.b(stringExtra) : new Bundle();
com.facebook.internal.n0 n0Var = com.facebook.internal.n0.a;
Intent intent2 = getIntent();
kotlin.jvm.internal.s.e(intent2, "intent");
Intent m = com.facebook.internal.n0.m(intent2, b2, null);
if (m != null) {
intent = m;
}
setResult(i2, intent);
} else {
com.facebook.internal.n0 n0Var2 = com.facebook.internal.n0.a;
Intent intent3 = getIntent();
kotlin.jvm.internal.s.e(intent3, "intent");
setResult(i2, com.facebook.internal.n0.m(intent3, null, null));
}
finish();
}
@Override
protected void onCreate(Bundle bundle) {
String stringExtra;
super.onCreate(bundle);
String str = CustomTabActivity.c;
if (kotlin.jvm.internal.s.a(str, getIntent().getAction())) {
setResult(0);
finish();
return;
}
if (bundle != null || (stringExtra = getIntent().getStringExtra(d)) == null) {
return;
}
Bundle bundleExtra = getIntent().getBundleExtra(e);
boolean a = (b.a[com.facebook.login.s.b.a(getIntent().getStringExtra(h)).ordinal()] == 1 ? new com.facebook.internal.f0(stringExtra, bundleExtra) : new com.facebook.internal.d(stringExtra, bundleExtra)).a(this, getIntent().getStringExtra(f));
this.shouldCloseCustomTab = false;
if (!a) {
setResult(0, getIntent().putExtra(j, true));
finish();
} else {
BroadcastReceiver broadcastReceiver = new BroadcastReceiver() {
@Override
public void onReceive(Context context, Intent intent) {
kotlin.jvm.internal.s.f(context, "context");
kotlin.jvm.internal.s.f(intent, "intent");
Intent intent2 = new Intent(CustomTabMainActivity.this, (Class<?>) CustomTabMainActivity.class);
intent2.setAction(CustomTabMainActivity.i);
String str2 = CustomTabMainActivity.g;
intent2.putExtra(str2, intent.getStringExtra(str2));
intent2.addFlags(603979776);
CustomTabMainActivity.this.startActivity(intent2);
}
};
this.redirectReceiver = broadcastReceiver;
t0.a.b(this).c(broadcastReceiver, new IntentFilter(str));
}
}
@Override
protected void onNewIntent(Intent intent) {
kotlin.jvm.internal.s.f(intent, "intent");
super.onNewIntent(intent);
if (kotlin.jvm.internal.s.a(i, intent.getAction())) {
t0.a.b(this).d(new Intent(CustomTabActivity.d));
a(-1, intent);
} else if (kotlin.jvm.internal.s.a(CustomTabActivity.c, intent.getAction())) {
a(-1, intent);
}
}
@Override
protected void onResume() {
super.onResume();
if (this.shouldCloseCustomTab) {
a(0, null);
}
this.shouldCloseCustomTab = true;
}
}