- 28,932 files - Full Java source code - Smali files - Resources Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
174 lines
5.8 KiB
Java
174 lines
5.8 KiB
Java
package com.ironsource.mediationsdk.testSuite;
|
|
|
|
import android.app.Activity;
|
|
import android.os.Bundle;
|
|
import android.widget.RelativeLayout;
|
|
import com.ironsource.at;
|
|
import com.ironsource.ft;
|
|
import com.ironsource.qg;
|
|
import com.ironsource.qs;
|
|
import kotlin.jvm.internal.Intrinsics;
|
|
import org.json.JSONObject;
|
|
|
|
/* loaded from: classes4.dex */
|
|
public final class TestSuiteActivity extends Activity implements qg {
|
|
private RelativeLayout a;
|
|
private ft b;
|
|
private at c;
|
|
|
|
private final String a() {
|
|
Bundle extras;
|
|
if (getIntent() == null || getIntent().getExtras() == null || (extras = getIntent().getExtras()) == null) {
|
|
return null;
|
|
}
|
|
return extras.getString("controllerUrl");
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: private */
|
|
public static final void a(TestSuiteActivity this$0) {
|
|
Intrinsics.checkNotNullParameter(this$0, "this$0");
|
|
this$0.finish();
|
|
}
|
|
|
|
private final JSONObject b() {
|
|
if (getIntent() != null && getIntent().getExtras() != null) {
|
|
Bundle extras = getIntent().getExtras();
|
|
String string = extras != null ? extras.getString(qs.a) : null;
|
|
if (string != null && string.length() != 0) {
|
|
return new JSONObject(string);
|
|
}
|
|
}
|
|
return new JSONObject();
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: private */
|
|
public static final void b(TestSuiteActivity this$0) {
|
|
Intrinsics.checkNotNullParameter(this$0, "this$0");
|
|
ft ftVar = this$0.b;
|
|
ft ftVar2 = null;
|
|
if (ftVar == null) {
|
|
Intrinsics.throwUninitializedPropertyAccessException("mWebViewWrapper");
|
|
ftVar = null;
|
|
}
|
|
if (ftVar.c().getParent() == null) {
|
|
RelativeLayout relativeLayout = this$0.a;
|
|
if (relativeLayout == null) {
|
|
Intrinsics.throwUninitializedPropertyAccessException("mContainer");
|
|
relativeLayout = null;
|
|
}
|
|
ft ftVar3 = this$0.b;
|
|
if (ftVar3 == null) {
|
|
Intrinsics.throwUninitializedPropertyAccessException("mWebViewWrapper");
|
|
ftVar3 = null;
|
|
}
|
|
relativeLayout.removeView(ftVar3.d());
|
|
RelativeLayout relativeLayout2 = this$0.a;
|
|
if (relativeLayout2 == null) {
|
|
Intrinsics.throwUninitializedPropertyAccessException("mContainer");
|
|
relativeLayout2 = null;
|
|
}
|
|
ft ftVar4 = this$0.b;
|
|
if (ftVar4 == null) {
|
|
Intrinsics.throwUninitializedPropertyAccessException("mWebViewWrapper");
|
|
ftVar4 = null;
|
|
}
|
|
relativeLayout2.addView(ftVar4.c(), this$0.c());
|
|
ft ftVar5 = this$0.b;
|
|
if (ftVar5 == null) {
|
|
Intrinsics.throwUninitializedPropertyAccessException("mWebViewWrapper");
|
|
} else {
|
|
ftVar2 = ftVar5;
|
|
}
|
|
ftVar2.b();
|
|
}
|
|
}
|
|
|
|
private final RelativeLayout.LayoutParams c() {
|
|
return new RelativeLayout.LayoutParams(-1, -1);
|
|
}
|
|
|
|
public final RelativeLayout getContainer() {
|
|
RelativeLayout relativeLayout = this.a;
|
|
if (relativeLayout != null) {
|
|
return relativeLayout;
|
|
}
|
|
Intrinsics.throwUninitializedPropertyAccessException("mContainer");
|
|
return null;
|
|
}
|
|
|
|
@Override // android.app.Activity
|
|
public void onBackPressed() {
|
|
}
|
|
|
|
@Override // com.ironsource.qg
|
|
public void onClosed() {
|
|
runOnUiThread(new Runnable() { // from class: com.ironsource.mediationsdk.testSuite.TestSuiteActivity$$ExternalSyntheticLambda1
|
|
@Override // java.lang.Runnable
|
|
public final void run() {
|
|
TestSuiteActivity.a(TestSuiteActivity.this);
|
|
}
|
|
});
|
|
}
|
|
|
|
@Override // android.app.Activity
|
|
public void onCreate(Bundle bundle) {
|
|
super.onCreate(bundle);
|
|
RelativeLayout relativeLayout = new RelativeLayout(this);
|
|
this.a = relativeLayout;
|
|
setContentView(relativeLayout, c());
|
|
ft ftVar = new ft(this, this, b(), a());
|
|
this.b = ftVar;
|
|
at atVar = new at(ftVar);
|
|
this.c = atVar;
|
|
atVar.d();
|
|
RelativeLayout relativeLayout2 = this.a;
|
|
ft ftVar2 = null;
|
|
if (relativeLayout2 == null) {
|
|
Intrinsics.throwUninitializedPropertyAccessException("mContainer");
|
|
relativeLayout2 = null;
|
|
}
|
|
ft ftVar3 = this.b;
|
|
if (ftVar3 == null) {
|
|
Intrinsics.throwUninitializedPropertyAccessException("mWebViewWrapper");
|
|
} else {
|
|
ftVar2 = ftVar3;
|
|
}
|
|
relativeLayout2.addView(ftVar2.d(), c());
|
|
}
|
|
|
|
@Override // android.app.Activity
|
|
public void onDestroy() {
|
|
at atVar = this.c;
|
|
ft ftVar = null;
|
|
if (atVar == null) {
|
|
Intrinsics.throwUninitializedPropertyAccessException("mNativeBridge");
|
|
atVar = null;
|
|
}
|
|
atVar.a();
|
|
RelativeLayout relativeLayout = this.a;
|
|
if (relativeLayout == null) {
|
|
Intrinsics.throwUninitializedPropertyAccessException("mContainer");
|
|
relativeLayout = null;
|
|
}
|
|
relativeLayout.removeAllViews();
|
|
ft ftVar2 = this.b;
|
|
if (ftVar2 == null) {
|
|
Intrinsics.throwUninitializedPropertyAccessException("mWebViewWrapper");
|
|
} else {
|
|
ftVar = ftVar2;
|
|
}
|
|
ftVar.a();
|
|
super.onDestroy();
|
|
}
|
|
|
|
@Override // com.ironsource.qg
|
|
public void onUIReady() {
|
|
runOnUiThread(new Runnable() { // from class: com.ironsource.mediationsdk.testSuite.TestSuiteActivity$$ExternalSyntheticLambda0
|
|
@Override // java.lang.Runnable
|
|
public final void run() {
|
|
TestSuiteActivity.b(TestSuiteActivity.this);
|
|
}
|
|
});
|
|
}
|
|
}
|