正在查看: All File Recovery v1.0.2 应用的 DialogC2744f.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: All File Recovery v1.0.2 应用的 DialogC2744f.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package com.applovin.impl.adview;
import android.R;
import android.app.Activity;
import android.app.Dialog;
import android.os.Bundle;
import android.view.View;
import android.view.Window;
import android.view.animation.AlphaAnimation;
import android.view.animation.Animation;
import android.widget.RelativeLayout;
import com.applovin.impl.C2837l4;
import com.applovin.impl.InterfaceC2810i1;
import com.applovin.impl.adview.AbstractC2743e;
import com.applovin.impl.sdk.C2932k;
import com.applovin.impl.sdk.C2936o;
import com.applovin.impl.sdk.ad.C2921a;
import com.applovin.sdk.AppLovinSdkUtils;
class DialogC2744f extends Dialog implements InterfaceC2810i1 {
private final Activity f40452a;
private final C2932k f40453b;
private final C2936o f40454c;
private final C2740b f40455d;
private final C2921a f40456e;
private RelativeLayout f40457f;
private AbstractC2743e f40458g;
public class a implements Animation.AnimationListener {
public a() {
}
@Override
public void onAnimationEnd(Animation animation) {
DialogC2744f.this.f40458g.setClickable(true);
}
@Override
public void onAnimationRepeat(Animation animation) {
}
@Override
public void onAnimationStart(Animation animation) {
}
}
public DialogC2744f(C2921a c2921a, C2740b c2740b, Activity activity, C2932k c2932k) {
super(activity, R.style.Theme.Translucent.NoTitleBar);
if (c2921a == null) {
throw new IllegalArgumentException("No ad specified");
}
if (c2740b == null) {
throw new IllegalArgumentException("No main view specified");
}
if (c2932k == null) {
throw new IllegalArgumentException("No sdk specified");
}
if (activity == null) {
throw new IllegalArgumentException("No activity specified");
}
this.f40453b = c2932k;
this.f40454c = c2932k.O();
this.f40452a = activity;
this.f40455d = c2740b;
this.f40456e = c2921a;
requestWindowFeature(1);
setCancelable(false);
}
private void g() {
this.f40452a.runOnUiThread(new Runnable() {
@Override
public final void run() {
DialogC2744f.this.f();
}
});
}
@Override
public void dismiss(String str) {
this.f40452a.runOnUiThread(new Runnable() {
@Override
public final void run() {
DialogC2744f.this.e();
}
});
}
@Override
public void onBackPressed() {
this.f40455d.a("javascript:al_onBackPressed();");
dismiss("expanded_ad_dialog_back_button");
}
@Override
public void onCreate(Bundle bundle) {
super.onCreate(bundle);
d();
}
@Override
public void onStart() {
super.onStart();
try {
Window window = getWindow();
if (window != null) {
window.setFlags(this.f40452a.getWindow().getAttributes().flags, this.f40452a.getWindow().getAttributes().flags);
window.addFlags(16777216);
} else if (C2936o.a()) {
this.f40454c.b("ExpandedAdDialog", "Unable to turn on hardware acceleration - window is null");
}
} catch (Throwable th) {
if (C2936o.a()) {
this.f40454c.a("ExpandedAdDialog", "Setting window flags failed.", th);
}
}
}
private void a() {
this.f40455d.a("javascript:al_onCloseTapped();");
dismiss("expanded_ad_dialog_close_button");
}
public void b(View view) {
if (this.f40458g.isClickable()) {
this.f40458g.performClick();
}
}
private void d() {
RelativeLayout.LayoutParams layoutParams = new RelativeLayout.LayoutParams(-1, -1);
layoutParams.addRule(13);
this.f40455d.setLayoutParams(layoutParams);
RelativeLayout relativeLayout = new RelativeLayout(this.f40452a);
this.f40457f = relativeLayout;
relativeLayout.setLayoutParams(new RelativeLayout.LayoutParams(-1, -1));
this.f40457f.setBackgroundColor(-1157627904);
this.f40457f.addView(this.f40455d);
if (!this.f40456e.t1()) {
a(this.f40456e.n1());
g();
}
setContentView(this.f40457f);
}
public void e() {
this.f40457f.removeView(this.f40455d);
super.dismiss();
}
public void f() {
try {
if (this.f40458g == null) {
a();
}
this.f40458g.setVisibility(0);
this.f40458g.bringToFront();
AlphaAnimation alphaAnimation = new AlphaAnimation(0.0f, 1.0f);
alphaAnimation.setDuration(300L);
alphaAnimation.setAnimationListener(new a());
this.f40458g.startAnimation(alphaAnimation);
} catch (Throwable th) {
if (C2936o.a()) {
this.f40454c.a("ExpandedAdDialog", "Unable to fade in close button", th);
}
a();
}
}
public C2740b c() {
return this.f40455d;
}
private void a(AbstractC2743e.a aVar) {
if (this.f40458g != null) {
if (C2936o.a()) {
this.f40454c.k("ExpandedAdDialog", "Attempting to create duplicate close button");
return;
}
return;
}
AbstractC2743e a10 = AbstractC2743e.a(aVar, this.f40452a);
this.f40458g = a10;
a10.setVisibility(8);
this.f40458g.setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
DialogC2744f.this.a(view);
}
});
this.f40458g.setClickable(false);
int a11 = a(((Integer) this.f40453b.a(C2837l4.f41473x1)).intValue());
RelativeLayout.LayoutParams layoutParams = new RelativeLayout.LayoutParams(a11, a11);
layoutParams.addRule(10);
C2932k c2932k = this.f40453b;
C2837l4 c2837l4 = C2837l4.f41101A1;
layoutParams.addRule(((Boolean) c2932k.a(c2837l4)).booleanValue() ? 9 : 11);
this.f40458g.a(a11);
int a12 = a(((Integer) this.f40453b.a(C2837l4.f41489z1)).intValue());
int a13 = a(((Integer) this.f40453b.a(C2837l4.f41481y1)).intValue());
layoutParams.setMargins(a13, a12, a13, 0);
this.f40457f.addView(this.f40458g, layoutParams);
this.f40458g.bringToFront();
int a14 = a(((Integer) this.f40453b.a(C2837l4.f41109B1)).intValue());
View view = new View(this.f40452a);
view.setBackgroundColor(0);
int i10 = a11 + a14;
RelativeLayout.LayoutParams layoutParams2 = new RelativeLayout.LayoutParams(i10, i10);
layoutParams2.addRule(10);
layoutParams2.addRule(((Boolean) this.f40453b.a(c2837l4)).booleanValue() ? 9 : 11);
layoutParams2.setMargins(a13 - a(5), a12 - a(5), a13 - a(5), 0);
view.setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view2) {
DialogC2744f.this.b(view2);
}
});
this.f40457f.addView(view, layoutParams2);
view.bringToFront();
}
public C2921a b() {
return this.f40456e;
}
public void a(View view) {
a();
}
private int a(int i10) {
return AppLovinSdkUtils.dpToPx(this.f40452a, i10);
}
}