.class Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;
.super Lcom/tencent/smtt/sdk/WebViewClient;
.source "DetailAdapter.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/moji/mjweather/feed/adapter/DetailAdapter;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x2
    name = "MyWebViewClient"
.end annotation


# instance fields
.field final synthetic a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;


# direct methods
.method private constructor <init>(Lcom/moji/mjweather/feed/adapter/DetailAdapter;)V
    .locals 0

    .line 216
    iput-object p1, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-direct {p0}, Lcom/tencent/smtt/sdk/WebViewClient;-><init>()V

    return-void
.end method

.method synthetic constructor <init>(Lcom/moji/mjweather/feed/adapter/DetailAdapter;Lcom/moji/mjweather/feed/adapter/DetailAdapter$1;)V
    .locals 0

    .line 216
    invoke-direct {p0, p1}, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;-><init>(Lcom/moji/mjweather/feed/adapter/DetailAdapter;)V

    return-void
.end method


# virtual methods
.method public onPageFinished(Lcom/tencent/smtt/sdk/WebView;Ljava/lang/String;)V
    .locals 2

    .line 232
    instance-of v0, p1, Lcom/moji/mjweather/feed/view/FeedDetailWebView;

    if-eqz v0, :cond_0

    .line 233
    move-object v0, p1

    check-cast v0, Lcom/moji/mjweather/feed/view/FeedDetailWebView;

    const/4 v1, 0x1

    iput-boolean v1, v0, Lcom/moji/mjweather/feed/view/FeedDetailWebView;->a:Z

    :cond_0
    const-string v0, "appshare=1"

    .line 235
    invoke-virtual {p2, v0}, Ljava/lang/String;->contains(Ljava/lang/CharSequence;)Z

    move-result v0

    if-eqz v0, :cond_1

    const-string v0, "javascript:window.jsObj.setShareContent(null,document.getElementsByTagName(\'title\')[0].innerHTML,null,null,null)"

    .line 236
    invoke-virtual {p1, v0}, Lcom/tencent/smtt/sdk/WebView;->loadUrl(Ljava/lang/String;)V

    .line 242
    :cond_1
    iget-object v0, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-static {v0}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->c(Lcom/moji/mjweather/feed/adapter/DetailAdapter;)Lcom/moji/mjweather/feed/adapter/DetailAdapter$onWebViewLoadFinishedListener;

    move-result-object v0

    if-eqz v0, :cond_2

    .line 243
    iget-object v0, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-static {v0}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->c(Lcom/moji/mjweather/feed/adapter/DetailAdapter;)Lcom/moji/mjweather/feed/adapter/DetailAdapter$onWebViewLoadFinishedListener;

    move-result-object v0

    iget-object v1, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-static {v1}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->d(Lcom/moji/mjweather/feed/adapter/DetailAdapter;)Lcom/moji/http/fdsapi/entity/ShareJS;

    move-result-object v1

    invoke-interface {v0, v1}, Lcom/moji/mjweather/feed/adapter/DetailAdapter$onWebViewLoadFinishedListener;->a(Lcom/moji/http/fdsapi/entity/ShareJS;)V

    .line 245
    :cond_2
    iget-object v0, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-static {v0}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->a(Lcom/moji/mjweather/feed/adapter/DetailAdapter;)Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v0

    if-nez v0, :cond_3

    iget-object v0, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-static {v0}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->a(Lcom/moji/mjweather/feed/adapter/DetailAdapter;)Ljava/lang/String;

    move-result-object v0

    invoke-virtual {p2, v0}, Ljava/lang/String;->contains(Ljava/lang/CharSequence;)Z

    move-result v0

    if-nez v0, :cond_4

    .line 246
    :cond_3
    invoke-static {p1, p2}, Lcom/moji/webview/umeng/UMHybrid;->onPageFinished(Lcom/tencent/smtt/sdk/WebView;Ljava/lang/String;)V

    .line 247
    iget-object p1, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-static {p1, p2}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->b(Lcom/moji/mjweather/feed/adapter/DetailAdapter;Ljava/lang/String;)Ljava/lang/String;

    .line 248
    iget-object p1, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    const/4 p2, 0x0

    invoke-static {p1, p2}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->a(Lcom/moji/mjweather/feed/adapter/DetailAdapter;Ljava/lang/String;)Ljava/lang/String;

    :cond_4
    return-void
.end method

.method public shouldOverrideUrlLoading(Lcom/tencent/smtt/sdk/WebView;Ljava/lang/String;)Z
    .locals 1

    .line 219
    iget-object v0, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-static {v0, p1, p2}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->a(Lcom/moji/mjweather/feed/adapter/DetailAdapter;Lcom/tencent/smtt/sdk/WebView;Ljava/lang/String;)V

    .line 220
    invoke-static {p1, p2}, Lcom/moji/webview/umeng/UMHybrid;->shouldOverrideUrlLoading(Lcom/tencent/smtt/sdk/WebView;Ljava/lang/String;)V

    .line 221
    iget-object p1, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-static {p1}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->a(Lcom/moji/mjweather/feed/adapter/DetailAdapter;)Ljava/lang/String;

    move-result-object p1

    invoke-static {p1}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result p1

    if-nez p1, :cond_1

    iget-object p1, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-static {p1}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->a(Lcom/moji/mjweather/feed/adapter/DetailAdapter;)Ljava/lang/String;

    move-result-object p1

    invoke-virtual {p2, p1}, Ljava/lang/String;->contains(Ljava/lang/CharSequence;)Z

    move-result p1

    if-nez p1, :cond_1

    const-string p1, "http"

    invoke-virtual {p2, p1}, Ljava/lang/String;->startsWith(Ljava/lang/String;)Z

    move-result p1

    if-eqz p1, :cond_1

    .line 222
    iget-object p1, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-static {p1}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->b(Lcom/moji/mjweather/feed/adapter/DetailAdapter;)Ljava/lang/String;

    move-result-object p1

    invoke-static {p1}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result p1

    if-nez p1, :cond_0

    iget-object p1, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-static {p1}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->b(Lcom/moji/mjweather/feed/adapter/DetailAdapter;)Ljava/lang/String;

    move-result-object p1

    iget-object p2, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-static {p2}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->a(Lcom/moji/mjweather/feed/adapter/DetailAdapter;)Ljava/lang/String;

    move-result-object p2

    invoke-virtual {p1, p2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result p1

    if-nez p1, :cond_1

    .line 223
    :cond_0
    iget-object p1, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-static {p1}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->a(Lcom/moji/mjweather/feed/adapter/DetailAdapter;)Ljava/lang/String;

    move-result-object p1

    invoke-static {p1}, Lcom/moji/webview/umeng/UMHybrid;->onPageChanged(Ljava/lang/String;)V

    .line 224
    iget-object p1, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    iget-object p2, p0, Lcom/moji/mjweather/feed/adapter/DetailAdapter$MyWebViewClient;->a:Lcom/moji/mjweather/feed/adapter/DetailAdapter;

    invoke-static {p2}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->a(Lcom/moji/mjweather/feed/adapter/DetailAdapter;)Ljava/lang/String;

    move-result-object p2

    invoke-static {p1, p2}, Lcom/moji/mjweather/feed/adapter/DetailAdapter;->a(Lcom/moji/mjweather/feed/adapter/DetailAdapter;Ljava/lang/String;)Ljava/lang/String;

    :cond_1
    const/4 p1, 0x1

    return p1
.end method
