去广告成功,但无法投屏,无限重启,上一级函数怎么找?
//// Decompiled by FernFlower - 1823ms
//
package com.gongwu.wherecollect.activity;
import android.app.Dialog;
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import android.support.design.widget.FloatingActionButton;
importandroid.support.v7.app.ActionBarActivity;
import android.text.TextUtils;
import android.view.KeyEvent;
import android.view.View;
import android.view.ViewGroup;
import android.view.View.OnClickListener;
import android.webkit.WebSettings;
import android.webkit.WebView;
importandroid.webkit.WebSettings.PluginState;
importandroid.webkit.WebSettings.RenderPriority;
import android.widget.RelativeLayout;
import android.widget.Toast;
import b.b.a.a;
import com.gongwu.wherecollect.application.MyApplication;
importcom.gongwu.wherecollect.util.CollectBeanUtil;
importcom.gongwu.wherecollect.util.DialogUtil;
importcom.gongwu.wherecollect.util.EventBusMsg;
importcom.gongwu.wherecollect.util.LookRecordUtil;
import com.gongwu.wherecollect.util.SaveDate;
importcom.gongwu.wherecollect.util.StringUtils;
importcom.gongwu.wherecollect.util.ToastUtil;
import com.qq.e.ads.banner.ADSize;
import com.qq.e.ads.banner.BannerView;
import org.greenrobot.eventbus.ThreadMode;
import org.greenrobot.eventbus.e;
import org.greenrobot.eventbus.k;
public class NativeWebActivity extendsActionBarActivity implements OnClickListener {
ViewGroup a;
FloatingActionButton b;
FloatingActionButton c;
long d = 0L;
private WebView e;
private RelativeLayout f;
private RelativeLayout g;
private String h;
private String i;
private int j = 0;
private a k;
//$FF: synthetic method
static int a(NativeWebActivity var0) {
return var0.j;
}
//$FF: synthetic method
staticString a(NativeWebActivity var0, String var1) {
return var0.c(var1);
}
//$FF: synthetic method
static int b(NativeWebActivity var0) {
int var1 = var0.j;
var0.j = var1 + 1;
return var1;
}
//$FF: synthetic method
static String b(NativeWebActivity var0, String var1) {
return var0.b(var1);
}
private String b(String var1) {
String[] var3 = var1.split("&");
int var2 = 0;
while(true) {
if (var2 >= var3.length) {
var1 = "";
break;
}
if (var3.startsWith("vid=")) {
var1 = var3.replace("vid=", "");
break;
}
++var2;
}
return TextUtils.isEmpty(var1) ? "" : String.format("http://m.le.com/vplay_%s.html",var1);
}
private String c(String var1) {
String[] var3 = var1.split("&");
int var2 = 0;
while(true) {
if (var2 >= var3.length) {
var1 = "";
break;
}
if(var3.startsWith("showid=")) {
var1 = var3.replace("showid=", "");
break;
}
++var2;
}
return TextUtils.isEmpty(var1) ? "" :String.format("http://m.youku.com/video/id_%s.html", var1);
}
private void c() {
try {
BannerView var1 = new BannerView(this, ADSize.BANNER,"1107880329", "9000746335268600");
this.g.addView(var1);
var1.setRefresh(30);
var1.loadAD();
} catch (Exception var2) {
var2.printStackTrace();
}
}
//$FF: synthetic method
static void c(NativeWebActivity var0) {
var0.g();
}
private void d() {
this.b.setOnTouchListener(new X(this));
}
private boolean e() {
if (this.e.canGoBack()) {
this.e.goBack();
return true;
} else {
return false;
}
}
private void f() {
String var2 = this.e.getUrl();
this.e.getOriginalUrl();
LookRecordUtil.saveRecord(this.e.getUrl(), this.e.getTitle(),"0");
String var1;
if (var2.contains("iqiyi.com")) {
var1 = var2.replace("//m.", "//www.");
} else if (var2.contains("qq.com")) {
var1 = var2.replace("//m.", "//");
} else if (var2.contains("youku.com")) {
var1 = var2.replace("//m.", "//.");
} else {
var1 = var2;
if (var2.contains("le.com")) {
var1 = var2.replace("//m.","//www.").replace("vplay_", "ptv/vplay/");
}
}
PlayActivity.start(this, var1, "", this.e.getTitle());
}
private void g() {
String var1 = this.e.getUrl();
if (var1 != null) {
if (var1.contains("youku.com") &&!StringUtils.hasUpcase(var1)) {
DialogUtil.show("提醒", "优酷视频必须先点击一下选集,否则无法解析。电影也有选集哦!","我知道了", this);
} else {
if (SaveDate.getInstence(this).getLastVideoTime().longValue() ==Long.MAX_VALUE) {
SaveDate.getInstence(this).setLastVideoTime(System.currentTimeMillis());
}
this.f();
}
}
}
private void h() {
Dialog var1 = new Dialog(this);
var1.setContentView(0x7f0b0065);
var1.show();
}
public static void start(Context var0, String var1, String var2) {
Intent var3 = new Intent(var0, NativeWebActivity.class);
var3.putExtra("url", var1);
var3.putExtra("html", var2);
var0.startActivity(var3);
}
public boolean dispatchKeyEvent(KeyEvent var1) {
if (StringUtils.isTv(this)) {
a var3 = this.k;
if (var3 != null) {
boolean var2;
if (var3.a(var1)) {
var2 = true;
} else {
var2 =super.dispatchKeyEvent(var1);
}
return var2;
}
}
return super.dispatchKeyEvent(var1);
}
public void initMouse() {
if (this.k == null) {
this.k = b.b.a.a.a(this);
this.k.a(this.getWindow().getDecorView(),(com.tencent.smtt.sdk.WebView)null);
this.k.a(true);
}
}
public void onBackPressed() {
if (System.currentTimeMillis() - this.d < 2000L) {
this.finish();
} else {
this.d = System.currentTimeMillis();
}
if (!this.e()) {
super.onBackPressed();
}
}
public void onClick(View var1) {
if (var1.getId() == 0x7f09004d) {
ToastUtil.showTopMsg(this, "收藏成功");
CollectBeanUtil.saveCollect(this.e.getUrl(), this.e.getTitle(),"0");
}
}
protected void onCreate(Bundle var1) {
super.onCreate(var1);
this.setContentView(0x7f0b0034);
org.greenrobot.eventbus.e.a().b(this);
this.h = this.getIntent().getStringExtra("url");
this.i = this.getIntent().getStringExtra("html");
this.f = (RelativeLayout)this.findViewById(0x7f09018e);
this.e = (WebView)this.findViewById(0x7f09018c);
this.g = (RelativeLayout)this.findViewById(0x7f090024);
this.a = (ViewGroup)this.findViewById(0x7f090183);
this.b = (FloatingActionButton)this.findViewById(0x7f0900d2);
this.c = (FloatingActionButton)this.findViewById(0x7f09004d);
this.c.setOnClickListener(this);
this.j = SaveDate.getInstence(this).getClickCount();
this.e.setWebViewClient(new com.gongwu.wherecollect.activity.NativeWebActivity.a(this,(X)null));
WebSettings var2 = this.e.getSettings();
var2.setJavaScriptEnabled(true);
var2.setAllowFileAccess(true);
var2.setSupportZoom(true);
var2.setBuiltInZoomControls(false);
var2.setUseWideViewPort(true);
var2.setSupportMultipleWindows(false);
var2.setLoadWithOverviewMode(true);
var2.setAppCacheEnabled(true);
var2.setDomStorageEnabled(true);
var2.setJavaScriptEnabled(true);
var2.setGeolocationEnabled(true);
var2.setAllowUniversalAccessFromFileURLs(true);
var2.setAllowContentAccess(true);
var2.setAllowFileAccess(true);
var2.setAppCacheMaxSize(Long.MAX_VALUE);
var2.setAppCachePath(MyApplication.CACHEPATH);
var2.setPluginState(PluginState.ON_DEMAND);
var2.setRenderPriority(RenderPriority.HIGH);
if (!TextUtils.isEmpty(this.h)) {
this.e.loadUrl(this.h);
}
this.c();
this.d();
if (SaveDate.getInstence(this.getApplication()).isFirstHelp()) {
SaveDate.getInstence(this.getApplication()).setIsFirstHelp(false);
this.h();
}
}
protected void onDestroy() {
super.onDestroy();
try {
org.greenrobot.eventbus.e.a().c(this);
this.e.destroy();
} catch (Exception var2) {
var2.printStackTrace();
}
}
public boolean onKeyDown(int var1, KeyEvent var2) {
if (var1 == 82) {
this.g();
return true;
} else {
return super.onKeyDown(var1, var2);
}
}
@k(
threadMode = ThreadMode.MAIN
)
public void onMessageEvent(EventBusMsg var1) {
Toast.makeText(this, "加载播放插件成功,2秒后将关闭应用,请手动重启", 1).show();
(new Handler()).postDelayed(new Y(this), 3000L);
}
protectedvoid onResume() {
super.onResume();
if (StringUtils.isTv(this)) {
this.initMouse();
}
}
}
https://static.52pojie.cn/static/image/hrline/2.gif
.class public Lcom/gongwu/wherecollect/activity/WebActivity;
.super Landroid/support/v7/app/ActionBarActivity;
.source "TbsSdkJava"
# interfaces
.implements Landroid/view/View$OnClickListener;
# annotations
.annotation system Ldalvik/annotation/MemberClasses;
value = {
Lcom/gongwu/wherecollect/activity/WebActivity$a;
}
.end annotation
# instance fields
.field a:Landroid/view/ViewGroup;
.field b:Landroid/support/design/widget/FloatingActionButton;
.field c:Landroid/support/design/widget/FloatingActionButton;
.field d:J
.field private e:Lcom/tencent/smtt/sdk/WebView;
.field private f:Landroid/widget/RelativeLayout;
.field private g:Landroid/widget/RelativeLayout;
.field private h:Ljava/lang/String;
.field private i:Ljava/lang/String;
.field private j:I
.field private k:Lb/b/a/a;
# direct methods
.method public constructor <init>()V
.registers 3
.line 1
invoke-direct {p0}, Landroid/support/v7/app/ActionBarActivity;-><init>()V
const-wide/16 v0, 0x0
.line 2
iput-wide v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->d:J
const/4 v0, 0x0
.line 3
iput v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->j:I
return-void
.end method
.method static synthetic a(Lcom/gongwu/wherecollect/activity/WebActivity;)I
.registers 1
.line 1
iget p0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->j:I
return p0
.end method
.method static synthetic a(Lcom/gongwu/wherecollect/activity/WebActivity;Ljava/lang/String;)Ljava/lang/String;
.registers 2
.line 2
invoke-direct {p0, p1}, Lcom/gongwu/wherecollect/activity/WebActivity;->c(Ljava/lang/String;)Ljava/lang/String;
move-result-object p0
return-object p0
.end method
.method static synthetic b(Lcom/gongwu/wherecollect/activity/WebActivity;)I
.registers 3
.line 1
iget v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->j:I
add-int/lit8 v1, v0, 0x1
iput v1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->j:I
return v0
.end method
.method static synthetic b(Lcom/gongwu/wherecollect/activity/WebActivity;Ljava/lang/String;)Ljava/lang/String;
.registers 2
.line 2
invoke-direct {p0, p1}, Lcom/gongwu/wherecollect/activity/WebActivity;->b(Ljava/lang/String;)Ljava/lang/String;
move-result-object p0
return-object p0
.end method
.method private b(Ljava/lang/String;)Ljava/lang/String;
.registers 7
const-string v0, "&"
.line 3
invoke-virtual {p1, v0}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;
move-result-object p1
const/4 v0, 0x0
const/4 v1, 0x0
.line 4
:goto_8
array-length v2, p1
const-string v3, ""
if-ge v1, v2, :cond_21
.line 5
aget-object v2, p1, v1
const-string v4, "vid="
invoke-virtual {v2, v4}, Ljava/lang/String;->startsWith(Ljava/lang/String;)Z
move-result v2
if-eqz v2, :cond_1e
.line 6
aget-object p1, p1, v1
invoke-virtual {p1, v4, v3}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object p1
goto :goto_22
:cond_1e
add-int/lit8 v1, v1, 0x1
goto :goto_8
:cond_21
move-object p1, v3
.line 7
:goto_22
invoke-static {p1}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z
move-result v1
if-eqz v1, :cond_29
return-object v3
:cond_29
const/4 v1, 0x1
.line 8
new-array v1, v1, [Ljava/lang/Object;
aput-object p1, v1, v0
const-string p1, "http://m.le.com/vplay_%s.html"
invoke-static {p1, v1}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
move-result-object p1
return-object p1
.end method
.method private c(Ljava/lang/String;)Ljava/lang/String;
.registers 7
const-string v0, "&"
.line 7
invoke-virtual {p1, v0}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;
move-result-object p1
const/4 v0, 0x0
const/4 v1, 0x0
.line 8
:goto_8
array-length v2, p1
const-string v3, ""
if-ge v1, v2, :cond_21
.line 9
aget-object v2, p1, v1
const-string v4, "showid="
invoke-virtual {v2, v4}, Ljava/lang/String;->startsWith(Ljava/lang/String;)Z
move-result v2
if-eqz v2, :cond_1e
.line 10
aget-object p1, p1, v1
invoke-virtual {p1, v4, v3}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object p1
goto :goto_22
:cond_1e
add-int/lit8 v1, v1, 0x1
goto :goto_8
:cond_21
move-object p1, v3
.line 11
:goto_22
invoke-static {p1}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z
move-result v1
if-eqz v1, :cond_29
return-object v3
:cond_29
const/4 v1, 0x1
.line 12
new-array v1, v1, [Ljava/lang/Object;
aput-object p1, v1, v0
const-string p1, "http://m.youku.com/video/id_%s.html"
invoke-static {p1, v1}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
move-result-object p1
return-object p1
.end method
.method private c()V
.registers 5
.line 2
:try_start_0
new-instance v0, Lcom/qq/e/ads/banner/BannerView;
sget-object v1, Lcom/qq/e/ads/banner/ADSize;->BANNER:Lcom/qq/e/ads/banner/ADSize;
const-string v2, "1107880329"
const-string v3, "9000746335268600"
invoke-direct {v0, p0, v1, v2, v3}, Lcom/qq/e/ads/banner/BannerView;-><init>(Landroid/app/Activity;Lcom/qq/e/ads/banner/ADSize;Ljava/lang/String;Ljava/lang/String;)V
.line 3
iget-object v1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->g:Landroid/widget/RelativeLayout;
invoke-virtual {v1, v0}, Landroid/widget/RelativeLayout;->addView(Landroid/view/View;)V
const/16 v1, 0x1e
.line 4
invoke-virtual {v0, v1}, Lcom/qq/e/ads/banner/BannerView;->setRefresh(I)V
.line 5
invoke-virtual {v0}, Lcom/qq/e/ads/banner/BannerView;->loadAD()V
:try_end_18
.catch Ljava/lang/Exception; {:try_start_0 .. :try_end_18} :catch_19
goto :goto_1d
:catch_19
move-exception v0
.line 6
invoke-virtual {v0}, Ljava/lang/Exception;->printStackTrace()V
:goto_1d
return-void
.end method
.method static synthetic c(Lcom/gongwu/wherecollect/activity/WebActivity;)V
.registers 1
.line 1
invoke-direct {p0}, Lcom/gongwu/wherecollect/activity/WebActivity;->g()V
return-void
.end method
.method private d()V
.registers 3
.line 1
iget-object v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->b:Landroid/support/design/widget/FloatingActionButton;
new-instance v1, Lcom/gongwu/wherecollect/activity/kb;
invoke-direct {v1, p0}, Lcom/gongwu/wherecollect/activity/kb;-><init>(Lcom/gongwu/wherecollect/activity/WebActivity;)V
invoke-virtual {v0, v1}, Landroid/widget/ImageButton;->setOnTouchListener(Landroid/view/View$OnTouchListener;)V
return-void
.end method
.method private e()Z
.registers 2
.line 1
iget-object v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
invoke-virtual {v0}, Lcom/tencent/smtt/sdk/WebView;->canGoBack()Z
move-result v0
if-eqz v0, :cond_f
.line 2
iget-object v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
invoke-virtual {v0}, Lcom/tencent/smtt/sdk/WebView;->goBack()V
const/4 v0, 0x1
return v0
:cond_f
const/4 v0, 0x0
return v0
.end method
.method private f()V
.registers 5
.line 1
iget-object v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
invoke-virtual {v0}, Lcom/tencent/smtt/sdk/WebView;->getUrl()Ljava/lang/String;
move-result-object v0
.line 2
iget-object v1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
invoke-virtual {v1}, Lcom/tencent/smtt/sdk/WebView;->getOriginalUrl()Ljava/lang/String;
.line 3
iget-object v1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
invoke-virtual {v1}, Lcom/tencent/smtt/sdk/WebView;->getUrl()Ljava/lang/String;
move-result-object v1
iget-object v2, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
invoke-virtual {v2}, Lcom/tencent/smtt/sdk/WebView;->getTitle()Ljava/lang/String;
move-result-object v2
const-string v3, "0"
invoke-static {v1, v2, v3}, Lcom/gongwu/wherecollect/util/LookRecordUtil;->saveRecord(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V
const-string v1, "iqiyi.com"
.line 4
invoke-virtual {v0, v1}, Ljava/lang/String;->contains(Ljava/lang/CharSequence;)Z
move-result v1
const-string v2, "//www."
const-string v3, "//m."
if-eqz v1, :cond_2d
.line 5
invoke-virtual {v0, v3, v2}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object v0
goto :goto_5f
:cond_2d
const-string v1, "qq.com"
.line 6
invoke-virtual {v0, v1}, Ljava/lang/String;->contains(Ljava/lang/CharSequence;)Z
move-result v1
if-eqz v1, :cond_3c
const-string v1, "//"
.line 7
invoke-virtual {v0, v3, v1}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object v0
goto :goto_5f
:cond_3c
const-string v1, "youku.com"
.line 8
invoke-virtual {v0, v1}, Ljava/lang/String;->contains(Ljava/lang/CharSequence;)Z
move-result v1
if-eqz v1, :cond_4b
const-string v1, "//."
.line 9
invoke-virtual {v0, v3, v1}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object v0
goto :goto_5f
:cond_4b
const-string v1, "le.com"
.line 10
invoke-virtual {v0, v1}, Ljava/lang/String;->contains(Ljava/lang/CharSequence;)Z
move-result v1
if-eqz v1, :cond_5f
.line 11
invoke-virtual {v0, v3, v2}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object v0
const-string v1, "vplay_"
const-string v2, "ptv/vplay/"
invoke-virtual {v0, v1, v2}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object v0
.line 12
:cond_5f
:goto_5f
iget-object v1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
invoke-virtual {v1}, Lcom/tencent/smtt/sdk/WebView;->getTitle()Ljava/lang/String;
move-result-object v1
const-string v2, ""
invoke-static {p0, v0, v2, v1}, Lcom/gongwu/wherecollect/activity/PlayActivity;->start(Landroid/content/Context;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V
return-void
.end method
.method private g()V
.registers 6
.line 1
iget-object v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
invoke-virtual {v0}, Lcom/tencent/smtt/sdk/WebView;->getUrl()Ljava/lang/String;
move-result-object v0
if-nez v0, :cond_9
return-void
:cond_9
const-string v1, "youku.com"
.line 2
invoke-virtual {v0, v1}, Ljava/lang/String;->contains(Ljava/lang/CharSequence;)Z
move-result v1
if-eqz v1, :cond_21
.line 3
invoke-static {v0}, Lcom/gongwu/wherecollect/util/StringUtils;->hasUpcase(Ljava/lang/String;)Z
move-result v0
if-nez v0, :cond_21
const-string v0, "提醒"
const-string v1, "优酷视频必须先点击一下选集,否则无法解析。电影也有选集哦!"
const-string v2, "我知道了"
.line 4
invoke-static {v0, v1, v2, p0}, Lcom/gongwu/wherecollect/util/DialogUtil;->show(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Landroid/app/Activity;)Landroid/support/v7/app/AlertDialog;
return-void
.line 5
:cond_21
invoke-static {p0}, Lcom/gongwu/wherecollect/util/SaveDate;->getInstence(Landroid/content/Context;)Lcom/gongwu/wherecollect/util/SaveDate;
move-result-object v0
invoke-virtual {v0}, Lcom/gongwu/wherecollect/util/SaveDate;->getLastVideoTime()Ljava/lang/Long;
move-result-object v0
invoke-virtual {v0}, Ljava/lang/Long;->longValue()J
move-result-wide v0
const-wide v2, 0x7fffffffffffffffL
cmp-long v4, v0, v2
if-nez v4, :cond_45
.line 6
invoke-static {p0}, Lcom/gongwu/wherecollect/util/SaveDate;->getInstence(Landroid/content/Context;)Lcom/gongwu/wherecollect/util/SaveDate;
move-result-object v0
invoke-static {}, Ljava/lang/System;->currentTimeMillis()J
move-result-wide v1
invoke-static {v1, v2}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;
move-result-object v1
invoke-virtual {v0, v1}, Lcom/gongwu/wherecollect/util/SaveDate;->setLastVideoTime(Ljava/lang/Long;)V
.line 7
:cond_45
invoke-direct {p0}, Lcom/gongwu/wherecollect/activity/WebActivity;->f()V
return-void
.end method
.method private h()V
.registers 3
.line 1
new-instance v0, Landroid/app/Dialog;
invoke-direct {v0, p0}, Landroid/app/Dialog;-><init>(Landroid/content/Context;)V
const v1, 0x7f0b0065
.line 2
invoke-virtual {v0, v1}, Landroid/app/Dialog;->setContentView(I)V
.line 3
invoke-virtual {v0}, Landroid/app/Dialog;->show()V
return-void
.end method
.method public static start(Landroid/content/Context;Ljava/lang/String;Ljava/lang/String;)V
.registers 5
.line 1
new-instance v0, Landroid/content/Intent;
const-class v1, Lcom/gongwu/wherecollect/activity/WebActivity;
invoke-direct {v0, p0, v1}, Landroid/content/Intent;-><init>(Landroid/content/Context;Ljava/lang/Class;)V
const-string v1, "url"
.line 2
invoke-virtual {v0, v1, p1}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;
const-string p1, "html"
.line 3
invoke-virtual {v0, p1, p2}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;
.line 4
invoke-virtual {p0, v0}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V
return-void
.end method
# virtual methods
.method public dispatchKeyEvent(Landroid/view/KeyEvent;)Z
.registers 3
.line 1
invoke-static {p0}, Lcom/gongwu/wherecollect/util/StringUtils;->isTv(Landroid/content/Context;)Z
move-result v0
if-eqz v0, :cond_17
iget-object v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->k:Lb/b/a/a;
if-eqz v0, :cond_17
.line 2
invoke-virtual {v0, p1}, Lb/b/a/a;->a(Landroid/view/KeyEvent;)Z
move-result v0
if-eqz v0, :cond_12
const/4 p1, 0x1
goto :goto_16
:cond_12
invoke-super {p0, p1}, Landroid/support/v7/app/AppCompatActivity;->dispatchKeyEvent(Landroid/view/KeyEvent;)Z
move-result p1
:goto_16
return p1
.line 3
:cond_17
invoke-super {p0, p1}, Landroid/support/v7/app/AppCompatActivity;->dispatchKeyEvent(Landroid/view/KeyEvent;)Z
move-result p1
return p1
.end method
.method public initMouse()V
.registers 4
.line 1
iget-object v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->k:Lb/b/a/a;
if-nez v0, :cond_1f
.line 2
invoke-static {p0}, Lb/b/a/a;->a(Landroid/content/Context;)Lb/b/a/a;
move-result-object v0
iput-object v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->k:Lb/b/a/a;
.line 3
iget-object v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->k:Lb/b/a/a;
invoke-virtual {p0}, Landroid/app/Activity;->getWindow()Landroid/view/Window;
move-result-object v1
invoke-virtual {v1}, Landroid/view/Window;->getDecorView()Landroid/view/View;
move-result-object v1
iget-object v2, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
invoke-virtual {v0, v1, v2}, Lb/b/a/a;->a(Landroid/view/View;Lcom/tencent/smtt/sdk/WebView;)V
.line 4
iget-object v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->k:Lb/b/a/a;
const/4 v1, 0x1
invoke-virtual {v0, v1}, Lb/b/a/a;->a(Z)V
:cond_1f
return-void
.end method
.method public onBackPressed()V
.registers 6
.line 1
invoke-static {}, Ljava/lang/System;->currentTimeMillis()J
move-result-wide v0
iget-wide v2, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->d:J
sub-long/2addr v0, v2
const-wide/16 v2, 0x7d0
cmp-long v4, v0, v2
if-gez v4, :cond_11
.line 2
invoke-virtual {p0}, Landroid/app/Activity;->finish()V
goto :goto_17
.line 3
:cond_11
invoke-static {}, Ljava/lang/System;->currentTimeMillis()J
move-result-wide v0
iput-wide v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->d:J
.line 4
:goto_17
invoke-direct {p0}, Lcom/gongwu/wherecollect/activity/WebActivity;->e()Z
move-result v0
if-eqz v0, :cond_1e
goto :goto_21
.line 5
:cond_1e
invoke-super {p0}, Landroid/support/v4/app/FragmentActivity;->onBackPressed()V
:goto_21
return-void
.end method
.method public onClick(Landroid/view/View;)V
.registers 4
.line 1
invoke-virtual {p1}, Landroid/view/View;->getId()I
move-result p1
const v0, 0x7f09004d
if-eq p1, v0, :cond_d
const v0, 0x7f0900d2
goto :goto_23
:cond_d
const-string p1, "收藏成功"
.line 2
invoke-static {p0, p1}, Lcom/gongwu/wherecollect/util/ToastUtil;->showTopMsg(Landroid/content/Context;Ljava/lang/String;)V
.line 3
iget-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
invoke-virtual {p1}, Lcom/tencent/smtt/sdk/WebView;->getUrl()Ljava/lang/String;
move-result-object p1
iget-object v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
invoke-virtual {v0}, Lcom/tencent/smtt/sdk/WebView;->getTitle()Ljava/lang/String;
move-result-object v0
const-string v1, "0"
invoke-static {p1, v0, v1}, Lcom/gongwu/wherecollect/util/CollectBeanUtil;->saveCollect(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V
:goto_23
return-void
.end method
.method protected onCreate(Landroid/os/Bundle;)V
.registers 9
.line 1
invoke-super {p0, p1}, Landroid/support/v7/app/AppCompatActivity;->onCreate(Landroid/os/Bundle;)V
const p1, 0x7f0b0033
.line 2
invoke-virtual {p0, p1}, Landroid/support/v7/app/AppCompatActivity;->setContentView(I)V
.line 3
invoke-static {}, Lorg/greenrobot/eventbus/e;->a()Lorg/greenrobot/eventbus/e;
move-result-object p1
invoke-virtual {p1, p0}, Lorg/greenrobot/eventbus/e;->b(Ljava/lang/Object;)V
.line 4
invoke-virtual {p0}, Landroid/app/Activity;->getIntent()Landroid/content/Intent;
move-result-object p1
const-string v0, "url"
invoke-virtual {p1, v0}, Landroid/content/Intent;->getStringExtra(Ljava/lang/String;)Ljava/lang/String;
move-result-object p1
iput-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->h:Ljava/lang/String;
.line 5
invoke-virtual {p0}, Landroid/app/Activity;->getIntent()Landroid/content/Intent;
move-result-object p1
const-string v0, "html"
invoke-virtual {p1, v0}, Landroid/content/Intent;->getStringExtra(Ljava/lang/String;)Ljava/lang/String;
move-result-object p1
iput-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->i:Ljava/lang/String;
.line 6
iget-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->h:Ljava/lang/String;
const-string v0, "iqiyi.com"
invoke-virtual {p1, v0}, Ljava/lang/String;->contains(Ljava/lang/CharSequence;)Z
move-result p1
if-eqz p1, :cond_3c
.line 7
iget-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->h:Ljava/lang/String;
const-string v0, ""
invoke-static {p0, p1, v0}, Lcom/gongwu/wherecollect/activity/NativeWebActivity;->start(Landroid/content/Context;Ljava/lang/String;Ljava/lang/String;)V
.line 8
invoke-virtual {p0}, Landroid/app/Activity;->finish()V
:cond_3c
const p1, 0x7f09018e
.line 9
invoke-virtual {p0, p1}, Landroid/support/v7/app/AppCompatActivity;->findViewById(I)Landroid/view/View;
move-result-object p1
check-cast p1, Landroid/widget/RelativeLayout;
iput-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->f:Landroid/widget/RelativeLayout;
const p1, 0x7f09018c
.line 10
invoke-virtual {p0, p1}, Landroid/support/v7/app/AppCompatActivity;->findViewById(I)Landroid/view/View;
move-result-object p1
check-cast p1, Lcom/tencent/smtt/sdk/WebView;
iput-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
const p1, 0x7f090024
.line 11
invoke-virtual {p0, p1}, Landroid/support/v7/app/AppCompatActivity;->findViewById(I)Landroid/view/View;
move-result-object p1
check-cast p1, Landroid/widget/RelativeLayout;
iput-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->g:Landroid/widget/RelativeLayout;
const p1, 0x7f090183
.line 12
invoke-virtual {p0, p1}, Landroid/support/v7/app/AppCompatActivity;->findViewById(I)Landroid/view/View;
move-result-object p1
check-cast p1, Landroid/view/ViewGroup;
iput-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->a:Landroid/view/ViewGroup;
const p1, 0x7f0900d2
.line 13
invoke-virtual {p0, p1}, Landroid/support/v7/app/AppCompatActivity;->findViewById(I)Landroid/view/View;
move-result-object p1
check-cast p1, Landroid/support/design/widget/FloatingActionButton;
iput-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->b:Landroid/support/design/widget/FloatingActionButton;
const p1, 0x7f09004d
.line 14
invoke-virtual {p0, p1}, Landroid/support/v7/app/AppCompatActivity;->findViewById(I)Landroid/view/View;
move-result-object p1
check-cast p1, Landroid/support/design/widget/FloatingActionButton;
iput-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->c:Landroid/support/design/widget/FloatingActionButton;
.line 15
iget-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->c:Landroid/support/design/widget/FloatingActionButton;
invoke-virtual {p1, p0}, Landroid/widget/ImageButton;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 16
invoke-static {p0}, Lcom/gongwu/wherecollect/util/SaveDate;->getInstence(Landroid/content/Context;)Lcom/gongwu/wherecollect/util/SaveDate;
move-result-object p1
invoke-virtual {p1}, Lcom/gongwu/wherecollect/util/SaveDate;->getClickCount()I
move-result p1
iput p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->j:I
.line 17
iget-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
new-instance v0, Lcom/gongwu/wherecollect/activity/WebActivity$a;
const/4 v1, 0x0
invoke-direct {v0, p0, v1}, Lcom/gongwu/wherecollect/activity/WebActivity$a;-><init>(Lcom/gongwu/wherecollect/activity/WebActivity;Lcom/gongwu/wherecollect/activity/jb;)V
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebView;->setWebViewClient(Lcom/tencent/smtt/sdk/WebViewClient;)V
.line 18
iget-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
invoke-virtual {p1}, Lcom/tencent/smtt/sdk/WebView;->getSettings()Lcom/tencent/smtt/sdk/WebSettings;
move-result-object p1
const/4 v0, 0x1
.line 19
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setJavaScriptEnabled(Z)V
.line 20
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setAllowFileAccess(Z)V
.line 21
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setSupportZoom(Z)V
const/4 v1, 0x0
.line 22
invoke-virtual {p1, v1}, Lcom/tencent/smtt/sdk/WebSettings;->setBuiltInZoomControls(Z)V
.line 23
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setUseWideViewPort(Z)V
.line 24
invoke-virtual {p1, v1}, Lcom/tencent/smtt/sdk/WebSettings;->setSupportMultipleWindows(Z)V
.line 25
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setLoadWithOverviewMode(Z)V
.line 26
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setAppCacheEnabled(Z)V
.line 27
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setDomStorageEnabled(Z)V
.line 28
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setJavaScriptEnabled(Z)V
.line 29
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setGeolocationEnabled(Z)V
.line 30
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setAllowUniversalAccessFromFileURLs(Z)V
.line 31
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setAllowContentAccess(Z)V
.line 32
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setAllowFileAccess(Z)V
.line 33
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setPluginsEnabled(Z)V
const-wide v2, 0x7fffffffffffffffL
.line 34
invoke-virtual {p1, v2, v3}, Lcom/tencent/smtt/sdk/WebSettings;->setAppCacheMaxSize(J)V
.line 35
sget-object v0, Lcom/gongwu/wherecollect/application/MyApplication;->CACHEPATH:Ljava/lang/String;
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setAppCachePath(Ljava/lang/String;)V
.line 36
sget-object v0, Lcom/tencent/smtt/sdk/WebSettings$PluginState;->ON_DEMAND:Lcom/tencent/smtt/sdk/WebSettings$PluginState;
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setPluginState(Lcom/tencent/smtt/sdk/WebSettings$PluginState;)V
.line 37
sget-object v0, Lcom/tencent/smtt/sdk/WebSettings$RenderPriority;->HIGH:Lcom/tencent/smtt/sdk/WebSettings$RenderPriority;
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebSettings;->setRenderPriority(Lcom/tencent/smtt/sdk/WebSettings$RenderPriority;)V
.line 38
iget-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->h:Ljava/lang/String;
invoke-static {p1}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z
move-result p1
if-nez p1, :cond_f3
.line 39
iget-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
iget-object v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->h:Ljava/lang/String;
invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebView;->loadUrl(Ljava/lang/String;)V
.line 40
:cond_f3
invoke-direct {p0}, Lcom/gongwu/wherecollect/activity/WebActivity;->c()V
.line 41
invoke-direct {p0}, Lcom/gongwu/wherecollect/activity/WebActivity;->d()V
.line 42
invoke-virtual {p0}, Landroid/app/Activity;->getApplication()Landroid/app/Application;
move-result-object p1
invoke-static {p1}, Lcom/gongwu/wherecollect/util/SaveDate;->getInstence(Landroid/content/Context;)Lcom/gongwu/wherecollect/util/SaveDate;
move-result-object p1
invoke-virtual {p1}, Lcom/gongwu/wherecollect/util/SaveDate;->isFirstHelp()Z
move-result p1
if-eqz p1, :cond_115
.line 43
invoke-virtual {p0}, Landroid/app/Activity;->getApplication()Landroid/app/Application;
move-result-object p1
invoke-static {p1}, Lcom/gongwu/wherecollect/util/SaveDate;->getInstence(Landroid/content/Context;)Lcom/gongwu/wherecollect/util/SaveDate;
move-result-object p1
invoke-virtual {p1, v1}, Lcom/gongwu/wherecollect/util/SaveDate;->setIsFirstHelp(Z)V
.line 44
invoke-direct {p0}, Lcom/gongwu/wherecollect/activity/WebActivity;->h()V
.line 45
:cond_115
iget-object p1, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
invoke-virtual {p1}, Lcom/tencent/smtt/sdk/WebView;->getX5WebViewExtension()Lcom/tencent/smtt/export/external/extension/interfaces/IX5WebViewExtension;
move-result-object p1
if-nez p1, :cond_12f
.line 46
new-instance v5, Lcom/gongwu/wherecollect/activity/jb;
invoke-direct {v5, p0}, Lcom/gongwu/wherecollect/activity/jb;-><init>(Lcom/gongwu/wherecollect/activity/WebActivity;)V
const/4 v6, 0x0
const-string v0, "提醒"
const-string v1, "加载播放插件失败,可能无法播放或全屏,尝试修复?"
const-string v2, "一键修复"
const-string v3, "取消"
move-object v4, p0
invoke-static/range {v0 .. v6}, Lcom/gongwu/wherecollect/util/DialogUtil;->show(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Landroid/app/Activity;Landroid/content/DialogInterface$OnClickListener;Landroid/content/DialogInterface$OnClickListener;)Landroid/support/v7/app/AlertDialog;
:cond_12f
return-void
.end method
.method protected onDestroy()V
.registers 2
.line 1
invoke-super {p0}, Landroid/support/v7/app/AppCompatActivity;->onDestroy()V
.line 2
:try_start_3
invoke-static {}, Lorg/greenrobot/eventbus/e;->a()Lorg/greenrobot/eventbus/e;
move-result-object v0
invoke-virtual {v0, p0}, Lorg/greenrobot/eventbus/e;->c(Ljava/lang/Object;)V
.line 3
iget-object v0, p0, Lcom/gongwu/wherecollect/activity/WebActivity;->e:Lcom/tencent/smtt/sdk/WebView;
invoke-virtual {v0}, Lcom/tencent/smtt/sdk/WebView;->destroy()V
:try_end_f
.catch Ljava/lang/Exception; {:try_start_3 .. :try_end_f} :catch_10
goto :goto_14
:catch_10
move-exception v0
.line 4
invoke-virtual {v0}, Ljava/lang/Exception;->printStackTrace()V
:goto_14
return-void
.end method
.method public onKeyDown(ILandroid/view/KeyEvent;)Z
.registers 4
const/16 v0, 0x52
if-ne p1, v0, :cond_9
.line 1
invoke-direct {p0}, Lcom/gongwu/wherecollect/activity/WebActivity;->g()V
const/4 p1, 0x1
return p1
.line 2
:cond_9
invoke-super {p0, p1, p2}, Landroid/app/Activity;->onKeyDown(ILandroid/view/KeyEvent;)Z
move-result p1
return p1
.end method
.method public onMessageEvent(Lcom/gongwu/wherecollect/util/EventBusMsg;)V
.registers 5
.annotation runtime Lorg/greenrobot/eventbus/k;
threadMode = .enum Lorg/greenrobot/eventbus/ThreadMode;->MAIN:Lorg/greenrobot/eventbus/ThreadMode;
.end annotation
const-string p1, "加载播放插件成功,2秒后将关闭应用,请手动重启"
const/4 v0, 0x1
.line 1
invoke-static {p0, p1, v0}, Landroid/widget/Toast;->makeText(Landroid/content/Context;Ljava/lang/CharSequence;I)Landroid/widget/Toast;
move-result-object p1
invoke-virtual {p1}, Landroid/widget/Toast;->show()V
.line 2
new-instance p1, Landroid/os/Handler;
invoke-direct {p1}, Landroid/os/Handler;-><init>()V
new-instance v0, Lcom/gongwu/wherecollect/activity/lb;
invoke-direct {v0, p0}, Lcom/gongwu/wherecollect/activity/lb;-><init>(Lcom/gongwu/wherecollect/activity/WebActivity;)V
const-wide/16 v1, 0xbb8
invoke-virtual {p1, v0, v1, v2}, Landroid/os/Handler;->postDelayed(Ljava/lang/Runnable;J)Z
return-void
.end method
.method protected onResume()V
.registers 2
.line 1
invoke-super {p0}, Landroid/support/v4/app/FragmentActivity;->onResume()V
.line 2
invoke-static {p0}, Lcom/gongwu/wherecollect/util/StringUtils;->isTv(Landroid/content/Context;)Z
move-result v0
if-eqz v0, :cond_c
.line 3
invoke-virtual {p0}, Lcom/gongwu/wherecollect/activity/WebActivity;->initMouse()V
:cond_c
return-void
.end method
解决了,不是这个文件,思路有问题啊,该找签名失败的那个
返回两次1
就签名成功,去广告并投屏正常了。{:301_971:} 期待分享成品。谢谢!
页:
[1]