288 lines
8.7 KiB
Smali
288 lines
8.7 KiB
Smali
.class public Lcom/moji/mjweather/me/presenter/AccountPresenter;
|
|
.super Lcom/moji/mjweather/me/presenter/LoginPresenter;
|
|
.source "AccountPresenter.java"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"Lcom/moji/mjweather/me/presenter/LoginPresenter<",
|
|
"Lcom/moji/mjweather/me/view/IMeTabHeadView;",
|
|
">;"
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field private static final d:Ljava/lang/String; = "AccountPresenter"
|
|
|
|
|
|
# instance fields
|
|
.field a:Lcom/moji/preferences/AccountPrefer;
|
|
|
|
.field b:Lcom/moji/preferences/ProcessPrefer;
|
|
|
|
|
|
# direct methods
|
|
.method static constructor <clinit>()V
|
|
.locals 0
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(Lcom/moji/mjweather/me/view/IMeTabHeadView;)V
|
|
.locals 0
|
|
|
|
.line 29
|
|
invoke-direct {p0, p1}, Lcom/moji/mjweather/me/presenter/LoginPresenter;-><init>(Lcom/moji/mjweather/me/view/ILoginView;)V
|
|
|
|
.line 30
|
|
invoke-static {}, Lcom/moji/preferences/AccountPrefer;->c()Lcom/moji/preferences/AccountPrefer;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->a:Lcom/moji/preferences/AccountPrefer;
|
|
|
|
.line 31
|
|
new-instance p1, Lcom/moji/preferences/ProcessPrefer;
|
|
|
|
invoke-direct {p1}, Lcom/moji/preferences/ProcessPrefer;-><init>()V
|
|
|
|
iput-object p1, p0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->b:Lcom/moji/preferences/ProcessPrefer;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method static synthetic a(Lcom/moji/mjweather/me/presenter/AccountPresenter;)Lcom/moji/mvpframe/IMJMvpView;
|
|
.locals 0
|
|
|
|
.line 19
|
|
iget-object p0, p0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->f:Lcom/moji/mvpframe/IMJMvpView;
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method private a(ILjava/lang/String;Ljava/lang/String;)V
|
|
.locals 2
|
|
|
|
.line 71
|
|
iget-object v0, p0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->f:Lcom/moji/mvpframe/IMJMvpView;
|
|
|
|
check-cast v0, Lcom/moji/mjweather/me/view/IMeTabHeadView;
|
|
|
|
invoke-interface {v0}, Lcom/moji/mjweather/me/view/IMeTabHeadView;->showLoading()V
|
|
|
|
.line 73
|
|
iget-object v0, p0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->e:Ljava/lang/Object;
|
|
|
|
check-cast v0, Lcom/moji/mjweather/me/AccountApi;
|
|
|
|
new-instance v1, Lcom/moji/mjweather/me/presenter/AccountPresenter$1;
|
|
|
|
invoke-direct {v1, p0, p0}, Lcom/moji/mjweather/me/presenter/AccountPresenter$1;-><init>(Lcom/moji/mjweather/me/presenter/AccountPresenter;Lcom/moji/mvpframe/BasePresenter;)V
|
|
|
|
invoke-virtual {v0, p1, p2, p3, v1}, Lcom/moji/mjweather/me/AccountApi;->a(ILjava/lang/String;Ljava/lang/String;Lcom/moji/requestcore/MJHttpCallback;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private a(Lcom/moji/account/data/UserInfo;)V
|
|
.locals 1
|
|
|
|
.line 87
|
|
iget-object v0, p0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->c:Lcom/moji/account/data/UserInfoSQLiteManager;
|
|
|
|
invoke-virtual {v0, p1}, Lcom/moji/account/data/UserInfoSQLiteManager;->a(Lcom/moji/account/data/UserInfo;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method static synthetic a(Lcom/moji/mjweather/me/presenter/AccountPresenter;Lcom/moji/account/data/UserInfo;)V
|
|
.locals 0
|
|
|
|
.line 19
|
|
invoke-direct {p0, p1}, Lcom/moji/mjweather/me/presenter/AccountPresenter;->a(Lcom/moji/account/data/UserInfo;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method static synthetic b(Lcom/moji/mjweather/me/presenter/AccountPresenter;)Lcom/moji/mvpframe/IMJMvpView;
|
|
.locals 0
|
|
|
|
.line 19
|
|
iget-object p0, p0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->f:Lcom/moji/mvpframe/IMJMvpView;
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method static synthetic f()Ljava/lang/String;
|
|
.locals 1
|
|
|
|
.line 19
|
|
sget-object v0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->d:Ljava/lang/String;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method a(Lcom/moji/http/ugc/bean/account/UserInfoEntity;)Lcom/moji/account/data/UserInfo;
|
|
.locals 0
|
|
|
|
.line 36
|
|
invoke-static {p1}, Lcom/moji/mjweather/me/AccountUtils;->a(Lcom/moji/http/ugc/bean/account/UserInfoEntity;)Lcom/moji/account/data/UserInfo;
|
|
|
|
move-result-object p1
|
|
|
|
return-object p1
|
|
.end method
|
|
|
|
.method public a(Lcom/moji/http/ugc/bean/account/LoginParams;)V
|
|
.locals 3
|
|
|
|
.line 40
|
|
iget-object v0, p0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->f:Lcom/moji/mvpframe/IMJMvpView;
|
|
|
|
check-cast v0, Lcom/moji/mjweather/me/view/IMeTabHeadView;
|
|
|
|
invoke-interface {v0}, Lcom/moji/mjweather/me/view/IMeTabHeadView;->showLoading()V
|
|
|
|
.line 42
|
|
iget-object v0, p1, Lcom/moji/http/ugc/bean/account/LoginParams;->c:Ljava/lang/String;
|
|
|
|
invoke-virtual {p0, v0}, Lcom/moji/mjweather/me/presenter/AccountPresenter;->c(Ljava/lang/String;)Ljava/lang/String;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p1, Lcom/moji/http/ugc/bean/account/LoginParams;->c:Ljava/lang/String;
|
|
|
|
.line 43
|
|
sget-object v0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->d:Ljava/lang/String;
|
|
|
|
invoke-virtual {p1}, Lcom/moji/http/ugc/bean/account/LoginParams;->toString()Ljava/lang/String;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-static {v0, v1}, Lcom/moji/tool/log/MJLogger;->c(Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
.line 44
|
|
iget-object v0, p0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->e:Ljava/lang/Object;
|
|
|
|
check-cast v0, Lcom/moji/mjweather/me/AccountApi;
|
|
|
|
iget v1, p1, Lcom/moji/http/ugc/bean/account/LoginParams;->d:I
|
|
|
|
const/4 v2, 0x1
|
|
|
|
invoke-virtual {p0, v2, v1}, Lcom/moji/mjweather/me/presenter/AccountPresenter;->a(ZI)Lcom/moji/requestcore/MJBaseHttpCallback;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v0, p1, v1}, Lcom/moji/mjweather/me/AccountApi;->a(Lcom/moji/http/ugc/bean/account/LoginParams;Lcom/moji/requestcore/MJBaseHttpCallback;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method protected synthetic b()Ljava/lang/Object;
|
|
.locals 1
|
|
|
|
.line 19
|
|
invoke-virtual {p0}, Lcom/moji/mjweather/me/presenter/AccountPresenter;->d()Lcom/moji/mjweather/me/AccountApi;
|
|
|
|
move-result-object v0
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method protected d()Lcom/moji/mjweather/me/AccountApi;
|
|
.locals 1
|
|
|
|
.line 49
|
|
new-instance v0, Lcom/moji/mjweather/me/AccountApi;
|
|
|
|
invoke-direct {v0}, Lcom/moji/mjweather/me/AccountApi;-><init>()V
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method public m_()V
|
|
.locals 3
|
|
|
|
.line 53
|
|
invoke-static {}, Lcom/moji/account/data/AccountProvider;->a()Lcom/moji/account/data/AccountProvider;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0}, Lcom/moji/account/data/AccountProvider;->f()Z
|
|
|
|
move-result v0
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
.line 54
|
|
iget-object v0, p0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->f:Lcom/moji/mvpframe/IMJMvpView;
|
|
|
|
check-cast v0, Lcom/moji/mjweather/me/view/IMeTabHeadView;
|
|
|
|
invoke-interface {v0}, Lcom/moji/mjweather/me/view/IMeTabHeadView;->showOffLineView()V
|
|
|
|
goto :goto_0
|
|
|
|
.line 56
|
|
:cond_0
|
|
iget-object v0, p0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->b:Lcom/moji/preferences/ProcessPrefer;
|
|
|
|
invoke-virtual {v0}, Lcom/moji/preferences/ProcessPrefer;->j()Ljava/lang/String;
|
|
|
|
move-result-object v0
|
|
|
|
.line 57
|
|
iget-object v1, p0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->c:Lcom/moji/account/data/UserInfoSQLiteManager;
|
|
|
|
invoke-virtual {v1, v0}, Lcom/moji/account/data/UserInfoSQLiteManager;->a(Ljava/lang/String;)Lcom/moji/account/data/UserInfo;
|
|
|
|
move-result-object v0
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
.line 59
|
|
iget-object v1, p0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->f:Lcom/moji/mvpframe/IMJMvpView;
|
|
|
|
check-cast v1, Lcom/moji/mjweather/me/view/IMeTabHeadView;
|
|
|
|
invoke-interface {v1, v0}, Lcom/moji/mjweather/me/view/IMeTabHeadView;->fillUserHeadInfo(Lcom/moji/account/data/UserInfo;)V
|
|
|
|
.line 60
|
|
sget-object v0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->d:Ljava/lang/String;
|
|
|
|
const-string v1, "\u672c\u5730\u5df2\u7ecf\u6709\u7528\u6237\u6570\u636e\u4e86"
|
|
|
|
invoke-static {v0, v1}, Lcom/moji/tool/log/MJLogger;->c(Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
goto :goto_0
|
|
|
|
.line 62
|
|
:cond_1
|
|
sget-object v0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->d:Ljava/lang/String;
|
|
|
|
const-string v1, "\u672c\u5730\u65e0\u7528\u6237\u6570\u636e \u4ece\u7f51\u7edc\u83b7\u53d6"
|
|
|
|
invoke-static {v0, v1}, Lcom/moji/tool/log/MJLogger;->c(Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
const/4 v0, 0x1
|
|
|
|
const-string v1, ""
|
|
|
|
.line 63
|
|
iget-object v2, p0, Lcom/moji/mjweather/me/presenter/AccountPresenter;->b:Lcom/moji/preferences/ProcessPrefer;
|
|
|
|
invoke-virtual {v2}, Lcom/moji/preferences/ProcessPrefer;->i()Ljava/lang/String;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-direct {p0, v0, v1, v2}, Lcom/moji/mjweather/me/presenter/AccountPresenter;->a(ILjava/lang/String;Ljava/lang/String;)V
|
|
|
|
:goto_0
|
|
return-void
|
|
.end method
|