正在查看: FanCode v7.24.0 应用的 ProxyBillingActivityV2.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: FanCode v7.24.0 应用的 ProxyBillingActivityV2.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package com.android.billingclient.api;
import android.app.PendingIntent;
import android.content.Intent;
import android.os.Bundle;
import android.os.ResultReceiver;
import androidx.activity.ComponentActivity;
import androidx.activity.result.ActivityResult;
import androidx.activity.result.IntentSenderRequest;
import androidx.annotation.NonNull;
import com.google.android.apps.common.proguard.UsedByReflection;
import com.google.android.gms.internal.play_billing.zzb;
import com.newrelic.agent.android.api.v2.TraceFieldInterface;
import com.newrelic.agent.android.background.ApplicationStateMonitor;
import com.newrelic.agent.android.instrumentation.Instrumented;
import com.newrelic.agent.android.tracing.Trace;
import com.newrelic.agent.android.tracing.TraceMachine;
import java.util.ArrayList;
@UsedByReflection("PlatformActivityProxy")
@Instrumented
public class ProxyBillingActivityV2 extends ComponentActivity implements TraceFieldInterface {
private d.b f8418a;
private d.b f8419b;
private ResultReceiver f8420c;
private ResultReceiver f8421d;
public Trace f8422e;
final void n(ActivityResult activityResult) {
Intent a9 = activityResult.a();
int b9 = zzb.zze(a9, "ProxyBillingActivityV2").b();
ResultReceiver resultReceiver = this.f8420c;
if (resultReceiver != null) {
resultReceiver.send(b9, a9 == null ? null : a9.getExtras());
}
if (activityResult.b() != -1 || b9 != 0) {
zzb.zzk("ProxyBillingActivityV2", "Alternative billing only dialog finished with resultCode " + activityResult.b() + " and billing's responseCode: " + b9);
}
finish();
}
final void o(ActivityResult activityResult) {
Intent a9 = activityResult.a();
int b9 = zzb.zze(a9, "ProxyBillingActivityV2").b();
ResultReceiver resultReceiver = this.f8421d;
if (resultReceiver != null) {
resultReceiver.send(b9, a9 == null ? null : a9.getExtras());
}
if (activityResult.b() != -1 || b9 != 0) {
zzb.zzk("ProxyBillingActivityV2", String.format("External offer dialog finished with resultCode: %s and billing's responseCode: %s", Integer.valueOf(activityResult.b()), Integer.valueOf(b9)));
}
finish();
}
@Override
protected final void onCreate(Bundle bundle) {
TraceMachine.startTracing("ProxyBillingActivityV2");
try {
TraceMachine.enterMethod(this.f8422e, "ProxyBillingActivityV2#onCreate", (ArrayList) null);
} catch (NoSuchFieldError unused) {
TraceMachine.enterMethod((Trace) null, "ProxyBillingActivityV2#onCreate", (ArrayList) null);
}
super.onCreate(bundle);
this.f8418a = registerForActivityResult(new e.d(), new d.a() {
@Override
public final void a(Object obj) {
ProxyBillingActivityV2.this.n((ActivityResult) obj);
}
});
this.f8419b = registerForActivityResult(new e.d(), new d.a() {
@Override
public final void a(Object obj) {
ProxyBillingActivityV2.this.o((ActivityResult) obj);
}
});
if (bundle == null) {
zzb.zzj("ProxyBillingActivityV2", "Launching Play Store billing dialog");
if (getIntent().hasExtra("ALTERNATIVE_BILLING_ONLY_DIALOG_INTENT")) {
PendingIntent pendingIntent = (PendingIntent) getIntent().getParcelableExtra("ALTERNATIVE_BILLING_ONLY_DIALOG_INTENT");
this.f8420c = (ResultReceiver) getIntent().getParcelableExtra("alternative_billing_only_dialog_result_receiver");
this.f8418a.b(new IntentSenderRequest.a(pendingIntent).a());
TraceMachine.exitMethod();
return;
}
if (getIntent().hasExtra("external_payment_dialog_pending_intent")) {
PendingIntent pendingIntent2 = (PendingIntent) getIntent().getParcelableExtra("external_payment_dialog_pending_intent");
this.f8421d = (ResultReceiver) getIntent().getParcelableExtra("external_payment_dialog_result_receiver");
this.f8419b.b(new IntentSenderRequest.a(pendingIntent2).a());
TraceMachine.exitMethod();
return;
}
} else if (bundle.containsKey("alternative_billing_only_dialog_result_receiver")) {
this.f8420c = (ResultReceiver) bundle.getParcelable("alternative_billing_only_dialog_result_receiver");
TraceMachine.exitMethod();
return;
} else if (bundle.containsKey("external_payment_dialog_result_receiver")) {
this.f8421d = (ResultReceiver) bundle.getParcelable("external_payment_dialog_result_receiver");
TraceMachine.exitMethod();
return;
}
TraceMachine.exitMethod();
}
@Override
protected final void onSaveInstanceState(@NonNull Bundle bundle) {
super.onSaveInstanceState(bundle);
ResultReceiver resultReceiver = this.f8420c;
if (resultReceiver != null) {
bundle.putParcelable("alternative_billing_only_dialog_result_receiver", resultReceiver);
}
ResultReceiver resultReceiver2 = this.f8421d;
if (resultReceiver2 != null) {
bundle.putParcelable("external_payment_dialog_result_receiver", resultReceiver2);
}
}
@Override
protected void onStart() {
super.onStart();
ApplicationStateMonitor.getInstance().activityStarted();
}
@Override
protected void onStop() {
super.onStop();
ApplicationStateMonitor.getInstance().activityStopped();
}
}