Add decompiled APK source code (JADX)

- 28,932 files
- Full Java source code
- Smali files
- Resources

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
2026-02-18 14:52:23 -08:00
parent cc210a65ea
commit f9d20bb3fc
26991 changed files with 2541449 additions and 0 deletions

View File

@@ -0,0 +1,124 @@
package com.mbridge.msdk.video.module;
import android.content.Context;
import android.text.TextUtils;
import android.util.AttributeSet;
import android.webkit.WebView;
import android.widget.RelativeLayout;
import com.mbridge.msdk.foundation.controller.c;
import com.mbridge.msdk.foundation.same.g.a;
import com.mbridge.msdk.foundation.same.report.i;
import com.mbridge.msdk.foundation.tools.af;
import com.mbridge.msdk.mbsignalcommon.windvane.g;
import com.mbridge.msdk.videocommon.d.b;
import com.mbridge.msdk.videocommon.download.d;
import com.mbridge.msdk.videocommon.download.e;
/* loaded from: classes4.dex */
public class MBridgeAlertWebview extends MBridgeH5EndCardView {
private String w;
public MBridgeAlertWebview(Context context) {
super(context);
}
public MBridgeAlertWebview(Context context, AttributeSet attributeSet) {
super(context, attributeSet);
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
public final String a() {
if (TextUtils.isEmpty(this.unitId)) {
return "";
}
b.a().a(c.m().k(), this.unitId, false);
String str = com.mbridge.msdk.videocommon.d.c.a;
this.w = str;
return !TextUtils.isEmpty(str) ? d.a().a(this.w) : "";
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
public void preLoadData(com.mbridge.msdk.video.signal.factory.b bVar) {
String a = a();
if (this.e && this.b != null && !TextUtils.isEmpty(a)) {
a aVar = new a(this.b);
aVar.a(this.b.getAppName());
this.p.setDownloadListener(aVar);
this.p.setCampaignId(this.b.getId());
setCloseVisible(8);
this.p.setApiManagerJSFactory(bVar);
this.p.setWebViewListener(new com.mbridge.msdk.mbsignalcommon.b.b() { // from class: com.mbridge.msdk.video.module.MBridgeAlertWebview.1
@Override // com.mbridge.msdk.mbsignalcommon.b.b, com.mbridge.msdk.mbsignalcommon.windvane.d
public final void a(WebView webView, String str) {
super.a(webView, str);
af.b("MBridgeAlertWebview", "finish+" + str);
g.a().a(webView);
}
@Override // com.mbridge.msdk.mbsignalcommon.b.b, com.mbridge.msdk.mbsignalcommon.windvane.d
public final void a(WebView webView, int i, String str, String str2) {
super.a(webView, i, str, str2);
af.b("MBridgeAlertWebview", "onReceivedError");
if (MBridgeAlertWebview.this.t) {
return;
}
af.a(MBridgeBaseView.TAG, "onReceivedError,url:" + str2);
MBridgeAlertWebview mBridgeAlertWebview = MBridgeAlertWebview.this;
i.a(mBridgeAlertWebview.a, mBridgeAlertWebview.b, mBridgeAlertWebview.w, MBridgeAlertWebview.this.unitId, 2, str, 1);
MBridgeAlertWebview.this.t = true;
}
@Override // com.mbridge.msdk.mbsignalcommon.b.b, com.mbridge.msdk.mbsignalcommon.windvane.d
public final void a(WebView webView, int i) {
String str;
super.a(webView, i);
af.b("MBridgeAlertWebview", "readyState : " + i);
MBridgeAlertWebview mBridgeAlertWebview = MBridgeAlertWebview.this;
if (mBridgeAlertWebview.t) {
return;
}
boolean z = i == 1;
mBridgeAlertWebview.s = z;
if (z) {
str = "readyState state is " + i;
} else {
str = "";
}
String str2 = str;
MBridgeAlertWebview mBridgeAlertWebview2 = MBridgeAlertWebview.this;
i.a(mBridgeAlertWebview2.a, mBridgeAlertWebview2.b, mBridgeAlertWebview2.w, MBridgeAlertWebview.this.unitId, i, str2, 1);
}
});
setHtmlSource(e.a().b(a));
this.s = false;
if (TextUtils.isEmpty(this.r)) {
af.a(MBridgeBaseView.TAG, "load url:" + a);
this.p.loadUrl(a);
} else {
af.a(MBridgeBaseView.TAG, "load html...");
this.p.loadDataWithBaseURL(a, this.r, "text/html", "UTF-8", null);
}
this.p.setBackgroundColor(0);
setBackgroundColor(0);
return;
}
this.notifyListener.a(101, "");
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
public void webviewshow() {
RelativeLayout relativeLayout = this.n;
if (relativeLayout != null) {
relativeLayout.setBackgroundColor(0);
}
super.webviewshow();
i.a(this.a, this.b, this.w, this.unitId, 2, 1);
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
public final RelativeLayout.LayoutParams b() {
RelativeLayout.LayoutParams layoutParams = new RelativeLayout.LayoutParams(-1, -1);
layoutParams.addRule(13, -1);
return layoutParams;
}
}

View File

@@ -0,0 +1,290 @@
package com.mbridge.msdk.video.module;
import android.content.Context;
import android.content.res.Configuration;
import android.text.TextUtils;
import android.util.AttributeSet;
import android.view.LayoutInflater;
import android.view.MotionEvent;
import android.view.View;
import android.view.ViewGroup;
import android.widget.LinearLayout;
import android.widget.RelativeLayout;
import com.mbridge.msdk.foundation.controller.c;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.tools.af;
import com.mbridge.msdk.foundation.tools.ak;
import com.mbridge.msdk.foundation.tools.x;
import com.mbridge.msdk.playercommon.exoplayer2.text.ttml.TtmlNode;
import com.mbridge.msdk.video.module.a.a;
import com.mbridge.msdk.video.module.a.a.f;
import org.json.JSONException;
import org.json.JSONObject;
/* loaded from: classes4.dex */
public abstract class MBridgeBaseView extends RelativeLayout {
public static final String TAG = "MBridgeBaseView";
protected Context a;
protected CampaignEx b;
protected LayoutInflater c;
protected int d;
protected boolean e;
protected float f;
protected float g;
protected boolean h;
protected int i;
protected boolean j;
protected int k;
protected int l;
public a notifyListener;
public void c() {
}
public CampaignEx getCampaign() {
return this.b;
}
public abstract void init(Context context);
public void setCampaign(CampaignEx campaignEx) {
this.b = campaignEx;
}
public void setNotifyListener(a aVar) {
this.notifyListener = aVar;
}
public MBridgeBaseView(Context context) {
this(context, null);
}
public MBridgeBaseView(Context context, AttributeSet attributeSet, boolean z, int i, boolean z2, int i2, int i3) {
super(context, attributeSet);
this.d = 1;
this.notifyListener = new f();
this.e = false;
this.k = 1;
this.l = 0;
this.a = context;
this.c = LayoutInflater.from(context);
this.h = z;
this.i = i;
this.j = z2;
this.k = i2;
this.l = i3;
init(context);
}
public MBridgeBaseView(Context context, AttributeSet attributeSet) {
super(context, attributeSet);
this.d = 1;
this.notifyListener = new f();
this.e = false;
this.k = 1;
this.l = 0;
this.a = context;
this.c = LayoutInflater.from(context);
init(context);
}
@Override // android.view.View
public void onConfigurationChanged(Configuration configuration) {
this.d = configuration.orientation;
super.onConfigurationChanged(configuration);
StringBuilder sb = new StringBuilder();
sb.append("onConfigurationChanged:");
sb.append(configuration.orientation);
}
public void onSelfConfigurationChanged(Configuration configuration) {
this.d = configuration.orientation;
StringBuilder sb = new StringBuilder();
sb.append("onSelfConfigurationChanged:");
sb.append(configuration.orientation);
}
public int findID(String str) {
return x.a(this.a.getApplicationContext(), str, "id");
}
public int findDyID(String str) {
if (TextUtils.isEmpty(str)) {
return -1;
}
return str.hashCode();
}
public int filterFindViewId(boolean z, String str) {
if (z) {
return findDyID(str);
}
return findID(str);
}
public int findLayout(String str) {
return x.a(this.a.getApplicationContext(), str, TtmlNode.TAG_LAYOUT);
}
public int findColor(String str) {
return x.a(this.a.getApplicationContext(), str, "color");
}
public int findDrawable(String str) {
return x.a(this.a.getApplicationContext(), str, "drawable");
}
public boolean isNotNULL(View... viewArr) {
if (viewArr == null) {
return false;
}
int length = viewArr.length;
int i = 0;
boolean z = false;
while (i < length) {
if (viewArr[i] == null) {
return false;
}
i++;
z = true;
}
return z;
}
public void setMatchParent() {
ViewGroup.LayoutParams layoutParams = getLayoutParams();
if (layoutParams == null) {
setLayoutParams(new ViewGroup.LayoutParams(-1, -1));
} else {
layoutParams.height = -1;
layoutParams.width = -1;
}
}
public void setWrapContent() {
ViewGroup.LayoutParams layoutParams = getLayoutParams();
if (layoutParams == null) {
setLayoutParams(new ViewGroup.LayoutParams(-2, -2));
} else {
layoutParams.height = -2;
layoutParams.width = -2;
}
}
public void defaultShow() {
af.a(TAG, "defaultShow");
}
public boolean isLandscape() {
return this.a.getResources().getConfiguration().orientation == 2;
}
public void setLayoutCenter(int i, int i2) {
RelativeLayout.LayoutParams parentRelativeLayoutParams = getParentRelativeLayoutParams();
LinearLayout.LayoutParams parentLinearLayoutParams = getParentLinearLayoutParams();
if (parentRelativeLayoutParams != null) {
parentRelativeLayoutParams.addRule(13);
if (i != -999) {
parentRelativeLayoutParams.width = i;
}
if (i2 != -999) {
parentRelativeLayoutParams.height = i2;
}
setLayoutParams(parentRelativeLayoutParams);
return;
}
if (parentLinearLayoutParams != null) {
parentLinearLayoutParams.gravity = 17;
if (i != -999) {
parentLinearLayoutParams.width = i;
}
if (i2 != -999) {
parentLinearLayoutParams.height = i2;
}
setLayoutParams(parentLinearLayoutParams);
}
}
public void setLayoutParam(int i, int i2, int i3, int i4) {
RelativeLayout.LayoutParams parentRelativeLayoutParams = getParentRelativeLayoutParams();
LinearLayout.LayoutParams parentLinearLayoutParams = getParentLinearLayoutParams();
if (parentRelativeLayoutParams != null) {
parentRelativeLayoutParams.topMargin = i2;
parentRelativeLayoutParams.leftMargin = i;
if (i3 != -999) {
parentRelativeLayoutParams.width = i3;
}
if (i4 != -999) {
parentRelativeLayoutParams.height = i4;
}
setLayoutParams(parentRelativeLayoutParams);
return;
}
if (parentLinearLayoutParams != null) {
parentLinearLayoutParams.topMargin = i2;
parentLinearLayoutParams.leftMargin = i;
if (i3 != -999) {
parentLinearLayoutParams.width = i3;
}
if (i4 != -999) {
parentLinearLayoutParams.height = i4;
}
setLayoutParams(parentLinearLayoutParams);
}
}
public RelativeLayout.LayoutParams getParentRelativeLayoutParams() {
ViewGroup.LayoutParams layoutParams = getLayoutParams();
if (layoutParams instanceof RelativeLayout.LayoutParams) {
return (RelativeLayout.LayoutParams) layoutParams;
}
return null;
}
public LinearLayout.LayoutParams getParentLinearLayoutParams() {
ViewGroup.LayoutParams layoutParams = getLayoutParams();
if (layoutParams instanceof LinearLayout.LayoutParams) {
return (LinearLayout.LayoutParams) layoutParams;
}
return null;
}
@Override // android.view.ViewGroup
public boolean onInterceptTouchEvent(MotionEvent motionEvent) {
this.f = motionEvent.getRawX();
this.g = motionEvent.getRawY();
return super.onInterceptTouchEvent(motionEvent);
}
public final String d() {
return a(0).toString();
}
public final JSONObject a(int i) {
JSONObject jSONObject;
JSONObject jSONObject2 = new JSONObject();
try {
jSONObject = new JSONObject();
} catch (JSONException e) {
e = e;
}
try {
jSONObject.put(com.mbridge.msdk.foundation.same.a.h, ak.b(c.m().c(), this.f));
jSONObject.put(com.mbridge.msdk.foundation.same.a.i, ak.b(c.m().c(), this.g));
jSONObject.put(com.mbridge.msdk.foundation.same.a.m, i);
try {
this.d = getContext().getResources().getConfiguration().orientation;
} catch (Exception e2) {
e2.printStackTrace();
}
jSONObject.put(com.mbridge.msdk.foundation.same.a.k, this.d);
jSONObject.put(com.mbridge.msdk.foundation.same.a.l, ak.d(getContext()));
return jSONObject;
} catch (JSONException e3) {
e = e3;
jSONObject2 = jSONObject;
e.printStackTrace();
return jSONObject2;
}
}
}

View File

@@ -0,0 +1,257 @@
package com.mbridge.msdk.video.module;
import android.animation.ObjectAnimator;
import android.content.Context;
import android.content.res.Configuration;
import android.text.TextUtils;
import android.util.AttributeSet;
import android.view.MotionEvent;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ImageView;
import android.widget.TextView;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.same.report.i;
import com.mbridge.msdk.foundation.tools.af;
import com.mbridge.msdk.video.dynview.e.h;
import com.mbridge.msdk.video.dynview.j.c;
import com.mbridge.msdk.video.module.a.a.e;
import com.mbridge.msdk.video.signal.factory.b;
import org.json.JSONException;
import org.json.JSONObject;
/* loaded from: classes4.dex */
public class MBridgeClickCTAView extends MBridgeClickCTAViewDiff {
public a ctaClickCallBack;
private ViewGroup m;
private ImageView n;
private TextView o;
private TextView p;
private String q;
private float r;
private float s;
private int t;
private ObjectAnimator u;
public interface a {
void ctaClick();
}
@Override // com.mbridge.msdk.video.module.MBridgeClickCTAViewDiff, com.mbridge.msdk.video.module.MBridgeBaseView
public void init(Context context) {
}
public void setCtaClickCallBack(a aVar) {
this.ctaClickCallBack = aVar;
}
public void setObjectAnimator(ObjectAnimator objectAnimator) {
this.u = objectAnimator;
}
public void setUnitId(String str) {
this.q = str;
}
public MBridgeClickCTAView(Context context) {
super(context);
}
public MBridgeClickCTAView(Context context, AttributeSet attributeSet) {
super(context, attributeSet);
}
@Override // com.mbridge.msdk.video.module.MBridgeBaseView
public final void c() {
super.c();
if (this.e) {
CampaignEx campaignEx = this.b;
if (campaignEx != null && campaignEx.isDynamicView()) {
setOnClickListener(new com.mbridge.msdk.widget.a() { // from class: com.mbridge.msdk.video.module.MBridgeClickCTAView.2
@Override // com.mbridge.msdk.widget.a
public final void onNoDoubleClick(View view) {
MBridgeClickCTAView mBridgeClickCTAView = MBridgeClickCTAView.this;
a aVar = mBridgeClickCTAView.ctaClickCallBack;
if (aVar != null) {
aVar.ctaClick();
} else {
MBridgeClickCTAView.b(mBridgeClickCTAView);
}
}
});
}
this.ctaTv.setOnClickListener(new com.mbridge.msdk.widget.a() { // from class: com.mbridge.msdk.video.module.MBridgeClickCTAView.3
@Override // com.mbridge.msdk.widget.a
public final void onNoDoubleClick(View view) {
MBridgeClickCTAView mBridgeClickCTAView = MBridgeClickCTAView.this;
a aVar = mBridgeClickCTAView.ctaClickCallBack;
if (aVar != null) {
aVar.ctaClick();
} else {
MBridgeClickCTAView.b(mBridgeClickCTAView);
}
}
});
ImageView imageView = this.n;
if (imageView != null) {
imageView.setOnClickListener(new View.OnClickListener() { // from class: com.mbridge.msdk.video.module.MBridgeClickCTAView.4
@Override // android.view.View.OnClickListener
public final void onClick(View view) {
}
});
}
}
}
@Override // com.mbridge.msdk.video.module.MBridgeClickCTAViewDiff
public void preLoadData(b bVar) {
CampaignEx campaignEx = this.b;
if (campaignEx != null) {
if (campaignEx.isDynamicView()) {
com.mbridge.msdk.video.dynview.b.a().a(new c().b(this, this.b), new h() { // from class: com.mbridge.msdk.video.module.MBridgeClickCTAView.1
@Override // com.mbridge.msdk.video.dynview.e.h
public final void viewInflaterSuccess(com.mbridge.msdk.video.dynview.a aVar) {
if (aVar != null) {
this.addView(aVar.a());
MBridgeClickCTAView mBridgeClickCTAView = MBridgeClickCTAView.this;
mBridgeClickCTAView.e = mBridgeClickCTAView.b();
MBridgeClickCTAView mBridgeClickCTAView2 = MBridgeClickCTAView.this;
mBridgeClickCTAView2.p = (TextView) mBridgeClickCTAView2.findViewById(mBridgeClickCTAView2.findID("mbridge_tv_desc"));
MBridgeClickCTAView.this.c();
}
}
@Override // com.mbridge.msdk.video.dynview.e.h
public final void viewInflaterFail(com.mbridge.msdk.video.dynview.c.a aVar) {
af.b(MBridgeBaseView.TAG, "errorMsg:" + aVar.b());
}
});
} else {
int findLayout = findLayout("mbridge_reward_clickable_cta");
if (findLayout >= 0) {
this.c.inflate(findLayout, this);
this.e = b();
c();
setWrapContent();
}
}
if (this.e) {
if (com.mbridge.msdk.e.b.a()) {
setChinaCTAData();
}
this.ctaTv.setText(this.b.getAdCall());
if (!TextUtils.isEmpty(this.b.getIconUrl())) {
com.mbridge.msdk.foundation.same.c.b.a(this.a.getApplicationContext()).a(this.b.getIconUrl(), new e(this.n, this.b, this.q) { // from class: com.mbridge.msdk.video.module.MBridgeClickCTAView.5
@Override // com.mbridge.msdk.video.module.a.a.e, com.mbridge.msdk.foundation.same.c.c
public final void onFailedLoad(String str, String str2) {
super.onFailedLoad(str, str2);
MBridgeClickCTAView.this.a();
}
});
} else {
a();
}
if (this.o != null && !TextUtils.isEmpty(this.b.getAppName())) {
this.o.setText(this.b.getAppName());
}
if (this.p == null || TextUtils.isEmpty(this.b.getAppDesc())) {
return;
}
this.p.setText(this.b.getAppDesc());
}
}
}
@Override // com.mbridge.msdk.video.module.MBridgeBaseView
public void onSelfConfigurationChanged(Configuration configuration) {
super.onSelfConfigurationChanged(configuration);
this.t = configuration.orientation;
}
/* JADX INFO: Access modifiers changed from: private */
public void a() {
ImageView imageView = this.n;
if (imageView != null) {
imageView.setVisibility(8);
}
}
/* JADX INFO: Access modifiers changed from: private */
public boolean b() {
this.m = (ViewGroup) findViewById(findID("mbridge_viewgroup_ctaroot"));
this.n = (ImageView) findViewById(findID("mbridge_iv_appicon"));
this.o = (TextView) findViewById(findID("mbridge_tv_title"));
TextView textView = (TextView) findViewById(findID("mbridge_tv_install"));
this.ctaTv = textView;
return isNotNULL(this.m, this.n, this.o, textView);
}
@Override // com.mbridge.msdk.video.module.MBridgeBaseView, android.view.ViewGroup
public boolean onInterceptTouchEvent(MotionEvent motionEvent) {
this.r = motionEvent.getRawX();
this.s = motionEvent.getRawY();
return super.onInterceptTouchEvent(motionEvent);
}
@Override // android.view.ViewGroup, android.view.View
public void onAttachedToWindow() {
super.onAttachedToWindow();
ObjectAnimator objectAnimator = this.u;
if (objectAnimator != null) {
try {
objectAnimator.start();
} catch (Exception e) {
e.printStackTrace();
}
}
}
@Override // android.view.ViewGroup, android.view.View
public void onDetachedFromWindow() {
super.onDetachedFromWindow();
ObjectAnimator objectAnimator = this.u;
if (objectAnimator != null) {
try {
objectAnimator.cancel();
} catch (Exception e) {
e.printStackTrace();
}
}
}
public static /* synthetic */ void b(MBridgeClickCTAView mBridgeClickCTAView) {
JSONObject jSONObject;
JSONException e;
CampaignEx campaignEx = mBridgeClickCTAView.b;
if (campaignEx != null && campaignEx.isDynamicView()) {
try {
CampaignEx.c rewardTemplateMode = mBridgeClickCTAView.b.getRewardTemplateMode();
String str = "";
if (rewardTemplateMode != null) {
str = rewardTemplateMode.f() + "";
}
i.a(com.mbridge.msdk.foundation.controller.c.m().c(), "cta_click", mBridgeClickCTAView.b.getCampaignUnitId(), mBridgeClickCTAView.b.isBidCampaign(), mBridgeClickCTAView.b.getRequestId(), mBridgeClickCTAView.b.getRequestIdNotice(), mBridgeClickCTAView.b.getId(), str);
} catch (Exception e2) {
e2.printStackTrace();
}
}
try {
jSONObject = new JSONObject();
try {
jSONObject.put(com.mbridge.msdk.foundation.same.a.j, mBridgeClickCTAView.a(0));
} catch (JSONException e3) {
e = e3;
e.printStackTrace();
mBridgeClickCTAView.b.setTriggerClickSource(1);
mBridgeClickCTAView.b.setClickTempSource(1);
mBridgeClickCTAView.notifyListener.a(105, jSONObject);
}
} catch (JSONException e4) {
jSONObject = null;
e = e4;
}
mBridgeClickCTAView.b.setTriggerClickSource(1);
mBridgeClickCTAView.b.setClickTempSource(1);
mBridgeClickCTAView.notifyListener.a(105, jSONObject);
}
}

View File

@@ -0,0 +1,33 @@
package com.mbridge.msdk.video.module;
import android.content.Context;
import android.util.AttributeSet;
import android.widget.TextView;
import com.mbridge.msdk.video.signal.factory.b;
/* loaded from: classes4.dex */
public class MBridgeClickCTAViewDiff extends MBridgeBaseView {
public TextView ctaTv;
@Override // com.mbridge.msdk.video.module.MBridgeBaseView
public void init(Context context) {
}
public void preLoadData(b bVar) {
}
public void setChinaCTAData() {
}
public MBridgeClickCTAViewDiff(Context context) {
super(context);
}
public MBridgeClickCTAViewDiff(Context context, AttributeSet attributeSet, boolean z, int i, boolean z2, int i2, int i3) {
super(context, attributeSet, z, i, z2, i2, i3);
}
public MBridgeClickCTAViewDiff(Context context, AttributeSet attributeSet) {
super(context, attributeSet);
}
}

View File

@@ -0,0 +1,167 @@
package com.mbridge.msdk.video.module;
import android.R;
import android.app.Activity;
import android.content.Context;
import android.content.res.Configuration;
import android.graphics.drawable.GradientDrawable;
import android.text.TextUtils;
import android.util.AttributeSet;
import android.util.Base64;
import android.view.View;
import android.view.ViewGroup;
import android.webkit.WebView;
import android.widget.RelativeLayout;
import androidx.annotation.RequiresApi;
import com.mbridge.msdk.foundation.controller.c;
import com.mbridge.msdk.foundation.download.download.H5DownLoadManager;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.same.report.d.d;
import com.mbridge.msdk.foundation.same.report.d.e;
import com.mbridge.msdk.foundation.tools.af;
import com.mbridge.msdk.foundation.tools.ak;
import com.mbridge.msdk.mbsignalcommon.windvane.WindVaneWebView;
import com.mbridge.msdk.mbsignalcommon.windvane.g;
import com.mbridge.msdk.video.signal.factory.b;
import org.json.JSONObject;
/* loaded from: classes4.dex */
public class MBridgeClickMiniCardView extends MBridgeH5EndCardView {
private boolean w;
public MBridgeClickMiniCardView(Context context) {
super(context);
this.w = false;
}
public MBridgeClickMiniCardView(Context context, AttributeSet attributeSet) {
super(context, attributeSet);
this.w = false;
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView, com.mbridge.msdk.video.module.MBridgeBaseView
@RequiresApi(api = 11)
public void onSelfConfigurationChanged(Configuration configuration) {
if (this.e) {
a(this.m);
}
super.onSelfConfigurationChanged(configuration);
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
public final RelativeLayout.LayoutParams b() {
RelativeLayout.LayoutParams layoutParams = new RelativeLayout.LayoutParams(-2, -2);
layoutParams.addRule(13, -1);
return layoutParams;
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
@RequiresApi(api = 11)
public final void e() {
super.e();
if (this.e) {
setBackgroundResource(findColor("mbridge_reward_minicard_bg"));
a(this.m);
setClickable(true);
}
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
public final String a() {
CampaignEx campaignEx = this.b;
if (campaignEx == null) {
return null;
}
CampaignEx.c rewardTemplateMode = campaignEx.getRewardTemplateMode();
String c = rewardTemplateMode != null ? rewardTemplateMode.c() : null;
if (TextUtils.isEmpty(c) || !c.contains(".zip")) {
return c;
}
String h5ResAddress = H5DownLoadManager.getInstance().getH5ResAddress(c);
return !TextUtils.isEmpty(h5ResAddress) ? h5ResAddress : c;
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
public void preLoadData(b bVar) {
super.preLoadData(bVar);
setCloseVisible(0);
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
public void webviewshow() {
WindVaneWebView windVaneWebView = this.p;
if (windVaneWebView != null) {
windVaneWebView.post(new Runnable() { // from class: com.mbridge.msdk.video.module.MBridgeClickMiniCardView.1
@Override // java.lang.Runnable
public final void run() {
try {
af.a(MBridgeBaseView.TAG, "webviewshow");
String str = "";
try {
int[] iArr = new int[2];
MBridgeClickMiniCardView.this.p.getLocationOnScreen(iArr);
af.b(MBridgeBaseView.TAG, "coordinate:" + iArr[0] + "--" + iArr[1]);
JSONObject jSONObject = new JSONObject();
jSONObject.put("startX", ak.b(c.m().c(), (float) iArr[0]));
jSONObject.put("startY", ak.b(c.m().c(), (float) iArr[1]));
str = jSONObject.toString();
} catch (Throwable th) {
af.b(MBridgeBaseView.TAG, th.getMessage(), th);
}
g.a().a((WebView) MBridgeClickMiniCardView.this.p, "webviewshow", Base64.encodeToString(str.toString().getBytes(), 2));
} catch (Exception e) {
e.printStackTrace();
}
}
});
e eVar = new e();
eVar.a("type", 3);
d.a().a("2000133", this.b, eVar);
}
}
@RequiresApi(api = 11)
private void a(View view) {
int f = ak.f(this.a);
ViewGroup.LayoutParams layoutParams = view.getLayoutParams();
layoutParams.width = (int) ((f * 0.7f) + 0.5f);
layoutParams.height = (int) ((ak.e(this.a) * 0.7f) + 0.5f);
view.setLayoutParams(layoutParams);
}
public void setMBridgeClickMiniCardViewTransparent() {
setBackgroundColor(0);
}
public void setMBridgeClickMiniCardViewClickable(boolean z) {
setClickable(z);
}
public void setMiniCardLocation(int i, int i2, int i3, int i4) {
this.w = true;
resizeMiniCard(i3, i4);
}
public void resizeMiniCard(int i, int i2) {
View findViewById = ((Activity) this.a).getWindow().findViewById(R.id.content);
int width = findViewById.getWidth();
int height = findViewById.getHeight();
if (i <= 0 || i2 <= 0 || i > width || i2 > height) {
return;
}
ViewGroup.LayoutParams layoutParams = this.m.getLayoutParams();
layoutParams.width = i;
layoutParams.height = i2;
this.m.setLayoutParams(layoutParams);
}
public void setRadius(int i) {
if (i > 0) {
GradientDrawable gradientDrawable = new GradientDrawable();
gradientDrawable.setCornerRadius(ak.a(getContext(), i));
gradientDrawable.setColor(-1);
this.p.setBackground(gradientDrawable);
this.p.setClipToOutline(true);
}
}
}

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,48 @@
package com.mbridge.msdk.video.module;
import android.content.Context;
import android.text.TextUtils;
import android.util.AttributeSet;
import com.mbridge.msdk.click.a;
import com.mbridge.msdk.click.i;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.tools.af;
import com.mbridge.msdk.mbsignalcommon.mraid.b;
import com.mbridge.msdk.video.signal.h;
/* loaded from: classes4.dex */
public abstract class MBridgeH5EndCardViewDiff extends MBridgeBaseView implements i, b, h {
public String unitId;
public MBridgeH5EndCardViewDiff(Context context) {
super(context);
}
public MBridgeH5EndCardViewDiff(Context context, AttributeSet attributeSet) {
super(context, attributeSet);
}
public void open(String str) {
try {
String clickURL = this.b.getClickURL();
if (!TextUtils.isEmpty(str)) {
this.b.setClickURL(str);
reportOpen(str);
}
a aVar = new a(getContext(), this.unitId);
aVar.a(this);
aVar.a(this.b);
this.b.setClickURL(clickURL);
this.notifyListener.a(126, "");
} catch (Exception e) {
af.b(MBridgeBaseView.TAG, e.getMessage());
}
}
public void reportOpen(String str) {
CampaignEx mraidCampaign = getMraidCampaign();
if (mraidCampaign != null) {
new com.mbridge.msdk.foundation.same.report.h(getContext()).a(mraidCampaign.getRequestId(), mraidCampaign.getRequestIdNotice(), mraidCampaign.getId(), this.unitId, str, this.b.isBidCampaign());
}
}
}

View File

@@ -0,0 +1,73 @@
package com.mbridge.msdk.video.module;
import android.content.Context;
import android.text.TextUtils;
import android.util.AttributeSet;
import android.webkit.URLUtil;
import android.webkit.WebView;
import com.mbridge.msdk.click.c;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.tools.af;
import com.mbridge.msdk.foundation.tools.aj;
import com.mbridge.msdk.mbsignalcommon.windvane.g;
import com.mbridge.msdk.out.BaseTrackingListener;
import com.mbridge.msdk.video.signal.factory.b;
/* loaded from: classes4.dex */
public class MBridgeLandingPageView extends MBridgeH5EndCardView {
public MBridgeLandingPageView(Context context) {
super(context);
}
public MBridgeLandingPageView(Context context, AttributeSet attributeSet) {
super(context, attributeSet);
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView, com.mbridge.msdk.video.module.MBridgeBaseView
public void init(Context context) {
super.init(context);
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
public final String a() {
CampaignEx campaignEx = this.b;
if (campaignEx != null) {
return c.a(campaignEx.getClickURL(), "-999", "-999");
}
return null;
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
public void preLoadData(b bVar) {
if (this.e) {
this.p.setFilter(new a());
}
super.preLoadData(bVar);
setVisibility(0);
setCloseVisible(0);
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
public void webviewshow() {
try {
af.a(MBridgeBaseView.TAG, "webviewshow");
g.a().a((WebView) this.p, "webviewshow", "");
} catch (Exception e) {
e.printStackTrace();
}
}
public static final class a implements com.mbridge.msdk.mbsignalcommon.base.a {
private a() {
}
@Override // com.mbridge.msdk.mbsignalcommon.base.a
public final boolean a(String str) {
if (TextUtils.isEmpty(str) || URLUtil.isNetworkUrl(str)) {
return false;
}
aj.a(com.mbridge.msdk.foundation.controller.c.m().c(), str, (BaseTrackingListener) null);
return true;
}
}
}

View File

@@ -0,0 +1,967 @@
package com.mbridge.msdk.video.module;
import android.annotation.TargetApi;
import android.content.Context;
import android.content.res.Configuration;
import android.graphics.Bitmap;
import android.graphics.drawable.GradientDrawable;
import android.renderscript.Allocation;
import android.renderscript.Element;
import android.renderscript.RenderScript;
import android.renderscript.ScriptIntrinsicBlur;
import android.text.TextUtils;
import android.util.AttributeSet;
import android.view.View;
import android.view.ViewGroup;
import android.view.animation.AlphaAnimation;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.RelativeLayout;
import android.widget.TextView;
import androidx.core.internal.view.SupportMenu;
import com.mbridge.msdk.MBridgeConstans;
import com.mbridge.msdk.dycreator.baseview.MBHeatLevelLayoutView;
import com.mbridge.msdk.dycreator.baseview.MBStarLevelLayoutView;
import com.mbridge.msdk.dycreator.baseview.cusview.MBridgeBaitClickView;
import com.mbridge.msdk.foundation.controller.c;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.entity.CampaignUnit;
import com.mbridge.msdk.foundation.same.report.d.d;
import com.mbridge.msdk.foundation.same.report.d.e;
import com.mbridge.msdk.foundation.same.report.i;
import com.mbridge.msdk.foundation.tools.af;
import com.mbridge.msdk.foundation.tools.ak;
import com.mbridge.msdk.foundation.tools.aq;
import com.mbridge.msdk.shake.MBShakeView;
import com.mbridge.msdk.shake.a;
import com.mbridge.msdk.video.dynview.e.h;
import com.mbridge.msdk.video.dynview.widget.MBridgeLevelLayoutView;
import com.mbridge.msdk.video.module.a.a.j;
import com.mbridge.msdk.video.signal.factory.b;
import com.mbridge.msdk.videocommon.view.RoundImageView;
import com.mbridge.msdk.videocommon.view.StarLevelView;
import com.mbridge.msdk.widget.FeedBackButton;
import java.util.Iterator;
import java.util.Locale;
import org.json.JSONException;
import org.json.JSONObject;
/* loaded from: classes4.dex */
public class MBridgeNativeEndCardView extends MBridgeNativeEndCardViewDiff {
private LinearLayout A;
private Runnable B;
private Runnable C;
private RelativeLayout D;
private b E;
private boolean F;
private boolean G;
private boolean H;
private boolean I;
private int J;
private AlphaAnimation K;
private int L;
private int M;
private int N;
private int O;
private Bitmap P;
private View Q;
private FeedBackButton R;
private String S;
private CampaignUnit T;
private MBShakeView U;
private com.mbridge.msdk.shake.b V;
private MBridgeBaitClickView W;
private boolean aa;
private int ab;
private String ac;
private ViewGroup m;
private ViewGroup n;
private RelativeLayout o;
private ImageView p;
private ImageView q;
private ImageView r;
private ImageView s;
private TextView t;
private ImageView u;
private ImageView v;
private TextView w;
private TextView x;
private TextView y;
private LinearLayout z;
@Override // com.mbridge.msdk.video.module.MBridgeBaseView
public void init(Context context) {
}
public boolean isDyXmlSuccess() {
return this.aa;
}
public void setCloseBtnDelay(int i) {
this.J = i;
}
public void setOnPause() {
this.H = false;
}
public void setOnResume() {
this.H = true;
}
public void setUnitId(String str) {
this.S = str;
}
public MBridgeNativeEndCardView(Context context) {
super(context);
this.F = false;
this.G = false;
this.H = false;
this.I = false;
this.J = 0;
this.aa = false;
this.ab = 1;
}
public MBridgeNativeEndCardView(Context context, AttributeSet attributeSet) {
super(context, attributeSet);
this.F = false;
this.G = false;
this.H = false;
this.I = false;
this.J = 0;
this.aa = false;
this.ab = 1;
}
public MBridgeNativeEndCardView(Context context, AttributeSet attributeSet, boolean z, int i, boolean z2, int i2, int i3) {
super(context, attributeSet, z, i, z2, i2, i3);
this.F = false;
this.G = false;
this.H = false;
this.I = false;
this.J = 0;
this.aa = false;
this.ab = 1;
}
@Override // android.view.ViewGroup, android.view.View
public void onAttachedToWindow() {
int parseInt;
int parseInt2;
int i;
MBridgeBaitClickView mBridgeBaitClickView;
super.onAttachedToWindow();
if (this.B == null) {
this.B = new Runnable() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.1
@Override // java.lang.Runnable
public final void run() {
MBridgeNativeEndCardView.this.G = true;
if (MBridgeNativeEndCardView.this.Q != null) {
MBridgeNativeEndCardView.this.Q.setVisibility(0);
}
}
};
}
Runnable runnable = this.B;
if (runnable != null) {
postDelayed(runnable, this.J * 1000);
if (!this.H) {
this.H = true;
}
try {
CampaignEx campaignEx = this.b;
if (campaignEx != null && campaignEx.isDynamicView()) {
String str = this.b.getendcard_url();
if (TextUtils.isEmpty(str)) {
str = this.b.getEndScreenUrl();
}
String a = aq.a(str, "alac");
if (!TextUtils.isEmpty(a) && a.equals("1") && this.b.getAutoShowStoreMiniCard() != 1) {
postDelayed(new Runnable() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.8
@Override // java.lang.Runnable
public final void run() {
MBridgeNativeEndCardView.this.b.setTriggerClickSource(2);
MBridgeNativeEndCardView.this.b.setClickType(1);
MBridgeNativeEndCardView.a(MBridgeNativeEndCardView.this, 2);
}
}, 1000L);
}
}
} catch (Throwable th) {
af.b(MBridgeBaseView.TAG, th.getMessage());
}
}
try {
CampaignEx campaignEx2 = this.b;
if (campaignEx2 != null && campaignEx2.isDynamicView()) {
String str2 = this.b.getendcard_url();
if (TextUtils.isEmpty(str2)) {
str2 = this.b.getEndScreenUrl();
}
String a2 = aq.a(str2, "bait_click");
try {
i = Integer.parseInt(a2);
} catch (Throwable th2) {
af.b(MBridgeBaseView.TAG, th2.getMessage());
i = 1;
}
if (!TextUtils.isEmpty(a2) && i != 0 && (mBridgeBaitClickView = this.W) != null) {
mBridgeBaitClickView.setVisibility(0);
this.W.init(1342177280, i);
if (this.b.getEcTemplateId() == 1302) {
GradientDrawable gradientDrawable = new GradientDrawable();
gradientDrawable.setShape(0);
gradientDrawable.setColor(1342177280);
gradientDrawable.setStroke(0, SupportMenu.CATEGORY_MASK);
gradientDrawable.setCornerRadius(25.0f);
this.W.setBackground(gradientDrawable);
}
this.W.startAnimation();
this.W.setOnClickListener(new View.OnClickListener() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.7
@Override // android.view.View.OnClickListener
public final void onClick(View view) {
MBridgeNativeEndCardView.this.b.setTriggerClickSource(2);
MBridgeNativeEndCardView.a(MBridgeNativeEndCardView.this, 0);
}
});
}
}
} catch (Throwable th3) {
af.b(MBridgeBaseView.TAG, th3.getMessage());
}
try {
CampaignEx campaignEx3 = this.b;
if (campaignEx3 != null && campaignEx3.isDynamicView()) {
String str3 = this.b.getendcard_url();
if (TextUtils.isEmpty(str3)) {
str3 = this.b.getEndScreenUrl();
}
String a3 = aq.a(str3, "shake_show");
String a4 = aq.a(str3, "shake_strength");
String a5 = aq.a(str3, "shake_time");
if (!TextUtils.isEmpty(a3) && a3.equals("1") && this.U == null) {
MBridgeBaitClickView mBridgeBaitClickView2 = this.W;
if (mBridgeBaitClickView2 != null) {
mBridgeBaitClickView2.setVisibility(8);
}
MBShakeView mBShakeView = new MBShakeView(getContext());
this.U = mBShakeView;
mBShakeView.initView(this.b.getAdCall(), true);
RelativeLayout.LayoutParams layoutParams = new RelativeLayout.LayoutParams(-2, -2);
if (!isLandscape()) {
layoutParams.addRule(2, filterFindViewId(this.aa, "mbridge_iv_logo"));
layoutParams.addRule(14);
this.U.setPadding(0, 0, 0, ak.a(getContext(), 20.0f));
} else {
layoutParams.addRule(13);
}
this.U.setLayoutParams(layoutParams);
RelativeLayout relativeLayout = this.o;
if (relativeLayout != null && relativeLayout.isShown()) {
this.o.addView(this.U);
TextView textView = this.ctaView;
if (textView != null) {
textView.setVisibility(4);
}
this.U.setOnClickListener(new View.OnClickListener() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.5
@Override // android.view.View.OnClickListener
public final void onClick(View view) {
MBridgeNativeEndCardView.this.b.setTriggerClickSource(5);
MBridgeNativeEndCardView.a(MBridgeNativeEndCardView.this, 0);
}
});
int i2 = 10;
if (!TextUtils.isEmpty(a4) && (parseInt2 = Integer.parseInt(a4)) > 0) {
i2 = parseInt2;
}
int i3 = 5000;
if (!TextUtils.isEmpty(a5) && (parseInt = Integer.parseInt(a5)) > 0) {
i3 = parseInt * 1000;
}
this.V = new com.mbridge.msdk.shake.b(i2, i3) { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.6
@Override // com.mbridge.msdk.shake.b
public final void a() {
if ((com.mbridge.msdk.e.b.a() && MBridgeNativeEndCardView.this.checkChinaShakeState()) || MBridgeNativeEndCardView.this.I || !MBridgeNativeEndCardView.this.H) {
return;
}
MBridgeNativeEndCardView mBridgeNativeEndCardView = MBridgeNativeEndCardView.this;
mBridgeNativeEndCardView.f = 0.0f;
mBridgeNativeEndCardView.g = 0.0f;
mBridgeNativeEndCardView.b.setTriggerClickSource(5);
MBridgeNativeEndCardView.a(MBridgeNativeEndCardView.this, 4);
}
};
a.a().a(this.V);
}
}
}
} catch (Throwable th4) {
af.b(MBridgeBaseView.TAG, th4.getMessage());
}
try {
CampaignEx campaignEx4 = this.b;
if (campaignEx4 != null && campaignEx4.getAutoShowStoreMiniCard() != 0 && !TextUtils.isEmpty(this.b.getDeepLinkURL())) {
long showStoreMiniCardDelayTime = this.b.getShowStoreMiniCardDelayTime();
if (showStoreMiniCardDelayTime == 0) {
showStoreMiniCardDelayTime = 1;
}
if (this.C == null) {
this.C = new Runnable() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.9
@Override // java.lang.Runnable
public final void run() {
MBridgeNativeEndCardView.this.b.setTriggerClickSource(2);
MBridgeNativeEndCardView.this.b.setClickType(1);
MBridgeNativeEndCardView.a(MBridgeNativeEndCardView.this, 2);
}
};
}
postDelayed(this.C, showStoreMiniCardDelayTime * 1000);
}
} catch (Throwable th5) {
af.b(MBridgeBaseView.TAG, th5.getMessage());
}
}
@Override // android.view.ViewGroup, android.view.View
public void onDetachedFromWindow() {
super.onDetachedFromWindow();
Runnable runnable = this.B;
if (runnable != null) {
removeCallbacks(runnable);
}
Runnable runnable2 = this.C;
if (runnable2 != null) {
removeCallbacks(runnable2);
}
if (this.V != null) {
a.a().b(this.V);
this.V = null;
}
}
/* JADX INFO: Access modifiers changed from: private */
public void a() {
int e = e();
if (e > 0) {
this.e = b(e);
b();
CampaignEx campaignEx = this.b;
if (campaignEx != null) {
campaignEx.setECTemplateRenderSucc(false);
}
}
}
/* JADX INFO: Access modifiers changed from: private */
public void b() {
c();
if (!this.e) {
this.notifyListener.a(104, "");
}
AlphaAnimation alphaAnimation = new AlphaAnimation(0.0f, 100.0f);
this.K = alphaAnimation;
alphaAnimation.setDuration(200L);
}
@Override // com.mbridge.msdk.video.module.MBridgeBaseView
public void onSelfConfigurationChanged(Configuration configuration) {
super.onSelfConfigurationChanged(configuration);
CampaignEx campaignEx = this.b;
if (campaignEx == null || !campaignEx.isDynamicView()) {
RelativeLayout relativeLayout = this.D;
if (relativeLayout != null) {
relativeLayout.setVisibility(4);
}
int i = configuration.orientation;
this.d = i;
if (i == 2) {
removeView(this.m);
a(this.n);
} else {
removeView(this.n);
a(this.m);
}
}
}
public boolean canBackPress() {
View view = this.Q;
return view != null && view.getVisibility() == 0;
}
public void notifyShowListener() {
this.notifyListener.a(110, "");
}
private void a(View view) {
if (view == null) {
setLayout();
preLoadData(this.E);
} else {
if (view.getParent() != null) {
((ViewGroup) view.getParent()).removeView(view);
}
addView(view);
b(view);
c();
}
f();
}
private boolean b(int i) {
if (isLandscape()) {
ViewGroup viewGroup = (ViewGroup) this.c.inflate(i, (ViewGroup) null);
this.n = viewGroup;
addView(viewGroup);
return b(this.n);
}
ViewGroup viewGroup2 = (ViewGroup) this.c.inflate(i, (ViewGroup) null);
this.m = viewGroup2;
addView(viewGroup2);
return b(this.m);
}
@Override // com.mbridge.msdk.video.module.MBridgeBaseView
public final void c() {
if (this.e) {
this.o.setOnClickListener(new View.OnClickListener() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.14
@Override // android.view.View.OnClickListener
public final void onClick(View view) {
if (MBridgeNativeEndCardView.this.F) {
MBridgeNativeEndCardView.this.b.setTriggerClickSource(2);
MBridgeNativeEndCardView.a(MBridgeNativeEndCardView.this, 1);
}
}
});
this.Q.setOnClickListener(new View.OnClickListener() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.15
@Override // android.view.View.OnClickListener
public final void onClick(View view) {
if (MBridgeNativeEndCardView.this.h) {
try {
com.mbridge.msdk.video.dynview.moffer.a.a().b();
} catch (Exception e) {
af.b(MBridgeBaseView.TAG, e.getMessage());
}
try {
CampaignEx campaignEx = MBridgeNativeEndCardView.this.b;
if (campaignEx != null) {
String a = aq.a(campaignEx.getendcard_url(), "ecid");
String a2 = aq.a(MBridgeNativeEndCardView.this.b.getendcard_url(), "mof");
e eVar = new e();
eVar.a("type", "choseFromTwoClose");
eVar.a("endcard_id", a);
eVar.a("mof", a2);
com.mbridge.msdk.video.module.b.a.a("2000103", MBridgeNativeEndCardView.this.b, eVar);
}
} catch (Exception e2) {
if (MBridgeConstans.DEBUG) {
e2.printStackTrace();
}
}
}
try {
e eVar2 = new e();
eVar2.a("type", 2);
d.a().a("2000152", eVar2);
d.a().a("2000134", MBridgeNativeEndCardView.this.b);
} catch (Throwable th) {
if (MBridgeConstans.DEBUG) {
th.printStackTrace();
}
}
MBridgeNativeEndCardView.this.notifyListener.a(104, "");
}
});
TextView textView = this.ctaView;
if (textView != null) {
textView.setOnClickListener(new com.mbridge.msdk.widget.a() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.16
@Override // com.mbridge.msdk.widget.a
public final void onNoDoubleClick(View view) {
MBridgeNativeEndCardView.this.b.setTriggerClickSource(1);
MBridgeNativeEndCardView.a(MBridgeNativeEndCardView.this, 0);
}
});
}
this.r.setOnClickListener(new com.mbridge.msdk.widget.a() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.17
@Override // com.mbridge.msdk.widget.a
public final void onNoDoubleClick(View view) {
if (MBridgeNativeEndCardView.this.ctaView != null) {
if (!com.mbridge.msdk.e.b.a() || MBridgeNativeEndCardView.this.checkProgressBarIntercepted()) {
MBridgeNativeEndCardView.this.b.setTriggerClickSource(2);
MBridgeNativeEndCardView.a(MBridgeNativeEndCardView.this, 0);
}
}
}
});
this.q.setOnClickListener(new com.mbridge.msdk.widget.a() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.2
@Override // com.mbridge.msdk.widget.a
public final void onNoDoubleClick(View view) {
if (MBridgeNativeEndCardView.this.ctaView != null) {
if (!com.mbridge.msdk.e.b.a() || MBridgeNativeEndCardView.this.checkProgressBarIntercepted()) {
MBridgeNativeEndCardView.this.b.setTriggerClickSource(2);
MBridgeNativeEndCardView.a(MBridgeNativeEndCardView.this, 0);
}
}
}
});
}
}
/* JADX INFO: Access modifiers changed from: private */
public boolean b(View view) {
try {
this.o = (RelativeLayout) view.findViewById(filterFindViewId(this.aa, "mbridge_native_ec_layout"));
this.q = (ImageView) view.findViewById(filterFindViewId(this.aa, "mbridge_iv_adbanner"));
this.r = (ImageView) view.findViewById(filterFindViewId(this.aa, "mbridge_iv_icon"));
this.s = (ImageView) view.findViewById(filterFindViewId(this.aa, "mbridge_iv_flag"));
this.t = (TextView) view.findViewById(filterFindViewId(this.aa, "mbridge_tv_flag"));
this.u = (ImageView) view.findViewById(filterFindViewId(this.aa, "mbridge_iv_logo"));
this.v = (ImageView) view.findViewById(filterFindViewId(this.aa, "mbridge_iv_link"));
this.w = (TextView) view.findViewById(filterFindViewId(this.aa, "mbridge_tv_apptitle"));
this.z = (LinearLayout) view.findViewById(filterFindViewId(this.aa, "mbridge_sv_starlevel"));
this.A = (LinearLayout) view.findViewById(filterFindViewId(this.aa, "mbridge_sv_heat_count_level"));
this.Q = view.findViewById(filterFindViewId(this.aa, "mbridge_iv_close"));
this.ctaView = (TextView) view.findViewById(filterFindViewId(this.aa, "mbridge_tv_cta"));
this.R = (FeedBackButton) view.findViewById(filterFindViewId(this.aa, "mbridge_native_endcard_feed_btn"));
this.D = (RelativeLayout) view.findViewById(filterFindViewId(this.aa, "mbridge_native_ec_controller"));
this.p = (ImageView) view.findViewById(filterFindViewId(this.aa, "mbridge_iv_adbanner_bg"));
this.W = (MBridgeBaitClickView) findViewById(filterFindViewId(this.aa, "mbridge_animation_click_view"));
this.x = (TextView) view.findViewById(filterFindViewId(this.aa, "mbridge_tv_appdesc"));
if (this.h) {
ImageView imageView = this.q;
if (imageView != null && (imageView instanceof RoundImageView)) {
((RoundImageView) imageView).setBorderRadius(10);
}
ImageView imageView2 = this.r;
if (imageView2 != null && (imageView2 instanceof RoundImageView)) {
((RoundImageView) imageView2).setBorderRadius(10);
}
return isNotNULL(this.q, this.r, this.w, this.z, this.Q, this.ctaView);
}
TextView textView = (TextView) view.findViewById(filterFindViewId(this.aa, "mbridge_tv_number"));
this.y = textView;
return isNotNULL(this.q, this.r, this.w, this.x, textView, this.z, this.Q, this.ctaView);
} catch (Throwable th) {
af.b(MBridgeBaseView.TAG, th.getMessage(), th);
return false;
}
}
/* JADX WARN: Code restructure failed: missing block: B:10:0x001b, code lost:
r1 = "mbridge_reward_endcard_native_half_landscape";
*/
/* JADX WARN: Code restructure failed: missing block: B:11:0x001c, code lost:
r3 = r1;
*/
/* JADX WARN: Code restructure failed: missing block: B:23:0x002e, code lost:
if (r6.j != false) goto L11;
*/
/* JADX WARN: Code restructure failed: missing block: B:9:0x0019, code lost:
if (r6.j != false) goto L11;
*/
/*
Code decompiled incorrectly, please refer to instructions dump.
To view partially-correct add '--show-bad-code' argument
*/
private int e() {
/*
r6 = this;
int r0 = r6.k
java.lang.String r1 = "mbridge_reward_endcard_native_land"
java.lang.String r2 = "mbridge_reward_endcard_native_half_landscape"
java.lang.String r3 = "mbridge_reward_endcard_native_hor"
java.lang.String r4 = "mbridge_reward_endcard_native_half_portrait"
if (r0 != 0) goto L1e
boolean r0 = r6.j
if (r0 == 0) goto L11
r3 = r4
L11:
boolean r0 = r6.isLandscape()
if (r0 == 0) goto L31
boolean r0 = r6.j
if (r0 == 0) goto L1c
L1b:
r1 = r2
L1c:
r3 = r1
goto L31
L1e:
r5 = 1
if (r0 != r5) goto L27
boolean r5 = r6.j
if (r5 == 0) goto L29
r3 = r4
goto L29
L27:
java.lang.String r3 = ""
L29:
r4 = 2
if (r0 != r4) goto L31
boolean r0 = r6.j
if (r0 == 0) goto L1c
goto L1b
L31:
int r0 = r6.findLayout(r3)
return r0
*/
throw new UnsupportedOperationException("Method not decompiled: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.e():int");
}
@TargetApi(17)
public Bitmap blurBitmap(Bitmap bitmap) {
try {
Bitmap createBitmap = Bitmap.createBitmap(bitmap.getWidth(), bitmap.getHeight(), Bitmap.Config.ARGB_4444);
RenderScript create = RenderScript.create(this.a.getApplicationContext());
ScriptIntrinsicBlur create2 = ScriptIntrinsicBlur.create(create, Element.U8_4(create));
Allocation createFromBitmap = Allocation.createFromBitmap(create, bitmap);
Allocation createFromBitmap2 = Allocation.createFromBitmap(create, createBitmap);
create2.setRadius(25.0f);
create2.setInput(createFromBitmap);
create2.forEach(createFromBitmap2);
createFromBitmap2.copyTo(createBitmap);
create.destroy();
return createBitmap;
} catch (Throwable unused) {
return null;
}
}
public void setNotchPadding(int i, int i2, int i3, int i4) {
af.b(MBridgeBaseView.TAG, "NOTCH NativeEndCard " + String.format("%1s-%2s-%3s-%4s", Integer.valueOf(i), Integer.valueOf(i2), Integer.valueOf(i3), Integer.valueOf(i4)));
this.L = i;
this.M = i2;
this.N = i3;
this.O = i4;
f();
}
private void f() {
RelativeLayout relativeLayout;
if (!this.e || (relativeLayout = this.D) == null) {
return;
}
relativeLayout.postDelayed(new Runnable() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.3
@Override // java.lang.Runnable
public final void run() {
if (MBridgeNativeEndCardView.this.D != null) {
CampaignEx campaignEx = MBridgeNativeEndCardView.this.b;
if (campaignEx != null && !campaignEx.isDynamicView() && MBridgeNativeEndCardView.this.b.getAdSpaceT() != 2) {
MBridgeNativeEndCardView.this.D.setPadding(MBridgeNativeEndCardView.this.L, MBridgeNativeEndCardView.this.N, MBridgeNativeEndCardView.this.M, MBridgeNativeEndCardView.this.O);
MBridgeNativeEndCardView.this.D.startAnimation(MBridgeNativeEndCardView.this.K);
}
MBridgeNativeEndCardView.this.D.setVisibility(0);
}
if (MBridgeNativeEndCardView.this.Q != null && MBridgeNativeEndCardView.this.Q.getVisibility() != 0 && MBridgeNativeEndCardView.this.G) {
MBridgeNativeEndCardView.this.Q.setVisibility(0);
}
MBridgeNativeEndCardView.p(MBridgeNativeEndCardView.this);
}
}, 200L);
}
public void setMoreOfferCampaignUnit(CampaignUnit campaignUnit) {
MBShakeView mBShakeView;
CampaignEx campaignEx = this.b;
if (campaignEx == null || !campaignEx.isDynamicView()) {
return;
}
this.T = campaignUnit;
if (campaignUnit == null || campaignUnit.getAds() == null || this.T.getAds().size() <= 5 || (mBShakeView = this.U) == null) {
return;
}
mBShakeView.setPadding(0, 0, 0, ak.a(getContext(), 5.0f));
}
public void clearMoreOfferBitmap() {
CampaignUnit campaignUnit;
CampaignEx campaignEx = this.b;
if (campaignEx == null || !campaignEx.isDynamicView() || (campaignUnit = this.T) == null || campaignUnit.getAds() == null || this.T.getAds().size() <= 0) {
return;
}
Iterator<CampaignEx> it = this.T.getAds().iterator();
while (it.hasNext()) {
CampaignEx next = it.next();
if (!TextUtils.isEmpty(next.getIconUrl())) {
com.mbridge.msdk.foundation.same.c.b.a(c.m().c());
next.getIconUrl();
}
}
}
public void release() {
try {
removeAllViews();
AlphaAnimation alphaAnimation = this.K;
if (alphaAnimation != null) {
alphaAnimation.cancel();
}
this.B = null;
} catch (Exception e) {
af.b(MBridgeBaseView.TAG, e.getMessage());
}
}
public void setLayout() {
if (!this.h) {
a();
return;
}
com.mbridge.msdk.video.dynview.c a = new com.mbridge.msdk.video.dynview.j.c().a(getContext(), this.b, this.i, com.mbridge.msdk.e.b.a() ? "cn_" : "en_");
this.ab = a.n();
com.mbridge.msdk.video.dynview.b.a().a(a, new h() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.10
@Override // com.mbridge.msdk.video.dynview.e.h
public final void viewInflaterSuccess(com.mbridge.msdk.video.dynview.a aVar) {
if (aVar != null) {
MBridgeNativeEndCardView.this.addView(aVar.a());
MBridgeNativeEndCardView.this.aa = aVar.c();
if (MBridgeNativeEndCardView.this.ctaViewCanGet(aVar.a(), MBridgeNativeEndCardView.this.aa)) {
MBridgeNativeEndCardView mBridgeNativeEndCardView = MBridgeNativeEndCardView.this;
mBridgeNativeEndCardView.e = mBridgeNativeEndCardView.b(aVar.a());
MBridgeNativeEndCardView.this.b();
} else {
MBridgeNativeEndCardView.this.aa = false;
MBridgeNativeEndCardView mBridgeNativeEndCardView2 = MBridgeNativeEndCardView.this;
mBridgeNativeEndCardView2.h = false;
mBridgeNativeEndCardView2.a();
}
MBridgeNativeEndCardView mBridgeNativeEndCardView3 = MBridgeNativeEndCardView.this;
CampaignEx campaignEx = mBridgeNativeEndCardView3.b;
if (campaignEx != null) {
campaignEx.setECTemplateRenderSucc(mBridgeNativeEndCardView3.aa);
}
}
}
@Override // com.mbridge.msdk.video.dynview.e.h
public final void viewInflaterFail(com.mbridge.msdk.video.dynview.c.a aVar) {
af.b(MBridgeBaseView.TAG, "errorMsg:" + aVar.b());
}
});
}
public void preLoadData(b bVar) {
this.E = bVar;
try {
if (this.b == null || !this.e) {
return;
}
com.mbridge.msdk.foundation.same.c.b.a(this.a.getApplicationContext()).a(this.b.getImageUrl(), new com.mbridge.msdk.foundation.same.c.c() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.11
@Override // com.mbridge.msdk.foundation.same.c.c
public final void onFailedLoad(String str, String str2) {
}
@Override // com.mbridge.msdk.foundation.same.c.c
public final void onSuccessLoad(Bitmap bitmap, String str) {
if (bitmap == null || bitmap.isRecycled()) {
return;
}
try {
if (MBridgeNativeEndCardView.this.q != null) {
MBridgeNativeEndCardView mBridgeNativeEndCardView = MBridgeNativeEndCardView.this;
if (mBridgeNativeEndCardView.h) {
mBridgeNativeEndCardView.q.setBackground(null);
}
MBridgeNativeEndCardView.this.q.setImageBitmap(bitmap);
}
MBridgeNativeEndCardView.a(MBridgeNativeEndCardView.this, bitmap);
} catch (Throwable unused) {
if (MBridgeNativeEndCardView.this.p != null) {
MBridgeNativeEndCardView.this.p.setVisibility(4);
}
}
}
});
com.mbridge.msdk.foundation.same.c.b.a(this.a.getApplicationContext()).a(this.b.getIconUrl(), new j(this.r, ak.a(c.m().c(), 8.0f)));
this.w.setText(this.b.getAppName());
TextView textView = this.ctaView;
if (textView != null) {
textView.setText(this.b.getAdCall());
}
TextView textView2 = this.x;
if (textView2 != null) {
textView2.setText(this.b.getAppDesc());
}
TextView textView3 = this.y;
if (textView3 != null) {
textView3.setText(this.b.getNumberRating() + ")");
}
this.z.removeAllViews();
double rating = this.b.getRating();
if (rating <= 0.0d) {
rating = 5.0d;
}
LinearLayout linearLayout = this.z;
if (linearLayout instanceof StarLevelView) {
((StarLevelView) linearLayout).initScore(rating);
}
LinearLayout linearLayout2 = this.z;
if (linearLayout2 instanceof MBridgeLevelLayoutView) {
((MBridgeLevelLayoutView) linearLayout2).setRatingAndUser(rating, this.b.getNumberRating());
}
LinearLayout linearLayout3 = this.z;
if (linearLayout3 instanceof MBStarLevelLayoutView) {
((MBStarLevelLayoutView) linearLayout3).setRating((int) rating);
}
LinearLayout linearLayout4 = this.A;
if (linearLayout4 != null && (linearLayout4 instanceof MBHeatLevelLayoutView)) {
((MBHeatLevelLayoutView) linearLayout4).setHeatCount(this.b.getNumberRating());
}
if (!TextUtils.isEmpty(this.b.getendcard_url()) && this.b.getendcard_url().contains("alecfc=1")) {
this.F = true;
}
String language = Locale.getDefault().getLanguage();
if (!TextUtils.isEmpty(language) && language.equals("zh")) {
this.s.setImageDrawable(getResources().getDrawable(getResources().getIdentifier("mbridge_reward_flag_cn", "drawable", c.m().g())));
this.ac = "广告";
} else {
this.s.setImageDrawable(getResources().getDrawable(getResources().getIdentifier("mbridge_reward_flag_en", "drawable", c.m().g())));
this.ac = "AD";
}
if (this.ab == 0) {
ImageView imageView = this.s;
if (imageView != null) {
imageView.setVisibility(4);
}
ImageView imageView2 = this.u;
if (imageView2 != null) {
imageView2.setVisibility(4);
}
TextView textView4 = this.t;
if (textView4 != null) {
textView4.setVisibility(0);
this.t.setText(this.ac);
}
}
ak.a(2, this.v, this.b, this.a, true, new com.mbridge.msdk.foundation.d.a() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.12
@Override // com.mbridge.msdk.foundation.d.a
public final void showed() {
MBridgeNativeEndCardView.this.I = true;
}
@Override // com.mbridge.msdk.foundation.d.a
public final void close() {
MBridgeNativeEndCardView.this.I = false;
}
@Override // com.mbridge.msdk.foundation.d.a
public final void summit(String str) {
MBridgeNativeEndCardView.this.I = false;
}
});
if (this.G) {
return;
}
this.Q.setVisibility(8);
} catch (Throwable th) {
af.a(MBridgeBaseView.TAG, th.getMessage());
}
}
public static /* synthetic */ void a(MBridgeNativeEndCardView mBridgeNativeEndCardView, final Bitmap bitmap) {
try {
com.mbridge.msdk.foundation.same.f.a.d().execute(new Runnable() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.13
@Override // java.lang.Runnable
public final void run() {
MBridgeNativeEndCardView mBridgeNativeEndCardView2 = MBridgeNativeEndCardView.this;
mBridgeNativeEndCardView2.P = mBridgeNativeEndCardView2.blurBitmap(bitmap);
if (MBridgeNativeEndCardView.this.P == null || MBridgeNativeEndCardView.this.P.isRecycled() || MBridgeNativeEndCardView.this.p == null) {
return;
}
MBridgeNativeEndCardView.this.p.post(new Runnable() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.13.1
@Override // java.lang.Runnable
public final void run() {
MBridgeNativeEndCardView mBridgeNativeEndCardView3 = MBridgeNativeEndCardView.this;
if (mBridgeNativeEndCardView3.h) {
mBridgeNativeEndCardView3.p.setBackground(null);
}
af.b("async", "执行异步加载图");
MBridgeNativeEndCardView.this.p.setImageBitmap(MBridgeNativeEndCardView.this.P);
}
});
}
});
} catch (Exception e) {
af.a(MBridgeBaseView.TAG, e.getMessage());
}
}
public static /* synthetic */ void a(MBridgeNativeEndCardView mBridgeNativeEndCardView, int i) {
JSONObject jSONObject;
CampaignEx campaignEx = mBridgeNativeEndCardView.b;
if (campaignEx != null && campaignEx.isDynamicView()) {
try {
CampaignEx.c rewardTemplateMode = mBridgeNativeEndCardView.b.getRewardTemplateMode();
String str = "";
if (rewardTemplateMode != null) {
str = rewardTemplateMode.f() + "";
}
i.a(c.m().c(), "end_card_click", mBridgeNativeEndCardView.b.getCampaignUnitId(), mBridgeNativeEndCardView.b.isBidCampaign(), mBridgeNativeEndCardView.b.getRequestId(), mBridgeNativeEndCardView.b.getRequestIdNotice(), mBridgeNativeEndCardView.b.getId(), str);
} catch (Exception e) {
e.printStackTrace();
}
}
JSONObject jSONObject2 = null;
try {
jSONObject = new JSONObject();
try {
jSONObject.put(com.mbridge.msdk.foundation.same.a.j, mBridgeNativeEndCardView.a(i));
if (mBridgeNativeEndCardView.b.getDynamicTempCode() == 5) {
jSONObject.put("camp_position", 0);
}
} catch (JSONException e2) {
e = e2;
jSONObject2 = jSONObject;
e.printStackTrace();
jSONObject = jSONObject2;
mBridgeNativeEndCardView.b.setClickTempSource(2);
mBridgeNativeEndCardView.notifyListener.a(105, jSONObject);
}
} catch (JSONException e3) {
e = e3;
}
mBridgeNativeEndCardView.b.setClickTempSource(2);
mBridgeNativeEndCardView.notifyListener.a(105, jSONObject);
}
public static /* synthetic */ void p(MBridgeNativeEndCardView mBridgeNativeEndCardView) {
CampaignEx campaignEx = mBridgeNativeEndCardView.b;
if (campaignEx != null) {
campaignEx.setCampaignUnitId(mBridgeNativeEndCardView.S);
com.mbridge.msdk.foundation.d.b.a().a(mBridgeNativeEndCardView.S + "_2", mBridgeNativeEndCardView.b);
}
if (com.mbridge.msdk.foundation.d.b.a().b()) {
com.mbridge.msdk.foundation.d.b.a().a(mBridgeNativeEndCardView.S + "_2", new com.mbridge.msdk.foundation.d.a() { // from class: com.mbridge.msdk.video.module.MBridgeNativeEndCardView.4
@Override // com.mbridge.msdk.foundation.d.a
public final void showed() {
MBridgeNativeEndCardView.this.I = true;
}
@Override // com.mbridge.msdk.foundation.d.a
public final void close() {
MBridgeNativeEndCardView.this.I = false;
}
@Override // com.mbridge.msdk.foundation.d.a
public final void summit(String str) {
MBridgeNativeEndCardView.this.I = false;
}
});
com.mbridge.msdk.foundation.d.b.a().c(mBridgeNativeEndCardView.S + "_1");
if (mBridgeNativeEndCardView.R != null) {
com.mbridge.msdk.foundation.d.b.a().a(mBridgeNativeEndCardView.S + "_2", mBridgeNativeEndCardView.R);
return;
}
return;
}
FeedBackButton feedBackButton = mBridgeNativeEndCardView.R;
if (feedBackButton != null) {
feedBackButton.setVisibility(8);
}
}
}

View File

@@ -0,0 +1,46 @@
package com.mbridge.msdk.video.module;
import android.content.Context;
import android.util.AttributeSet;
import android.view.View;
import android.widget.TextView;
import com.mbridge.msdk.MBridgeConstans;
/* loaded from: classes4.dex */
public abstract class MBridgeNativeEndCardViewDiff extends MBridgeBaseView {
public TextView ctaView;
public boolean checkChinaShakeState() {
return false;
}
public boolean checkProgressBarIntercepted() {
return false;
}
public MBridgeNativeEndCardViewDiff(Context context) {
super(context);
}
public MBridgeNativeEndCardViewDiff(Context context, AttributeSet attributeSet, boolean z, int i, boolean z2, int i2, int i3) {
super(context, attributeSet, z, i, z2, i2, i3);
}
public MBridgeNativeEndCardViewDiff(Context context, AttributeSet attributeSet) {
super(context, attributeSet);
}
public boolean ctaViewCanGet(View view, boolean z) {
try {
View findViewById = view.findViewById(filterFindViewId(z, "mbridge_tv_cta"));
if (findViewById instanceof TextView) {
this.ctaView = (TextView) findViewById;
}
} catch (Exception e) {
if (MBridgeConstans.DEBUG) {
e.printStackTrace();
}
}
return this.ctaView != null;
}
}

View File

@@ -0,0 +1,37 @@
package com.mbridge.msdk.video.module;
import android.content.Context;
import android.util.AttributeSet;
import com.mbridge.msdk.video.signal.factory.b;
/* loaded from: classes4.dex */
public class MBridgePlayableView extends MBridgeH5EndCardView {
public MBridgePlayableView(Context context) {
super(context);
}
public MBridgePlayableView(Context context, AttributeSet attributeSet) {
super(context, attributeSet);
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView, com.mbridge.msdk.video.module.MBridgeBaseView
public void init(Context context) {
super.init(context);
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
public final String a() {
return super.a();
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
public void preLoadData(b bVar) {
super.preLoadData(bVar);
super.setLoadPlayable(true);
}
@Override // com.mbridge.msdk.video.module.MBridgeH5EndCardView
public void onBackPress() {
super.onBackPress();
}
}

View File

@@ -0,0 +1,71 @@
package com.mbridge.msdk.video.module;
import android.content.Context;
import android.util.AttributeSet;
import android.view.View;
import android.view.ViewGroup;
import android.widget.RelativeLayout;
import com.mbridge.msdk.video.signal.factory.b;
import com.mbridge.msdk.widget.a;
/* loaded from: classes4.dex */
public class MBridgeVastEndCardView extends MBridgeBaseView {
private ViewGroup m;
private View n;
private View o;
public void preLoadData(b bVar) {
}
public MBridgeVastEndCardView(Context context) {
super(context);
}
public MBridgeVastEndCardView(Context context, AttributeSet attributeSet) {
super(context, attributeSet);
}
@Override // com.mbridge.msdk.video.module.MBridgeBaseView
public void init(Context context) {
int findLayout = findLayout("mbridge_reward_endcard_vast");
if (findLayout >= 0) {
this.c.inflate(findLayout, this);
this.m = (ViewGroup) findViewById(findID("mbridge_rl_content"));
this.n = findViewById(findID("mbridge_iv_vastclose"));
View findViewById = findViewById(findID("mbridge_iv_vastok"));
this.o = findViewById;
this.e = isNotNULL(this.m, this.n, findViewById);
c();
if (this.e) {
setMatchParent();
setBackgroundResource(findColor("mbridge_reward_endcard_vast_bg"));
setClickable(true);
((RelativeLayout.LayoutParams) this.m.getLayoutParams()).addRule(13, -1);
}
}
}
@Override // com.mbridge.msdk.video.module.MBridgeBaseView
public final void c() {
super.c();
if (this.e) {
this.n.setOnClickListener(new View.OnClickListener() { // from class: com.mbridge.msdk.video.module.MBridgeVastEndCardView.1
@Override // android.view.View.OnClickListener
public final void onClick(View view) {
MBridgeVastEndCardView.this.notifyListener.a(104, "");
}
});
this.o.setOnClickListener(new a() { // from class: com.mbridge.msdk.video.module.MBridgeVastEndCardView.2
@Override // com.mbridge.msdk.widget.a
public final void onNoDoubleClick(View view) {
MBridgeVastEndCardView mBridgeVastEndCardView = MBridgeVastEndCardView.this;
mBridgeVastEndCardView.notifyListener.a(108, mBridgeVastEndCardView.d());
}
});
}
}
public void notifyShowListener() {
this.notifyListener.a(111, "");
}
}

View File

@@ -0,0 +1,196 @@
package com.mbridge.msdk.video.module;
import android.content.Context;
import android.content.res.Configuration;
import android.text.TextUtils;
import android.util.AttributeSet;
import android.view.MotionEvent;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ImageView;
import android.widget.TextView;
import com.mbridge.msdk.foundation.controller.c;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.same.a;
import com.mbridge.msdk.foundation.tools.af;
import com.mbridge.msdk.foundation.tools.ak;
import com.mbridge.msdk.video.module.a.a.j;
import com.mbridge.msdk.video.signal.factory.b;
import org.json.JSONException;
import org.json.JSONObject;
/* loaded from: classes4.dex */
public class MBridgeVideoEndCoverView extends MBridgeBaseView {
private final String m;
private View n;
private ImageView o;
private ImageView p;
private TextView q;
private TextView r;
private TextView s;
private b t;
public MBridgeVideoEndCoverView(Context context) {
super(context);
this.m = "MBridgeVideoEndCoverView";
}
public MBridgeVideoEndCoverView(Context context, AttributeSet attributeSet) {
super(context, attributeSet);
this.m = "MBridgeVideoEndCoverView";
}
@Override // com.mbridge.msdk.video.module.MBridgeBaseView
public void init(Context context) {
int findLayout = findLayout("mbridge_reward_videoend_cover");
if (findLayout >= 0) {
View inflate = this.c.inflate(findLayout, (ViewGroup) null);
this.n = inflate;
if (inflate != null) {
this.e = a(inflate);
addView(this.n, -1, -1);
c();
}
}
}
@Override // com.mbridge.msdk.video.module.MBridgeBaseView, android.view.ViewGroup
public boolean onInterceptTouchEvent(MotionEvent motionEvent) {
this.f = motionEvent.getRawX();
this.g = motionEvent.getRawY();
return super.onInterceptTouchEvent(motionEvent);
}
@Override // com.mbridge.msdk.video.module.MBridgeBaseView
public void onSelfConfigurationChanged(Configuration configuration) {
super.onSelfConfigurationChanged(configuration);
this.d = configuration.orientation;
removeView(this.n);
View view = this.n;
if (view == null) {
init(this.a);
preLoadData(this.t);
return;
}
if (view.getParent() != null) {
((ViewGroup) this.n.getParent()).removeView(this.n);
}
addView(this.n);
a(this.n);
c();
}
private boolean a(View view) {
if (view == null) {
return true;
}
try {
this.o = (ImageView) view.findViewById(findID("mbridge_vec_iv_icon"));
this.p = (ImageView) view.findViewById(findID("mbridge_vec_iv_close"));
this.q = (TextView) view.findViewById(findID("mbridge_vec_tv_title"));
this.r = (TextView) view.findViewById(findID("mbridge_vec_tv_desc"));
this.s = (TextView) view.findViewById(findID("mbridge_vec_btn"));
return true;
} catch (Throwable th) {
af.b("MBridgeVideoEndCoverView", th.getMessage());
return false;
}
}
@Override // com.mbridge.msdk.video.module.MBridgeBaseView
public final void c() {
super.c();
this.p.setOnClickListener(new View.OnClickListener() { // from class: com.mbridge.msdk.video.module.MBridgeVideoEndCoverView.1
@Override // android.view.View.OnClickListener
public final void onClick(View view) {
MBridgeVideoEndCoverView.this.notifyListener.a(104, "");
}
});
this.o.setOnClickListener(new View.OnClickListener() { // from class: com.mbridge.msdk.video.module.MBridgeVideoEndCoverView.2
@Override // android.view.View.OnClickListener
public final void onClick(View view) {
MBridgeVideoEndCoverView.this.a();
}
});
this.s.setOnClickListener(new View.OnClickListener() { // from class: com.mbridge.msdk.video.module.MBridgeVideoEndCoverView.3
@Override // android.view.View.OnClickListener
public final void onClick(View view) {
MBridgeVideoEndCoverView.this.a();
}
});
}
public final void a() {
JSONObject jSONObject;
JSONException e;
JSONObject jSONObject2;
JSONException e2;
try {
JSONObject jSONObject3 = new JSONObject();
try {
jSONObject2 = new JSONObject();
try {
jSONObject2.put(a.h, ak.b(c.m().c(), this.f));
jSONObject2.put(a.i, ak.b(c.m().c(), this.g));
jSONObject2.put(a.m, 0);
try {
this.d = getContext().getResources().getConfiguration().orientation;
} catch (Exception e3) {
e3.printStackTrace();
}
jSONObject2.put(a.k, this.d);
jSONObject2.put(a.l, ak.d(getContext()));
} catch (JSONException e4) {
e2 = e4;
af.b("MBridgeVideoEndCoverView", e2.getMessage());
jSONObject = new JSONObject();
jSONObject.put(a.j, jSONObject2);
this.notifyListener.a(105, jSONObject);
}
} catch (JSONException e5) {
jSONObject2 = jSONObject3;
e2 = e5;
}
jSONObject = new JSONObject();
try {
jSONObject.put(a.j, jSONObject2);
} catch (JSONException e6) {
e = e6;
e.printStackTrace();
this.notifyListener.a(105, jSONObject);
}
} catch (JSONException e7) {
jSONObject = null;
e = e7;
}
this.notifyListener.a(105, jSONObject);
}
public void preLoadData(b bVar) {
ImageView imageView;
this.t = bVar;
try {
CampaignEx campaignEx = this.b;
if (campaignEx == null || !this.e || campaignEx == null) {
return;
}
if (!TextUtils.isEmpty(campaignEx.getIconUrl()) && (imageView = this.o) != null) {
com.mbridge.msdk.foundation.same.c.b.a(this.a.getApplicationContext()).a(this.b.getIconUrl(), new j(imageView, ak.a(c.m().c(), 8.0f)));
}
TextView textView = this.q;
if (textView != null) {
textView.setText(this.b.getAppName());
}
TextView textView2 = this.s;
if (textView2 != null) {
textView2.setText(this.b.getAdCall());
}
TextView textView3 = this.r;
if (textView3 != null) {
textView3.setText(this.b.getAppDesc());
}
} catch (Throwable th) {
af.a("MBridgeVideoEndCoverView", th.getMessage());
}
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,6 @@
package com.mbridge.msdk.video.module.a;
/* loaded from: classes4.dex */
public interface a {
void a(int i, Object obj);
}

View File

@@ -0,0 +1,39 @@
package com.mbridge.msdk.video.module.a.a;
import android.app.Activity;
import android.content.Intent;
import android.net.Uri;
import android.text.TextUtils;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.tools.af;
/* loaded from: classes4.dex */
public class a extends f {
private Activity a;
private CampaignEx b;
public a(Activity activity, CampaignEx campaignEx) {
this.a = activity;
this.b = campaignEx;
}
@Override // com.mbridge.msdk.video.module.a.a.f, com.mbridge.msdk.video.module.a.a
public void a(int i, Object obj) {
super.a(i, obj);
if (i != 106 || this.a == null || this.b == null) {
return;
}
try {
Intent intent = new Intent();
intent.setAction("android.intent.action.VIEW");
String a = com.mbridge.msdk.click.c.a(this.b.getClickURL(), "-999", "-999");
if (!TextUtils.isEmpty(a)) {
intent.setData(Uri.parse(a));
this.a.startActivity(intent);
}
} catch (Throwable th) {
af.b("NotifyListener", th.getMessage(), th);
}
this.a.finish();
}
}

View File

@@ -0,0 +1,57 @@
package com.mbridge.msdk.video.module.a.a;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.video.module.MBridgeContainerView;
import com.mbridge.msdk.video.module.MBridgeVideoView;
/* loaded from: classes4.dex */
public final class b extends d {
private MBridgeVideoView k;
private MBridgeContainerView l;
public b(MBridgeVideoView mBridgeVideoView, MBridgeContainerView mBridgeContainerView, CampaignEx campaignEx, com.mbridge.msdk.videocommon.b.c cVar, com.mbridge.msdk.videocommon.download.a aVar, String str, String str2, com.mbridge.msdk.video.module.a.a aVar2, int i, boolean z) {
super(campaignEx, aVar, cVar, str, str2, aVar2, i, z);
this.k = mBridgeVideoView;
this.l = mBridgeContainerView;
if (mBridgeVideoView == null || mBridgeContainerView == null) {
this.a = false;
}
}
@Override // com.mbridge.msdk.video.module.a.a.d, com.mbridge.msdk.video.module.a.a.k, com.mbridge.msdk.video.module.a.a.f, com.mbridge.msdk.video.module.a.a
public final void a(int i, Object obj) {
if (this.a) {
if (i == 8) {
MBridgeContainerView mBridgeContainerView = this.l;
if (mBridgeContainerView == null) {
MBridgeVideoView mBridgeVideoView = this.k;
if (mBridgeVideoView != null) {
mBridgeVideoView.showAlertView();
}
} else if (mBridgeContainerView.showAlertWebView()) {
MBridgeVideoView mBridgeVideoView2 = this.k;
if (mBridgeVideoView2 != null) {
mBridgeVideoView2.alertWebViewShowed();
}
} else {
MBridgeVideoView mBridgeVideoView3 = this.k;
if (mBridgeVideoView3 != null) {
mBridgeVideoView3.showAlertView();
}
}
} else if (i == 107) {
this.l.showVideoClickView(-1);
this.k.setCover(false);
this.k.setMiniEndCardState(false);
this.k.videoOperate(1);
} else if (i == 112) {
this.k.setCover(true);
this.k.setMiniEndCardState(true);
this.k.videoOperate(2);
} else if (i == 115) {
this.l.resizeMiniCard(this.k.getBorderViewWidth(), this.k.getBorderViewHeight(), this.k.getBorderViewRadius());
}
}
super.a(i, obj);
}
}

View File

@@ -0,0 +1,46 @@
package com.mbridge.msdk.video.module.a.a;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.video.signal.factory.IJSFactory;
/* loaded from: classes4.dex */
public final class c extends d {
private IJSFactory k;
public c(IJSFactory iJSFactory, CampaignEx campaignEx, com.mbridge.msdk.videocommon.b.c cVar, com.mbridge.msdk.videocommon.download.a aVar, String str, String str2, com.mbridge.msdk.video.module.a.a aVar2, int i, boolean z) {
super(campaignEx, aVar, cVar, str, str2, aVar2, i, z);
this.k = iJSFactory;
if (iJSFactory == null) {
this.a = false;
}
}
@Override // com.mbridge.msdk.video.module.a.a.d, com.mbridge.msdk.video.module.a.a.k, com.mbridge.msdk.video.module.a.a.f, com.mbridge.msdk.video.module.a.a
public final void a(int i, Object obj) {
if (this.a) {
if (i != 8) {
if (i == 105) {
this.k.getJSNotifyProxy().a(3, obj.toString());
i = -1;
} else if (i == 107) {
this.k.getJSContainerModule().showVideoClickView(-1);
this.k.getJSVideoModule().setCover(false);
this.k.getJSVideoModule().setMiniEndCardState(false);
this.k.getJSVideoModule().videoOperate(1);
} else if (i == 112) {
this.k.getJSVideoModule().setCover(true);
this.k.getJSVideoModule().setMiniEndCardState(true);
this.k.getJSVideoModule().videoOperate(2);
} else if (i == 115) {
com.mbridge.msdk.video.signal.j jSVideoModule = this.k.getJSVideoModule();
this.k.getJSContainerModule().resizeMiniCard(jSVideoModule.getBorderViewWidth(), jSVideoModule.getBorderViewHeight(), jSVideoModule.getBorderViewRadius());
}
} else if (!this.k.getJSContainerModule().showAlertWebView()) {
this.k.getJSVideoModule().showAlertView();
} else {
this.k.getJSVideoModule().alertWebViewShowed();
}
}
super.a(i, obj);
}
}

View File

@@ -0,0 +1,58 @@
package com.mbridge.msdk.video.module.a.a;
import android.net.Uri;
import android.text.TextUtils;
import com.ironsource.v8;
import com.mbridge.msdk.foundation.entity.CampaignEx;
/* loaded from: classes4.dex */
public class d extends k {
public d(CampaignEx campaignEx, com.mbridge.msdk.videocommon.download.a aVar, com.mbridge.msdk.videocommon.b.c cVar, String str, String str2, com.mbridge.msdk.video.module.a.a aVar2, int i, boolean z) {
super(campaignEx, aVar, cVar, str, str2, aVar2, i, z);
}
@Override // com.mbridge.msdk.video.module.a.a.k, com.mbridge.msdk.video.module.a.a.f, com.mbridge.msdk.video.module.a.a
public void a(int i, Object obj) {
super.a(i, obj);
if (this.a) {
try {
CampaignEx campaignEx = this.b;
if (campaignEx != null && campaignEx.getDynamicTempCode() == 5) {
b(obj.toString());
}
} catch (Exception unused) {
}
if (i != 105 && i != 106 && i != 113) {
if (i != 122) {
switch (i) {
case 109:
b(2);
a(2);
break;
case 110:
b(1);
a(1);
break;
case 111:
a(1);
break;
}
}
a();
return;
}
com.mbridge.msdk.video.module.b.b.d(com.mbridge.msdk.foundation.controller.c.m().c(), this.b);
if (i != 105) {
String noticeUrl = this.b.getNoticeUrl();
if (!TextUtils.isEmpty(noticeUrl)) {
if (!noticeUrl.contains(com.mbridge.msdk.foundation.same.a.m)) {
noticeUrl = noticeUrl + v8.i.c + com.mbridge.msdk.foundation.same.a.m + "=2";
} else {
noticeUrl = noticeUrl.replace(com.mbridge.msdk.foundation.same.a.m + v8.i.b + Uri.parse(noticeUrl).getQueryParameter(com.mbridge.msdk.foundation.same.a.m), com.mbridge.msdk.foundation.same.a.m + "=2");
}
}
com.mbridge.msdk.click.a.a(com.mbridge.msdk.foundation.controller.c.m().c(), this.b, this.g, noticeUrl, true, false, com.mbridge.msdk.click.a.a.i);
}
}
}
}

View File

@@ -0,0 +1,75 @@
package com.mbridge.msdk.video.module.a.a;
import android.graphics.Bitmap;
import android.widget.ImageView;
import com.mbridge.msdk.MBridgeConstans;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.tools.ab;
import com.mbridge.msdk.foundation.tools.af;
/* loaded from: classes4.dex */
public class e implements com.mbridge.msdk.foundation.same.c.c {
private CampaignEx a;
protected ImageView b;
private String c;
public e(ImageView imageView) {
this.b = imageView;
}
public e(ImageView imageView, CampaignEx campaignEx, String str) {
this.b = imageView;
this.a = campaignEx;
this.c = str;
}
@Override // com.mbridge.msdk.foundation.same.c.c
public void onSuccessLoad(Bitmap bitmap, String str) {
try {
if (bitmap == null) {
af.b("ImageLoaderListener", "bitmap=null");
} else {
if (this.b == null || bitmap.isRecycled()) {
return;
}
this.b.setImageBitmap(bitmap);
this.b.setVisibility(0);
}
} catch (Throwable th) {
if (MBridgeConstans.DEBUG) {
th.printStackTrace();
}
}
}
@Override // com.mbridge.msdk.foundation.same.c.c
public void onFailedLoad(final String str, String str2) {
Runnable runnable = new Runnable() { // from class: com.mbridge.msdk.video.module.a.a.e.1
@Override // java.lang.Runnable
public final void run() {
try {
com.mbridge.msdk.foundation.db.o a = com.mbridge.msdk.foundation.db.o.a(com.mbridge.msdk.foundation.db.g.a(com.mbridge.msdk.foundation.controller.c.m().c()));
if (e.this.a == null) {
af.a("ImageLoaderListener", "campaign is null");
return;
}
com.mbridge.msdk.foundation.entity.n nVar = new com.mbridge.msdk.foundation.entity.n();
nVar.a("2000044");
nVar.a(ab.m(com.mbridge.msdk.foundation.controller.c.m().c()));
nVar.e(e.this.a.getId());
nVar.p(e.this.a.getImageUrl());
nVar.f(e.this.a.getRequestId());
nVar.g(e.this.a.getRequestIdNotice());
nVar.c(e.this.c);
nVar.h(str);
a.a(nVar);
} catch (Exception e) {
e.printStackTrace();
}
}
};
com.mbridge.msdk.foundation.controller.d.a();
com.mbridge.msdk.foundation.same.f.a.b().execute(runnable);
af.b("ImageLoaderListener", "desc:" + str);
}
}

View File

@@ -0,0 +1,11 @@
package com.mbridge.msdk.video.module.a.a;
import com.mbridge.msdk.foundation.tools.af;
/* loaded from: classes4.dex */
public class f implements com.mbridge.msdk.video.module.a.a {
@Override // com.mbridge.msdk.video.module.a.a
public void a(int i, Object obj) {
af.b("NotifyListener", "onNotify,type=" + i + ",pt=" + obj);
}
}

View File

@@ -0,0 +1,43 @@
package com.mbridge.msdk.video.module.a.a;
import androidx.annotation.RequiresApi;
import com.mbridge.msdk.video.module.MBridgeClickMiniCardView;
import com.vungle.ads.internal.signals.SignalKey;
/* loaded from: classes4.dex */
public final class g extends i {
private MBridgeClickMiniCardView a;
public g(MBridgeClickMiniCardView mBridgeClickMiniCardView, com.mbridge.msdk.video.module.a.a aVar) {
super(aVar);
this.a = mBridgeClickMiniCardView;
}
@Override // com.mbridge.msdk.video.module.a.a.i, com.mbridge.msdk.video.module.a.a.f, com.mbridge.msdk.video.module.a.a
@RequiresApi(api = 11)
public final void a(int i, Object obj) {
boolean z = false;
switch (i) {
case 100:
MBridgeClickMiniCardView mBridgeClickMiniCardView = this.a;
if (mBridgeClickMiniCardView != null) {
mBridgeClickMiniCardView.webviewshow();
MBridgeClickMiniCardView mBridgeClickMiniCardView2 = this.a;
mBridgeClickMiniCardView2.onSelfConfigurationChanged(mBridgeClickMiniCardView2.getResources().getConfiguration());
break;
}
break;
case 101:
case 102:
z = true;
break;
case 103:
i = SignalKey.EVENT_ID;
break;
}
if (z) {
return;
}
super.a(i, obj);
}
}

View File

@@ -0,0 +1,46 @@
package com.mbridge.msdk.video.module.a.a;
import com.mbridge.msdk.foundation.entity.CampaignEx;
/* loaded from: classes4.dex */
public final class h extends k {
public h(CampaignEx campaignEx, com.mbridge.msdk.videocommon.download.a aVar, com.mbridge.msdk.videocommon.b.c cVar, String str, String str2, com.mbridge.msdk.video.module.a.a aVar2, int i, boolean z) {
super(campaignEx, aVar, cVar, str, str2, aVar2, i, z);
}
@Override // com.mbridge.msdk.video.module.a.a.k, com.mbridge.msdk.video.module.a.a.f, com.mbridge.msdk.video.module.a.a
public final void a(int i, Object obj) {
if (i == 100) {
g();
f();
e();
a(2);
} else if (i == 109) {
b(2);
} else if (i == 122) {
a();
} else if (i != 129) {
String str = "";
if (i == 118) {
if (obj != null && (obj instanceof String)) {
str = (String) obj;
}
a(3, str);
} else if (i == 119) {
if (obj != null && (obj instanceof String)) {
str = (String) obj;
}
a(4, str);
}
} else {
CampaignEx campaignEx = this.b;
if (campaignEx != null && campaignEx.getPlayable_ads_without_video() == 2) {
g();
f();
e();
a(1);
}
}
super.a(i, obj);
}
}

View File

@@ -0,0 +1,19 @@
package com.mbridge.msdk.video.module.a.a;
/* loaded from: classes4.dex */
public class i extends f {
protected com.mbridge.msdk.video.module.a.a b;
public i(com.mbridge.msdk.video.module.a.a aVar) {
this.b = aVar;
}
@Override // com.mbridge.msdk.video.module.a.a.f, com.mbridge.msdk.video.module.a.a
public void a(int i, Object obj) {
super.a(i, obj);
com.mbridge.msdk.video.module.a.a aVar = this.b;
if (aVar != null) {
aVar.a(i, obj);
}
}
}

View File

@@ -0,0 +1,34 @@
package com.mbridge.msdk.video.module.a.a;
import android.graphics.Bitmap;
import android.widget.ImageView;
import com.mbridge.msdk.MBridgeConstans;
import com.mbridge.msdk.foundation.tools.ae;
/* loaded from: classes4.dex */
public final class j extends e {
private int a;
public j(ImageView imageView, int i) {
super(imageView);
this.a = i;
}
@Override // com.mbridge.msdk.video.module.a.a.e, com.mbridge.msdk.foundation.same.c.c
public final void onSuccessLoad(Bitmap bitmap, String str) {
Bitmap a;
if (bitmap == null) {
return;
}
try {
if (this.b == null || bitmap.isRecycled() || (a = ae.a(bitmap, 1, this.a)) == null) {
return;
}
this.b.setImageBitmap(a);
} catch (Throwable th) {
if (MBridgeConstans.DEBUG) {
th.printStackTrace();
}
}
}
}

View File

@@ -0,0 +1,347 @@
package com.mbridge.msdk.video.module.a.a;
import android.content.Context;
import android.text.TextUtils;
import com.mbridge.msdk.MBridgeConstans;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.tools.ab;
import com.mbridge.msdk.foundation.tools.af;
import com.mbridge.msdk.foundation.tools.ap;
import java.util.HashMap;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import org.json.JSONObject;
/* loaded from: classes4.dex */
public class k extends f {
protected boolean a;
protected CampaignEx b;
protected List<CampaignEx> c;
protected boolean d;
protected com.mbridge.msdk.videocommon.download.a e;
protected com.mbridge.msdk.videocommon.b.c f;
protected String g;
protected String h;
protected com.mbridge.msdk.video.module.a.a i;
protected int j;
private boolean k = false;
private boolean l = false;
private boolean m = false;
public final void a(CampaignEx campaignEx) {
this.b = campaignEx;
}
public final void a(List<CampaignEx> list) {
this.c = list;
}
public k(CampaignEx campaignEx, com.mbridge.msdk.videocommon.download.a aVar, com.mbridge.msdk.videocommon.b.c cVar, String str, String str2, com.mbridge.msdk.video.module.a.a aVar2, int i, boolean z) {
this.d = false;
this.i = new f();
this.j = 1;
if (!z && campaignEx != null && ap.b(str2) && aVar != null && aVar2 != null) {
this.b = campaignEx;
this.h = str;
this.g = str2;
this.e = aVar;
this.f = cVar;
this.i = aVar2;
this.a = true;
this.j = i;
this.d = false;
return;
}
if (!z || campaignEx == null || !ap.b(str2) || aVar2 == null) {
return;
}
this.b = campaignEx;
this.h = str;
this.g = str2;
this.e = aVar;
this.f = cVar;
this.i = aVar2;
this.a = true;
this.j = i;
this.d = true;
}
@Override // com.mbridge.msdk.video.module.a.a.f, com.mbridge.msdk.video.module.a.a
public void a(int i, Object obj) {
super.a(i, obj);
this.i.a(i, obj);
}
public final void a(int i) {
if (this.b != null) {
if (i == 1 || i == 2) {
com.mbridge.msdk.video.module.b.b.a(com.mbridge.msdk.foundation.controller.c.m().c(), this.b, i, this.j);
}
}
}
public final void a() {
if (!this.a || this.b == null) {
return;
}
com.mbridge.msdk.foundation.entity.n nVar = new com.mbridge.msdk.foundation.entity.n("2000061", this.b.getId(), this.b.getRequestId(), this.b.getRequestIdNotice(), this.g, ab.m(com.mbridge.msdk.foundation.controller.c.m().c()));
nVar.d(this.b.isMraid() ? com.mbridge.msdk.foundation.entity.n.a : com.mbridge.msdk.foundation.entity.n.b);
com.mbridge.msdk.foundation.same.report.g.b(nVar, com.mbridge.msdk.foundation.controller.c.m().c(), this.g);
}
public final void a(int i, String str) {
if (this.b != null) {
com.mbridge.msdk.foundation.same.report.g.c(new com.mbridge.msdk.foundation.entity.n("2000062", this.b.getId(), this.b.getRequestId(), this.b.getRequestIdNotice(), this.g, ab.m(com.mbridge.msdk.foundation.controller.c.m().c()), i, str), com.mbridge.msdk.foundation.controller.c.m().c(), this.g);
}
}
public final void b(int i) {
CampaignEx campaignEx = this.b;
if (campaignEx != null) {
String noticeUrl = campaignEx.getNoticeUrl();
if (TextUtils.isEmpty(noticeUrl)) {
return;
}
if (i == 1 || i == 2) {
if (!noticeUrl.contains("endscreen_type")) {
StringBuilder sb = new StringBuilder(noticeUrl);
if (noticeUrl.contains("?")) {
sb.append("&endscreen_type=");
sb.append(i);
} else {
sb.append("?endscreen_type=");
sb.append(i);
}
noticeUrl = sb.toString();
} else if (i == 2) {
if (noticeUrl.contains("endscreen_type=1")) {
noticeUrl = noticeUrl.replace("endscreen_type=1", "endscreen_type=2");
}
} else if (noticeUrl.contains("endscreen_type=2")) {
noticeUrl = noticeUrl.replace("endscreen_type=2", "endscreen_type=1");
}
this.b.setNoticeUrl(noticeUrl);
}
}
}
public final void b() {
Runnable runnable = new Runnable() { // from class: com.mbridge.msdk.video.module.a.a.k.1
@Override // java.lang.Runnable
public final void run() {
try {
k kVar = k.this;
if (!kVar.a || kVar.b == null || !ap.b(kVar.g) || com.mbridge.msdk.foundation.controller.c.m().c() == null) {
return;
}
com.mbridge.msdk.foundation.db.i a = com.mbridge.msdk.foundation.db.i.a(com.mbridge.msdk.foundation.db.g.a(com.mbridge.msdk.foundation.controller.c.m().c()));
com.mbridge.msdk.foundation.entity.f fVar = new com.mbridge.msdk.foundation.entity.f();
fVar.a(System.currentTimeMillis());
fVar.b(k.this.g);
fVar.a(k.this.b.getId());
a.a(fVar);
} catch (Throwable th) {
af.b("NotifyListener", th.getMessage(), th);
}
}
};
com.mbridge.msdk.foundation.controller.d.a();
com.mbridge.msdk.foundation.same.f.a.b().execute(runnable);
}
public final void c() {
try {
Runnable runnable = new Runnable() { // from class: com.mbridge.msdk.video.module.a.a.k.2
@Override // java.lang.Runnable
public final void run() {
try {
k kVar = k.this;
if (kVar.a && kVar.b != null && ap.b(kVar.g)) {
com.mbridge.msdk.videocommon.a.a a = com.mbridge.msdk.videocommon.a.a.a();
k kVar2 = k.this;
a.a(kVar2.b, kVar2.g);
}
} catch (Exception e) {
if (MBridgeConstans.DEBUG) {
e.printStackTrace();
}
}
try {
com.mbridge.msdk.videocommon.a.a a2 = com.mbridge.msdk.videocommon.a.a.a();
k kVar3 = k.this;
a2.c(kVar3.h, kVar3.b.getAdType());
} catch (Exception e2) {
if (MBridgeConstans.DEBUG) {
e2.printStackTrace();
}
} catch (Throwable th) {
af.a("NotifyListener", th.getMessage());
}
}
};
com.mbridge.msdk.foundation.controller.d.a();
com.mbridge.msdk.foundation.same.f.a.b().execute(runnable);
} catch (Throwable th) {
af.b("NotifyListener", th.getMessage(), th);
}
}
public final void d() {
com.mbridge.msdk.videocommon.download.a aVar = this.e;
if (aVar != null) {
aVar.f(true);
}
}
public final void e() {
CampaignEx campaignEx;
Map<String, Long> map;
String str;
try {
CampaignEx campaignEx2 = this.b;
if (campaignEx2 != null && campaignEx2.isDynamicView() && this.d && !this.b.isCampaignIsFiltered()) {
this.l = true;
return;
}
if (!this.a || (campaignEx = this.b) == null || TextUtils.isEmpty(campaignEx.getOnlyImpressionURL()) || (map = com.mbridge.msdk.foundation.same.a.b.k) == null || map.containsKey(this.b.getOnlyImpressionURL()) || this.l) {
return;
}
com.mbridge.msdk.foundation.same.a.b.k.put(this.b.getOnlyImpressionURL(), Long.valueOf(System.currentTimeMillis()));
String onlyImpressionURL = this.b.getOnlyImpressionURL();
if (this.b.getSpareOfferFlag() == 1) {
str = onlyImpressionURL + "&to=1&cbt=" + this.b.getCbt() + "&tmorl=" + this.j;
} else {
str = onlyImpressionURL + "&to=0&cbt=" + this.b.getCbt() + "&tmorl=" + this.j;
}
String str2 = str;
if (!this.d || this.b.isCampaignIsFiltered()) {
com.mbridge.msdk.click.a.a(com.mbridge.msdk.foundation.controller.c.m().c(), this.b, this.g, str2, false, true, com.mbridge.msdk.click.a.a.h);
c();
}
this.l = true;
} catch (Exception e) {
e.printStackTrace();
}
}
public final void f() {
try {
if (!this.a || this.k || TextUtils.isEmpty(this.b.getImpressionURL())) {
return;
}
this.k = true;
if (this.b.isBidCampaign() && this.b != null) {
try {
HashMap hashMap = new HashMap();
List<com.mbridge.msdk.foundation.entity.d> a = com.mbridge.msdk.foundation.db.b.a(com.mbridge.msdk.foundation.controller.c.m().c()).a(this.b.getCampaignUnitId(), this.b.getRequestId());
if (a != null && a.size() > 0 && a.get(0) != null) {
if (a.get(0).c() == 1) {
hashMap.put("encrypt_p=", "encrypt_p=" + a.get(0).b());
hashMap.put("irlfa=", "irlfa=1");
for (Map.Entry entry : hashMap.entrySet()) {
String str = (String) entry.getKey();
String str2 = (String) entry.getValue();
CampaignEx campaignEx = this.b;
campaignEx.setImpressionURL(campaignEx.getImpressionURL().replaceAll(str, str2));
CampaignEx campaignEx2 = this.b;
campaignEx2.setOnlyImpressionURL(campaignEx2.getOnlyImpressionURL().replaceAll(str, str2));
}
}
af.a("BidReplaceCampignDao", "removeReplace count " + com.mbridge.msdk.foundation.db.b.a(com.mbridge.msdk.foundation.controller.c.m().c()).a(this.b.getRequestId()));
}
} catch (Exception e) {
e.printStackTrace();
}
}
String impressionURL = this.b.getImpressionURL();
com.mbridge.msdk.click.a.a(com.mbridge.msdk.foundation.controller.c.m().c(), this.b, this.g, this.b.getSpareOfferFlag() == 1 ? impressionURL + "&to=1&cbt=" + this.b.getCbt() + "&tmorl=" + this.j : impressionURL + "&to=0&cbt=" + this.b.getCbt() + "&tmorl=" + this.j, false, true, com.mbridge.msdk.click.a.a.g);
com.mbridge.msdk.video.module.b.b.a(com.mbridge.msdk.foundation.controller.c.m().c(), this.b);
new Thread(new Runnable() { // from class: com.mbridge.msdk.video.module.a.a.k.3
@Override // java.lang.Runnable
public final void run() {
try {
com.mbridge.msdk.foundation.db.j.a(com.mbridge.msdk.foundation.db.g.a(com.mbridge.msdk.foundation.controller.c.m().c())).a(k.this.b.getId());
} catch (Throwable th) {
af.b("NotifyListener", th.getMessage(), th);
}
}
}).start();
if (!this.a || com.mbridge.msdk.foundation.same.a.b.j == null || TextUtils.isEmpty(this.b.getId())) {
return;
}
com.mbridge.msdk.foundation.same.a.b.a(this.g, this.b, "reward");
} catch (Throwable th) {
af.b("NotifyListener", th.getMessage(), th);
}
}
public final void g() {
CampaignEx campaignEx;
List<String> pv_urls;
try {
if (!this.a || this.m || (campaignEx = this.b) == null) {
return;
}
this.m = true;
if ((campaignEx.isDynamicView() && this.d && !this.b.isCampaignIsFiltered()) || (pv_urls = this.b.getPv_urls()) == null || pv_urls.size() <= 0) {
return;
}
Iterator<String> it = pv_urls.iterator();
while (it.hasNext()) {
com.mbridge.msdk.click.a.a(com.mbridge.msdk.foundation.controller.c.m().c(), this.b, this.g, it.next(), false, true);
}
} catch (Throwable th) {
af.b("NotifyListener", th.getMessage());
}
}
public final void h() {
CampaignEx campaignEx = this.b;
if (campaignEx == null || TextUtils.isEmpty(campaignEx.getCampaignUnitId()) || this.b.getNativeVideoTracking() == null || this.b.getNativeVideoTracking().o() == null) {
return;
}
Context c = com.mbridge.msdk.foundation.controller.c.m().c();
CampaignEx campaignEx2 = this.b;
com.mbridge.msdk.click.a.a(c, campaignEx2, campaignEx2.getCampaignUnitId(), this.b.getNativeVideoTracking().o(), false, false);
}
public final void a(String str) {
try {
if (this.b != null) {
com.mbridge.msdk.foundation.same.report.d.e eVar = new com.mbridge.msdk.foundation.same.report.d.e();
eVar.a("url", this.b.getVideoUrlEncode());
eVar.a("reason", str);
String noticeUrl = this.b.getNoticeUrl();
String clickURL = this.b.getClickURL();
if (TextUtils.isEmpty(noticeUrl)) {
if (!TextUtils.isEmpty(clickURL)) {
eVar.a("offer_url", clickURL);
}
} else {
eVar.a("offer_url", noticeUrl);
}
com.mbridge.msdk.foundation.same.report.d.d.a().a("2000021", this.b, eVar);
}
} catch (Exception e) {
e.printStackTrace();
}
}
public final void b(String str) {
List<CampaignEx> list;
if (this.b == null || (list = this.c) == null || list.size() == 0 || TextUtils.isEmpty(str)) {
return;
}
try {
JSONObject jSONObject = new JSONObject(str);
if (jSONObject.has("camp_position")) {
this.b = this.c.get(jSONObject.getInt("camp_position"));
}
} catch (Exception e) {
if (MBridgeConstans.DEBUG) {
af.b("NotifyListener", e.getMessage());
}
}
}
}

View File

@@ -0,0 +1,13 @@
package com.mbridge.msdk.video.module.a.a;
/* loaded from: classes4.dex */
public final class l extends i {
public l(com.mbridge.msdk.video.module.a.a aVar) {
super(aVar);
}
@Override // com.mbridge.msdk.video.module.a.a.i, com.mbridge.msdk.video.module.a.a.f, com.mbridge.msdk.video.module.a.a
public final void a(int i, Object obj) {
super.a(i, obj);
}
}

View File

@@ -0,0 +1,381 @@
package com.mbridge.msdk.video.module.a.a;
import android.os.Handler;
import android.text.TextUtils;
import android.widget.FrameLayout;
import android.widget.TextView;
import com.mbridge.msdk.MBridgeConstans;
import com.mbridge.msdk.dycreator.baseview.cusview.SoundImageView;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.tools.ah;
import com.mbridge.msdk.foundation.tools.ak;
import com.mbridge.msdk.video.module.MBridgeContainerView;
import com.mbridge.msdk.video.module.MBridgeVideoView;
import java.util.Timer;
import java.util.TimerTask;
/* loaded from: classes4.dex */
public final class m extends o {
private MBridgeVideoView l;
private MBridgeContainerView m;
private int n;
private Timer o;
private Handler p;
private boolean q;
private boolean r;
private boolean s;
private int t;
private int u;
private MBridgeVideoView.a v;
public m(MBridgeVideoView mBridgeVideoView, MBridgeContainerView mBridgeContainerView, CampaignEx campaignEx, com.mbridge.msdk.videocommon.b.c cVar, com.mbridge.msdk.videocommon.download.a aVar, String str, String str2, int i, int i2, com.mbridge.msdk.video.module.a.a aVar2, int i3, boolean z, int i4) {
super(campaignEx, cVar, aVar, str, str2, aVar2, i3, z);
this.p = new Handler();
this.q = false;
this.r = false;
this.s = false;
this.l = mBridgeVideoView;
this.m = mBridgeContainerView;
this.u = i;
this.n = i2;
this.t = i4;
if (mBridgeVideoView != null) {
this.q = mBridgeVideoView.getVideoSkipTime() == 0;
}
if (mBridgeVideoView == null || mBridgeContainerView == null) {
this.a = false;
}
}
@Override // com.mbridge.msdk.video.module.a.a.o, com.mbridge.msdk.video.module.a.a.k, com.mbridge.msdk.video.module.a.a.f, com.mbridge.msdk.video.module.a.a
public final void a(int i, Object obj) {
Integer num;
int i2;
CampaignEx campaignEx;
if (this.a) {
if (i == 1) {
if (!this.m.endCardShowing()) {
int videoInteractiveType = this.m.getVideoInteractiveType();
if (videoInteractiveType != -2) {
if (videoInteractiveType == -1) {
if (this.m.isLast()) {
this.m.showVideoClickView(1);
this.l.soundOperate(0, 1);
try {
i();
this.o = new Timer();
this.o.schedule(new TimerTask() { // from class: com.mbridge.msdk.video.module.a.a.m.1
@Override // java.util.TimerTask, java.lang.Runnable
public final void run() {
try {
m.this.p.post(new Runnable() { // from class: com.mbridge.msdk.video.module.a.a.m.1.1
@Override // java.lang.Runnable
public final void run() {
m.this.m.showVideoClickView(-1);
m.this.l.soundOperate(0, 2);
}
});
} catch (Throwable th) {
if (MBridgeConstans.DEBUG) {
th.printStackTrace();
}
}
}
}, 3000L);
} catch (Exception e) {
e.printStackTrace();
}
} else {
this.m.showVideoClickView(-1);
this.l.soundOperate(0, 2);
i();
}
}
} else if (this.m.miniCardLoaded()) {
this.m.showVideoClickView(2);
}
}
} else {
if (i != 2) {
if (i != 5) {
if (i != 6) {
if (i == 8) {
MBridgeContainerView mBridgeContainerView = this.m;
if (mBridgeContainerView == null) {
MBridgeVideoView mBridgeVideoView = this.l;
if (mBridgeVideoView != null) {
mBridgeVideoView.showAlertView();
}
} else if (mBridgeContainerView.showAlertWebView()) {
MBridgeVideoView mBridgeVideoView2 = this.l;
if (mBridgeVideoView2 != null) {
mBridgeVideoView2.alertWebViewShowed();
}
} else {
MBridgeVideoView mBridgeVideoView3 = this.l;
if (mBridgeVideoView3 != null) {
mBridgeVideoView3.showAlertView();
}
}
} else if (i == 20) {
if (ah.a().a("i_l_s_t_r_i", false) && (obj instanceof MBridgeVideoView.a)) {
this.v = (MBridgeVideoView.a) obj;
}
} else {
switch (i) {
case 10:
this.r = true;
this.l.soundOperate(0, 2);
this.l.progressOperate(0, 2);
break;
case 11:
this.l.videoOperate(3);
this.l.dismissAllAlert();
CampaignEx campaignEx2 = this.b;
if (campaignEx2 != null && campaignEx2.getVideo_end_type() != 3 && this.b.getRewardTemplateMode() != null && this.b.getRewardTemplateMode().f() != 5002010) {
if (this.b.getAdSpaceT() != 2) {
this.l.setVisibility(8);
}
} else {
this.l.setVisibility(0);
}
CampaignEx campaignEx3 = this.b;
if (campaignEx3 != null && campaignEx3.getDynamicTempCode() == 5) {
MBridgeVideoView mBridgeVideoView4 = this.l;
if (mBridgeVideoView4.mCurrPlayNum == mBridgeVideoView4.mCampaignSize) {
MBridgeContainerView mBridgeContainerView2 = this.m;
if (mBridgeContainerView2 != null) {
mBridgeContainerView2.setRewardStatus(true);
this.m.showOrderCampView();
break;
}
}
}
CampaignEx campaignEx4 = this.b;
if (campaignEx4 == null || campaignEx4.getRewardTemplateMode() == null || this.b.getRewardTemplateMode().f() != 5002010) {
if (this.b.getAdSpaceT() == 2) {
this.m.showVideoEndCover();
break;
} else {
this.m.showEndcard(this.b.getVideo_end_type());
break;
}
}
break;
case 12:
h();
this.l.videoOperate(3);
this.l.dismissAllAlert();
if (this.b.getVideo_end_type() != 3) {
this.l.setVisibility(8);
} else {
this.l.setVisibility(0);
}
if (this.r || this.t != 0) {
if (this.b.isDynamicView() && this.b.getDynamicTempCode() == 5 && TextUtils.isEmpty(this.b.getendcard_url())) {
j();
this.t = 0;
}
if (!this.r && this.t == 1) {
g();
f();
e();
if (ah.a().a("i_l_s_t_r_i", false) && !this.s) {
this.s = true;
MBridgeVideoView.a aVar = this.v;
if (aVar != null) {
aVar.a();
}
}
}
if (this.b.getAdSpaceT() != 2) {
this.m.showEndcard(this.b.getVideo_end_type());
break;
} else {
this.m.showVideoEndCover();
break;
}
}
break;
case 13:
this.l.closeVideoOperate(0, 2);
break;
case 14:
if (!this.q) {
this.l.closeVideoOperate(0, 1);
break;
}
break;
case 15:
if (obj != null && (obj instanceof MBridgeVideoView.b)) {
MBridgeVideoView.b bVar = (MBridgeVideoView.b) obj;
int videoInteractiveType2 = this.m.getVideoInteractiveType();
if (this.b.getAdSpaceT() == 2) {
SoundImageView soundImageView = this.l.mSoundImageView;
if (soundImageView != null && (soundImageView.getLayoutParams() instanceof FrameLayout.LayoutParams)) {
FrameLayout.LayoutParams layoutParams = (FrameLayout.LayoutParams) this.l.mSoundImageView.getLayoutParams();
layoutParams.setMargins(ak.a(com.mbridge.msdk.foundation.controller.c.m().c(), 5.0f), 0, 0, ak.a(com.mbridge.msdk.foundation.controller.c.m().c(), 85.0f));
this.l.mSoundImageView.setLayoutParams(layoutParams);
}
TextView textView = this.l.tvFlag;
if (textView != null && (textView.getLayoutParams() instanceof FrameLayout.LayoutParams)) {
FrameLayout.LayoutParams layoutParams2 = (FrameLayout.LayoutParams) this.l.tvFlag.getLayoutParams();
layoutParams2.setMargins(ak.a(com.mbridge.msdk.foundation.controller.c.m().c(), 5.0f), 0, 0, ak.a(com.mbridge.msdk.foundation.controller.c.m().c(), 85.0f));
this.l.tvFlag.setVisibility(0);
this.l.tvFlag.setLayoutParams(layoutParams2);
}
this.m.showVideoClickView(1);
} else if (videoInteractiveType2 >= 0 && bVar.a >= videoInteractiveType2) {
this.m.showVideoClickView(1);
this.l.soundOperate(0, 1);
}
this.q = bVar.c;
if (this.b.getDynamicTempCode() != 5) {
int i3 = this.n;
if (((i3 >= 0 && ((i2 = bVar.a) >= i3 || i2 == bVar.b)) || (this.b.getVideoCompleteTime() > 0 && (bVar.a > this.b.getVideoCompleteTime() || bVar.a == bVar.b))) && !this.q) {
this.l.closeVideoOperate(0, 2);
this.q = true;
break;
}
} else {
int i4 = bVar.a;
int i5 = bVar.b;
if (!this.q && this.l != null && (campaignEx = this.b) != null) {
int i6 = this.n;
int i7 = (i6 < 0 || i4 < i6) ? 1 : 2;
if (i7 != 2 && (campaignEx.getVideoCompleteTime() != 0 ? i4 > this.b.getVideoCompleteTime() : this.l.mCurrPlayNum > 1)) {
i7 = 2;
}
if (i7 != 2 && this.l.mCurrPlayNum > 1 && i4 == i5) {
i7 = 2;
}
if (i7 == 2) {
this.l.closeVideoOperate(0, i7);
this.q = true;
break;
}
}
}
}
break;
}
}
}
} else if (obj != null && (obj instanceof Integer)) {
if (((Integer) obj).intValue() == 1) {
num = 2;
} else {
num = 1;
}
this.l.soundOperate(num.intValue(), -1);
}
}
this.l.dismissAllAlert();
this.l.videoOperate(3);
CampaignEx campaignEx5 = this.b;
if (campaignEx5 != null && campaignEx5.isDynamicView() && this.b.getDynamicTempCode() == 5) {
if (this.m != null) {
MBridgeVideoView mBridgeVideoView5 = this.l;
if (mBridgeVideoView5.mCurrPlayNum == mBridgeVideoView5.mCampaignSize) {
if (this.b.getAdSpaceT() != 2) {
this.m.setRewardStatus(true);
this.m.showOrderCampView();
}
i = 16;
}
}
com.mbridge.msdk.video.bt.module.b.f.a(this.b, this.g, this.l.mCurrentPlayProgressTime);
}
if (this.u == 2 && !this.m.endCardShowing() && this.b.getAdSpaceT() != 2) {
this.m.showEndcard(this.b.getVideo_end_type());
}
i = 16;
}
}
super.a(i, obj);
}
private void i() {
try {
Timer timer = this.o;
if (timer != null) {
timer.cancel();
this.o = null;
}
} catch (Exception e) {
e.printStackTrace();
}
}
/* JADX WARN: Removed duplicated region for block: B:23:0x005f */
/* JADX WARN: Removed duplicated region for block: B:32:? A[RETURN, SYNTHETIC] */
/*
Code decompiled incorrectly, please refer to instructions dump.
To view partially-correct add '--show-bad-code' argument
*/
private void j() {
/*
r4 = this;
com.mbridge.msdk.foundation.entity.CampaignEx r0 = r4.b
if (r0 == 0) goto L70
int r0 = r0.getDynamicTempCode()
r1 = 5
if (r0 != r1) goto L70
com.mbridge.msdk.video.module.MBridgeVideoView r0 = r4.l
if (r0 == 0) goto L5c
java.util.List<com.mbridge.msdk.foundation.entity.CampaignEx> r0 = r0.mCampOrderViewData
if (r0 == 0) goto L5c
r0 = 0
r1 = r0
L15:
com.mbridge.msdk.video.module.MBridgeVideoView r2 = r4.l
java.util.List<com.mbridge.msdk.foundation.entity.CampaignEx> r2 = r2.mCampOrderViewData
int r2 = r2.size()
if (r1 >= r2) goto L45
com.mbridge.msdk.video.module.MBridgeVideoView r2 = r4.l
java.util.List<com.mbridge.msdk.foundation.entity.CampaignEx> r2 = r2.mCampOrderViewData
java.lang.Object r2 = r2.get(r1)
if (r2 == 0) goto L42
com.mbridge.msdk.video.module.MBridgeVideoView r2 = r4.l
java.util.List<com.mbridge.msdk.foundation.entity.CampaignEx> r2 = r2.mCampOrderViewData
java.lang.Object r2 = r2.get(r1)
com.mbridge.msdk.foundation.entity.CampaignEx r2 = (com.mbridge.msdk.foundation.entity.CampaignEx) r2
java.lang.String r2 = r2.getId()
com.mbridge.msdk.foundation.entity.CampaignEx r3 = r4.b
java.lang.String r3 = r3.getId()
if (r2 != r3) goto L42
int r0 = r1 + (-1)
goto L45
L42:
int r1 = r1 + 1
goto L15
L45:
if (r0 < 0) goto L5c
com.mbridge.msdk.video.module.MBridgeVideoView r1 = r4.l
java.util.List<com.mbridge.msdk.foundation.entity.CampaignEx> r1 = r1.mCampOrderViewData
java.lang.Object r1 = r1.get(r0)
if (r1 == 0) goto L5c
com.mbridge.msdk.video.module.MBridgeVideoView r1 = r4.l
java.util.List<com.mbridge.msdk.foundation.entity.CampaignEx> r1 = r1.mCampOrderViewData
java.lang.Object r0 = r1.get(r0)
com.mbridge.msdk.foundation.entity.CampaignEx r0 = (com.mbridge.msdk.foundation.entity.CampaignEx) r0
goto L5d
L5c:
r0 = 0
L5d:
if (r0 == 0) goto L70
com.mbridge.msdk.video.module.MBridgeVideoView r1 = r4.l
if (r1 == 0) goto L66
r1.setCampaign(r0)
L66:
com.mbridge.msdk.video.module.MBridgeContainerView r1 = r4.m
if (r1 == 0) goto L6d
r1.setCampaign(r0)
L6d:
r4.a(r0)
L70:
return
*/
throw new UnsupportedOperationException("Method not decompiled: com.mbridge.msdk.video.module.a.a.m.j():void");
}
}

View File

@@ -0,0 +1,185 @@
package com.mbridge.msdk.video.module.a.a;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.tools.ah;
import com.mbridge.msdk.video.module.MBridgeVideoView;
import com.mbridge.msdk.video.signal.factory.IJSFactory;
/* loaded from: classes4.dex */
public final class n extends o {
private IJSFactory l;
private int m;
private boolean n;
private boolean o;
private int p;
private boolean q;
private MBridgeVideoView.a r;
public n(IJSFactory iJSFactory, CampaignEx campaignEx, com.mbridge.msdk.videocommon.b.c cVar, com.mbridge.msdk.videocommon.download.a aVar, String str, String str2, int i, int i2, com.mbridge.msdk.video.module.a.a aVar2, int i3, boolean z, int i4) {
super(campaignEx, cVar, aVar, str, str2, aVar2, i3, z);
this.n = false;
this.o = false;
this.q = false;
this.l = iJSFactory;
this.m = i;
this.n = i2 == 0;
this.p = i4;
if (iJSFactory == null) {
this.a = false;
}
}
@Override // com.mbridge.msdk.video.module.a.a.o, com.mbridge.msdk.video.module.a.a.k, com.mbridge.msdk.video.module.a.a.f, com.mbridge.msdk.video.module.a.a
public final void a(int i, Object obj) {
Integer num;
int i2;
int i3 = i;
if (this.a) {
if (i3 == 1) {
if (!this.l.getJSContainerModule().endCardShowing()) {
this.l.getJSNotifyProxy().a(1, obj != null ? obj.toString() : "");
}
} else {
if (i3 != 2) {
if (i3 != 5) {
if (i3 != 6) {
if (i3 != 8) {
if (i3 != 20) {
if (i3 != 114) {
if (i3 != 116) {
switch (i3) {
case 10:
this.q = true;
this.l.getJSNotifyProxy().a(0);
break;
case 11:
case 12:
this.l.getJSVideoModule().videoOperate(3);
if (this.b.getVideo_end_type() != 3) {
if (this.b.getAdSpaceT() != 2) {
this.l.getJSVideoModule().setVisible(8);
}
} else {
this.l.getJSVideoModule().setVisible(0);
}
if (i3 == 12) {
h();
i2 = 2;
} else {
i2 = 1;
}
this.l.getJSNotifyProxy().a(i2);
if (this.l.getJSCommon().g() == 2) {
this.l.getJSVideoModule().setVisible(0);
com.mbridge.msdk.video.signal.j jSVideoModule = this.l.getJSVideoModule();
this.l.getJSContainerModule().showMiniCard(jSVideoModule.getBorderViewTop(), jSVideoModule.getBorderViewLeft(), jSVideoModule.getBorderViewWidth(), jSVideoModule.getBorderViewHeight(), jSVideoModule.getBorderViewRadius());
} else if (i3 == 12) {
if (this.p == 1) {
if (this.b.getAdSpaceT() != 2) {
this.l.getJSContainerModule().showEndcard(this.b.getVideo_end_type());
} else {
this.l.getJSContainerModule().showVideoEndCover();
}
}
} else if (this.b.getAdSpaceT() != 2) {
this.l.getJSContainerModule().showEndcard(this.b.getVideo_end_type());
} else {
this.l.getJSContainerModule().showVideoEndCover();
}
this.l.getJSVideoModule().dismissAllAlert();
if (i3 == 12 && !this.q && this.p == 1) {
h();
g();
f();
e();
if (ah.a().a("i_l_s_t_r_i", false) && !this.o) {
this.o = true;
MBridgeVideoView.a aVar = this.r;
if (aVar != null) {
aVar.a();
break;
}
}
}
break;
case 13:
if (!this.l.getJSVideoModule().isH5Canvas()) {
this.l.getJSVideoModule().closeVideoOperate(0, 2);
}
this.l.getJSNotifyProxy().a(-1);
break;
case 14:
if (!this.n) {
this.l.getJSVideoModule().closeVideoOperate(0, 1);
break;
}
break;
case 15:
if (obj != null && (obj instanceof MBridgeVideoView.b)) {
this.n = true;
this.l.getJSNotifyProxy().a((MBridgeVideoView.b) obj);
break;
}
break;
default:
switch (i3) {
case 123:
case 124:
this.l.getJSNotifyProxy().a(i3 == 123 ? 7 : 6, "");
break;
case 125:
this.l.getJSContainerModule().hideAlertWebview();
break;
}
}
} else {
com.mbridge.msdk.video.signal.j jSVideoModule2 = this.l.getJSVideoModule();
this.l.getJSContainerModule().configurationChanged(jSVideoModule2.getBorderViewWidth(), jSVideoModule2.getBorderViewHeight(), jSVideoModule2.getBorderViewRadius());
}
} else if (this.l.getJSCommon().g() == 2) {
com.mbridge.msdk.video.signal.j jSVideoModule3 = this.l.getJSVideoModule();
this.l.getJSContainerModule().showMiniCard(jSVideoModule3.getBorderViewTop(), jSVideoModule3.getBorderViewLeft(), jSVideoModule3.getBorderViewWidth(), jSVideoModule3.getBorderViewHeight(), jSVideoModule3.getBorderViewRadius());
}
} else if (ah.a().a("i_l_s_t_r_i", false) && (obj instanceof MBridgeVideoView.a)) {
this.r = (MBridgeVideoView.a) obj;
}
} else if (!this.l.getJSContainerModule().showAlertWebView()) {
this.l.getJSVideoModule().showAlertView();
} else {
this.l.getJSVideoModule().alertWebViewShowed();
}
}
} else if (obj != null && (obj instanceof Integer)) {
if (((Integer) obj).intValue() == 1) {
num = 2;
} else {
num = 1;
}
this.l.getJSVideoModule().soundOperate(num.intValue(), -1);
this.l.getJSNotifyProxy().a(5, num + "");
}
}
this.l.getJSVideoModule().dismissAllAlert();
if (i3 == 2) {
this.l.getJSNotifyProxy().a(2, "");
}
this.l.getJSVideoModule().videoOperate(3);
int i4 = 16;
if (this.l.getJSCommon().g() != 2) {
if (this.b.getVideo_end_type() != 3) {
this.l.getJSVideoModule().setVisible(8);
} else {
this.l.getJSVideoModule().setVisible(0);
}
if (this.m == 2 && !this.l.getJSContainerModule().endCardShowing() && this.b.getAdSpaceT() != 2) {
this.l.getJSContainerModule().showEndcard(this.b.getVideo_end_type());
i4 = i3;
}
}
this.l.getJSNotifyProxy().a(1);
i3 = i4;
}
}
super.a(i3, obj);
}
}

View File

@@ -0,0 +1,178 @@
package com.mbridge.msdk.video.module.a.a;
import android.text.TextUtils;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.tools.af;
import com.mbridge.msdk.foundation.tools.ah;
import com.mbridge.msdk.video.module.MBridgeVideoView;
import com.mbridge.msdk.video.module.a.a.k;
import java.io.File;
import java.util.Map;
/* loaded from: classes4.dex */
public class o extends k {
protected int k;
private boolean l;
private boolean m;
private boolean n;
private boolean o;
private boolean p;
private boolean q;
private Map<Integer, String> r;
private MBridgeVideoView.a s;
private int t;
public o(CampaignEx campaignEx, com.mbridge.msdk.videocommon.b.c cVar, com.mbridge.msdk.videocommon.download.a aVar, String str, String str2, com.mbridge.msdk.video.module.a.a aVar2, int i, boolean z) {
super(campaignEx, aVar, cVar, str, str2, aVar2, i, z);
this.q = false;
this.k = 0;
this.t = -1;
if (this.a) {
this.r = campaignEx.getAdvImpList();
}
this.k = campaignEx.getVideoCompleteTime();
}
@Override // com.mbridge.msdk.video.module.a.a.k, com.mbridge.msdk.video.module.a.a.f, com.mbridge.msdk.video.module.a.a
public void a(int i, final Object obj) {
int i2;
CampaignEx campaignEx;
try {
if (i != 2) {
int i3 = 0;
if (i != 20) {
if (i != 130) {
if (i != 6) {
if (i != 7) {
if (i == 15) {
g();
f();
e();
if (ah.a().a("i_l_s_t_r_i", false) && !this.o) {
this.o = true;
MBridgeVideoView.a aVar = this.s;
if (aVar != null) {
aVar.a();
}
}
if (obj == null || !(obj instanceof MBridgeVideoView.b)) {
i2 = 0;
} else {
int i4 = ((MBridgeVideoView.b) obj).a;
i3 = ((MBridgeVideoView.b) obj).b;
i2 = i4;
}
if (i3 == 0 && (campaignEx = this.b) != null) {
i3 = campaignEx.getVideoLength();
}
com.mbridge.msdk.video.module.b.b.a(com.mbridge.msdk.foundation.controller.c.m().c(), this.b, i2, i3, this.j);
com.mbridge.msdk.video.module.b.b.a(this.b, this.r, this.g, i2);
if (!this.p) {
this.p = true;
com.mbridge.msdk.video.module.b.b.a(this.b, this.g);
}
if (!this.q) {
int i5 = this.k;
if (i5 != 0) {
i3 = i5;
}
if (i2 >= i3) {
this.q = true;
i = 17;
}
}
af.b("NotifyListener", "onPlayProgress:" + i2);
this.t = i2;
} else if (i != 16) {
switch (i) {
case 11:
com.mbridge.msdk.videocommon.download.b.getInstance().b(false);
d();
break;
case 12:
Runnable runnable = new Runnable() { // from class: com.mbridge.msdk.video.module.a.a.o.1
@Override // java.lang.Runnable
public final void run() {
Object obj2 = obj;
if (obj2 instanceof String) {
o.this.a((String) obj2);
}
}
};
com.mbridge.msdk.foundation.controller.d.a();
com.mbridge.msdk.foundation.same.f.a.b().execute(runnable);
d();
b();
c();
k.AnonymousClass4 anonymousClass4 = new Runnable() { // from class: com.mbridge.msdk.video.module.a.a.k.4
public AnonymousClass4() {
}
@Override // java.lang.Runnable
public final void run() {
com.mbridge.msdk.videocommon.download.a aVar2;
try {
if (ah.a().a("c_r_v_f_w_s_e", false)) {
return;
}
k kVar = k.this;
if (!kVar.a || (aVar2 = kVar.e) == null) {
return;
}
if (aVar2.l() != null && !TextUtils.isEmpty(k.this.e.l().getVideoUrlEncode())) {
com.mbridge.msdk.foundation.db.n.a(com.mbridge.msdk.foundation.db.g.a(com.mbridge.msdk.foundation.controller.c.m().c())).b(k.this.e.l().getVideoUrlEncode());
}
if (TextUtils.isEmpty(k.this.e.h())) {
return;
}
File file = new File(k.this.e.h());
if (file.exists() && file.isFile() && file.delete()) {
af.a("NotifyListener", "DEL File :" + file.getAbsolutePath());
}
} catch (Exception e) {
e.printStackTrace();
}
}
};
com.mbridge.msdk.foundation.controller.d.a();
com.mbridge.msdk.foundation.same.f.a.b().execute(anonymousClass4);
com.mbridge.msdk.videocommon.download.b.getInstance().b(false);
break;
case 13:
b();
c();
break;
}
}
} else if (this.a && obj != null && (obj instanceof Integer)) {
int intValue = ((Integer) obj).intValue();
if (intValue == 2) {
if (!this.m) {
this.m = true;
com.mbridge.msdk.video.module.b.b.b(com.mbridge.msdk.foundation.controller.c.m().c(), this.b);
}
} else if (intValue == 1 && !this.l) {
this.l = true;
com.mbridge.msdk.video.module.b.b.c(com.mbridge.msdk.foundation.controller.c.m().c(), this.b);
}
}
}
} else if (obj instanceof Integer) {
this.k = ((Integer) obj).intValue();
}
} else if (ah.a().a("i_l_s_t_r_i", false) && (obj instanceof MBridgeVideoView.a)) {
this.s = (MBridgeVideoView.a) obj;
}
this.i.a(i, obj);
}
if (this.a && !this.n) {
this.n = true;
d();
com.mbridge.msdk.video.module.b.b.e(com.mbridge.msdk.foundation.controller.c.m().c(), this.b);
}
this.i.a(i, obj);
} catch (Throwable th) {
af.b("NotifyListener", th.getMessage(), th);
}
}
}

View File

@@ -0,0 +1,51 @@
package com.mbridge.msdk.video.module.b;
import android.text.TextUtils;
import com.mbridge.msdk.MBridgeConstans;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.same.report.d.d;
import com.mbridge.msdk.foundation.same.report.d.e;
import com.mbridge.msdk.foundation.tools.aq;
/* loaded from: classes4.dex */
public final class a {
public static void a(String str, CampaignEx campaignEx, e eVar) {
String str2;
String str3;
if (TextUtils.isEmpty(str) || campaignEx == null || eVar == null) {
return;
}
try {
String mof_template_url = campaignEx.getMof_template_url();
String str4 = "";
if (TextUtils.isEmpty(mof_template_url)) {
str2 = "";
str3 = str2;
} else {
str3 = aq.a(mof_template_url, "cltp");
str2 = aq.a(mof_template_url, "xt");
}
if (!TextUtils.isEmpty(str3)) {
eVar.a("cltp", str3);
}
if (!TextUtils.isEmpty(str2)) {
eVar.a("xt", str2);
}
CampaignEx.c rewardTemplateMode = campaignEx.getRewardTemplateMode();
if (rewardTemplateMode != null) {
String e = rewardTemplateMode.e();
if (!TextUtils.isEmpty(e)) {
str4 = aq.a(e, "alecfc");
}
}
if (!TextUtils.isEmpty(str4)) {
eVar.a("alecfc", str4);
}
d.a().a(str, campaignEx, eVar);
} catch (Exception e2) {
if (MBridgeConstans.DEBUG) {
e2.printStackTrace();
}
}
}
}

View File

@@ -0,0 +1,253 @@
package com.mbridge.msdk.video.module.b;
import android.content.Context;
import android.text.TextUtils;
import com.ironsource.v8;
import com.mbridge.msdk.MBridgeConstans;
import com.mbridge.msdk.foundation.controller.c;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.mbridge.msdk.foundation.same.report.d.d;
import com.mbridge.msdk.foundation.same.report.d.e;
import com.mbridge.msdk.foundation.tools.af;
import com.mbridge.msdk.foundation.tools.z;
import java.net.URLEncoder;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import org.json.JSONObject;
/* loaded from: classes4.dex */
public final class b {
public static HashMap<String, ArrayList<String>> a = new HashMap<>();
public static void a(String str) {
a.remove(str);
}
public static void a(Context context, CampaignEx campaignEx) {
if (campaignEx == null || campaignEx.getNativeVideoTracking() == null || campaignEx.getNativeVideoTracking().p() == null) {
return;
}
d.a().a("2000141", campaignEx);
com.mbridge.msdk.click.a.a(context, campaignEx, campaignEx.getCampaignUnitId(), campaignEx.getNativeVideoTracking().p(), false, false);
}
public static void b(Context context, CampaignEx campaignEx) {
if (campaignEx == null || campaignEx.getNativeVideoTracking() == null || campaignEx.getNativeVideoTracking().j() == null) {
return;
}
com.mbridge.msdk.click.a.a(context, campaignEx, campaignEx.getCampaignUnitId(), campaignEx.getNativeVideoTracking().j(), false, false);
}
public static void c(Context context, CampaignEx campaignEx) {
if (campaignEx == null || campaignEx.getNativeVideoTracking() == null || campaignEx.getNativeVideoTracking().k() == null) {
return;
}
com.mbridge.msdk.click.a.a(context, campaignEx, campaignEx.getCampaignUnitId(), campaignEx.getNativeVideoTracking().k(), false, false);
}
public static void d(Context context, CampaignEx campaignEx) {
if (campaignEx == null || campaignEx.getNativeVideoTracking() == null || campaignEx.getNativeVideoTracking().l() == null) {
return;
}
String campaignUnitId = campaignEx.getCampaignUnitId();
ArrayList<String> arrayList = a.get(campaignUnitId);
if (arrayList == null) {
arrayList = new ArrayList<>();
a.put(campaignUnitId, arrayList);
}
if (arrayList.contains(campaignEx.getId())) {
return;
}
try {
d.a().a("2000142", campaignEx);
} catch (Exception unused) {
}
com.mbridge.msdk.click.a.a(context, campaignEx, campaignEx.getCampaignUnitId(), campaignEx.getNativeVideoTracking().l(), false, false);
arrayList.add(campaignEx.getId());
}
public static void a(Context context, CampaignEx campaignEx, int i, int i2) {
try {
String[] r = campaignEx.getNativeVideoTracking().r();
if (campaignEx.getNativeVideoTracking() == null || r == null) {
return;
}
String[] strArr = new String[r.length];
for (int i3 = 0; i3 < r.length; i3++) {
String str = r[i3];
JSONObject jSONObject = new JSONObject();
jSONObject.put("endscreen_type", i);
String jSONObject2 = jSONObject.toString();
if (!TextUtils.isEmpty(jSONObject2)) {
jSONObject2 = z.b(jSONObject2);
}
if (!TextUtils.isEmpty(jSONObject2)) {
str = str + "&value=" + URLEncoder.encode(jSONObject2);
}
strArr[i3] = campaignEx.getSpareOfferFlag() == 1 ? str + "&to=1&cbt=" + campaignEx.getCbt() + "&tmorl=" + i2 : str + "&to=0&cbt=" + campaignEx.getCbt() + "&tmorl=" + i2;
}
try {
e eVar = new e();
eVar.a("type", Integer.valueOf(i));
d.a().a("2000144", campaignEx, eVar);
d.a().a("2000147", campaignEx, eVar);
} catch (Exception unused) {
}
com.mbridge.msdk.click.a.a(context, campaignEx, campaignEx.getCampaignUnitId(), strArr, false, true);
} catch (Throwable unused2) {
af.b("VideoViewReport", "reportEndcardshowData error");
}
}
public static void e(Context context, CampaignEx campaignEx) {
if (campaignEx == null || campaignEx.getNativeVideoTracking() == null || campaignEx.getNativeVideoTracking().s() == null) {
return;
}
d.a().a("2000143", campaignEx);
com.mbridge.msdk.click.a.a(context, campaignEx, campaignEx.getCampaignUnitId(), campaignEx.getNativeVideoTracking().s(), false, false);
}
public static void f(Context context, CampaignEx campaignEx) {
if (campaignEx == null || campaignEx.getNativeVideoTracking() == null || campaignEx.getNativeVideoTracking().m() == null) {
return;
}
com.mbridge.msdk.click.a.a(context, campaignEx, campaignEx.getCampaignUnitId(), campaignEx.getNativeVideoTracking().m(), false, false);
}
public static void a(Context context, CampaignEx campaignEx, int i, int i2, int i3) {
String str;
if (i2 == 0 || context == null || campaignEx == null) {
return;
}
try {
List<Map<Integer, String>> i4 = campaignEx.getNativeVideoTracking().i();
int i5 = ((i + 1) * 100) / i2;
if (i4 != null) {
int i6 = 0;
int i7 = 0;
while (i6 < i4.size()) {
Map<Integer, String> map = i4.get(i6);
if (map != null && map.size() > 0) {
Iterator<Map.Entry<Integer, String>> it = map.entrySet().iterator();
int i8 = i6;
while (it.hasNext()) {
Map.Entry<Integer, String> next = it.next();
int intValue = next.getKey().intValue();
String value = next.getValue();
if (campaignEx.getSpareOfferFlag() == 1) {
str = value + "&to=1&cbt=" + campaignEx.getCbt() + "&tmorl=" + i3;
} else {
str = value + "&to=0&cbt=" + campaignEx.getCbt() + "&tmorl=" + i3;
}
if (intValue <= i5 && !TextUtils.isEmpty(str)) {
String[] strArr = {str};
if (i7 < 1) {
i7++;
try {
e eVar = new e();
eVar.a("percent", Integer.valueOf(intValue));
d.a().a("2000140", campaignEx, eVar);
} catch (Exception unused) {
}
}
int i9 = i7;
com.mbridge.msdk.click.a.a(context, campaignEx, campaignEx.getCampaignUnitId(), strArr, false, true);
it.remove();
i4.remove(i8);
i8--;
i7 = i9;
}
}
i6 = i8;
}
i6++;
}
}
} catch (Throwable unused2) {
af.b("VideoViewReport", "reportPlayPercentageData error");
}
}
public static void a(CampaignEx campaignEx, Map<Integer, String> map, String str, int i) {
if (campaignEx == null || map == null) {
return;
}
try {
if (map.size() > 0) {
Iterator<Map.Entry<Integer, String>> it = map.entrySet().iterator();
while (it.hasNext()) {
Map.Entry<Integer, String> next = it.next();
Integer key = next.getKey();
String value = next.getValue();
if (i == key.intValue() && !TextUtils.isEmpty(value)) {
com.mbridge.msdk.click.a.a(c.m().c(), campaignEx, str, value, false, false);
it.remove();
}
}
}
} catch (Exception e) {
e.printStackTrace();
}
}
public static void a(CampaignEx campaignEx, String str) {
if (campaignEx != null) {
try {
if (campaignEx.getAdUrlList() == null || campaignEx.getAdUrlList().size() <= 0) {
return;
}
for (String str2 : campaignEx.getAdUrlList()) {
if (!TextUtils.isEmpty(str2)) {
com.mbridge.msdk.click.a.a(c.m().c(), campaignEx, str, str2, false, false);
}
}
} catch (Exception e) {
e.printStackTrace();
}
}
}
public static void a(CampaignEx campaignEx, com.mbridge.msdk.videocommon.b.c cVar, String str, String str2, String str3) {
String str4 = v8.i.c;
String str5 = "";
if (campaignEx == null || cVar == null) {
return;
}
try {
com.mbridge.msdk.video.module.c.b bVar = new com.mbridge.msdk.video.module.c.b(c.m().c());
com.mbridge.msdk.foundation.same.net.f.e eVar = new com.mbridge.msdk.foundation.same.net.f.e();
eVar.a("user_id", z.b(str2));
eVar.a("cb_type", "1");
eVar.a(CampaignEx.JSON_KEY_REWARD_NAME, cVar.a());
eVar.a(CampaignEx.JSON_KEY_REWARD_AMOUNT, cVar.b() + "");
eVar.a(MBridgeConstans.PROPERTIES_UNIT_ID, str);
eVar.a("click_id", campaignEx.getRequestIdNotice());
if (!TextUtils.isEmpty(str3)) {
eVar.a("extra", str3);
}
bVar.addExtraParams("", eVar);
String str6 = campaignEx.getHost() + "/addReward?";
String trim = eVar.b().trim();
if (!TextUtils.isEmpty(trim)) {
if (!str6.endsWith("?") && !str6.endsWith(v8.i.c)) {
StringBuilder sb = new StringBuilder();
sb.append(str6);
if (!str6.contains("?")) {
str4 = "?";
}
sb.append(str4);
str6 = sb.toString();
}
str5 = str6 + trim;
}
String str7 = str5;
af.b("VideoViewReport", "rewardUrl:" + str7);
com.mbridge.msdk.click.a.a(c.m().c(), campaignEx, campaignEx.getCampaignUnitId(), str7, false, false);
} catch (Throwable th) {
af.b("VideoViewReport", th.getMessage(), th);
}
}
}

View File

@@ -0,0 +1,41 @@
package com.mbridge.msdk.video.module.c;
import android.content.Context;
import android.os.Build;
import com.mbridge.msdk.foundation.same.net.f.c;
import com.mbridge.msdk.foundation.same.net.f.e;
import com.mbridge.msdk.foundation.tools.ab;
import com.mbridge.msdk.foundation.tools.f;
import com.mbridge.msdk.out.MBConfiguration;
/* loaded from: classes4.dex */
public class a extends c {
public a(Context context) {
super(context);
}
@Override // com.mbridge.msdk.foundation.same.net.f.c
public void addExtraParams(String str, e eVar) {
super.addExtraParams(str, eVar);
eVar.a("platform", "1");
eVar.a("os_version", Build.VERSION.RELEASE);
eVar.a("package_name", ab.f(this.mContext));
eVar.a("app_version_name", ab.q(this.mContext));
eVar.a("app_version_code", ab.r(this.mContext) + "");
eVar.a("orientation", ab.s(this.mContext) + "");
eVar.a("model", ab.h());
eVar.a("brand", ab.x());
eVar.a("mnc", ab.l(this.mContext));
eVar.a("mcc", ab.k(this.mContext));
eVar.a("gaid", "");
eVar.a("gaid2", f.b());
int m = ab.m(this.mContext);
eVar.a("network_type", m + "");
eVar.a("network_str", ab.a(this.mContext, m) + "");
eVar.a("language", ab.t(this.mContext));
eVar.a("timezone", ab.y());
eVar.a("useragent", ab.g());
eVar.a("sdk_version", MBConfiguration.SDK_VERSION);
eVar.a("screen_size", ab.j(this.mContext) + "x" + ab.h(this.mContext));
}
}

View File

@@ -0,0 +1,36 @@
package com.mbridge.msdk.video.module.c;
import android.content.Context;
import android.text.TextUtils;
import com.mbridge.msdk.c.h;
import com.mbridge.msdk.foundation.controller.c;
import com.mbridge.msdk.foundation.same.net.f.e;
import com.mbridge.msdk.foundation.tools.z;
import org.json.JSONObject;
/* loaded from: classes4.dex */
public final class b extends a {
public b(Context context) {
super(context);
}
@Override // com.mbridge.msdk.video.module.c.a, com.mbridge.msdk.foundation.same.net.f.c
public final void addExtraParams(String str, e eVar) {
super.addExtraParams(str, eVar);
if (h.a().b(c.m().k()) != null) {
JSONObject jSONObject = new JSONObject();
try {
if (TextUtils.isEmpty(jSONObject.toString())) {
return;
}
String b = z.b(jSONObject.toString());
if (TextUtils.isEmpty(b)) {
return;
}
eVar.a("dvi", b);
} catch (Exception e) {
e.printStackTrace();
}
}
}
}