今奥全景相机
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

940 lines
24 KiB

.class public Lcom/viatech/update/UpgradeDeviceActivity;
.super Landroid/app/Activity;
.source "UpgradeDeviceActivity.java"
# static fields
.field public static final ACTION_CHNAGELOG:Ljava/lang/String; = "upgrade_change_log"
.field public static final ACTION_VERSION:Ljava/lang/String; = "curent_version"
.field public static final DIALOG_DISMISS_TIMEOUT:I = 0x9c4
.field public static final MSG_CLOSE_DLG:I = 0x3f1
.field public static final MSG_REBOOT_TIMEOUT:I = 0x3f0
.field public static final MSG_SEND_FAIL:I = 0x3eb
.field public static final MSG_SEND_FINISH:I = 0x3ea
.field public static final MSG_SEND_PERCENT:I = 0x3ec
.field public static final MSG_SEND_START:I = 0x3e9
.field public static final MSG_START_SHOW_DLG:I = 0x3e8
.field public static final MSG_TIMEOUT:I = 0x3ef
.field public static final MSG_UPGRADE_FAILED:I = 0x3f2
.field public static final MSG_UPGRADE_PERCENT:I = 0x3ed
.field public static final MSG_UPGRADE_USB:I = 0x3ee
.field public static final STATUS_FAILED:I = 0x6
.field public static final STATUS_SENDING:I = 0x1
.field public static final STATUS_SENT:I = 0x2
.field public static final STATUS_START:I = 0x0
.field public static final STATUS_SUCCESS:I = 0x5
.field public static final STATUS_UPGRADED:I = 0x4
.field public static final STATUS_UPGRADING:I = 0x3
.field private static final TAG:Ljava/lang/String; = "Vpai_Upgrade"
.field public static final UPGRADE_TIMEOUT:I = 0x186a0
.field public static sUpdateManager:Lcom/viatech/update/UpdateManager;
# instance fields
.field private mChangelLogView:Landroid/widget/TextView;
.field private mContext:Landroid/content/Context;
.field private mCurVersion:I
.field private mDeviceFilter:Ljava/util/ArrayList;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/util/ArrayList",
"<[I>;"
}
.end annotation
.end field
.field private mFileLength:I
.field private mHandler:Landroid/os/Handler;
.field private mIsUSBCamera:Z
.field private mIsVisProgrees:Z
.field private mNoteView:Landroid/widget/TextView;
.field private mPercent:I
.field private mPercentView:Landroid/widget/TextView;
.field private mProgressBar:Landroid/widget/ProgressBar;
.field private mProgressInterval:I
.field private mProgressWait:Landroid/widget/ProgressBar;
.field private final mReceiver:Landroid/content/BroadcastReceiver;
.field private mUpdateManager:Lcom/viatech/update/UpdateManager;
.field private mUpgradeStatus:I
.field private mWaitRebootDialog:Landroid/app/ProgressDialog;
# direct methods
.method public constructor <init>()V
.locals 2
.prologue
const/4 v1, 0x0
.line 40
invoke-direct {p0}, Landroid/app/Activity;-><init>()V
.line 64
iput v1, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mUpgradeStatus:I
.line 86
iput v1, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mPercent:I
.line 87
iput v1, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mCurVersion:I
.line 88
iput v1, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mFileLength:I
.line 89
const/16 v0, 0x190
iput v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mProgressInterval:I
.line 90
iput-boolean v1, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mIsUSBCamera:Z
.line 91
iput-boolean v1, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mIsVisProgrees:Z
.line 94
new-instance v0, Ljava/util/ArrayList;
invoke-direct {v0}, Ljava/util/ArrayList;-><init>()V
iput-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mDeviceFilter:Ljava/util/ArrayList;
.line 170
new-instance v0, Lcom/viatech/update/UpgradeDeviceActivity$1;
invoke-direct {v0, p0}, Lcom/viatech/update/UpgradeDeviceActivity$1;-><init>(Lcom/viatech/update/UpgradeDeviceActivity;)V
iput-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mReceiver:Landroid/content/BroadcastReceiver;
.line 228
new-instance v0, Lcom/viatech/update/UpgradeDeviceActivity$2;
invoke-direct {v0, p0}, Lcom/viatech/update/UpgradeDeviceActivity$2;-><init>(Lcom/viatech/update/UpgradeDeviceActivity;)V
iput-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mHandler:Landroid/os/Handler;
return-void
.end method
.method static synthetic access$000(Lcom/viatech/update/UpgradeDeviceActivity;)Z
.locals 1
.prologue
.line 40
iget-boolean v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mIsUSBCamera:Z
return v0
.end method
.method static synthetic access$100(Lcom/viatech/update/UpgradeDeviceActivity;)Ljava/util/ArrayList;
.locals 1
.prologue
.line 40
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mDeviceFilter:Ljava/util/ArrayList;
return-object v0
.end method
.method static synthetic access$1000(Lcom/viatech/update/UpgradeDeviceActivity;)Lcom/viatech/update/UpdateManager;
.locals 1
.prologue
.line 40
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mUpdateManager:Lcom/viatech/update/UpdateManager;
return-object v0
.end method
.method static synthetic access$1100(Lcom/viatech/update/UpgradeDeviceActivity;)I
.locals 1
.prologue
.line 40
iget v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mFileLength:I
return v0
.end method
.method static synthetic access$1102(Lcom/viatech/update/UpgradeDeviceActivity;I)I
.locals 0
.prologue
.line 40
iput p1, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mFileLength:I
return p1
.end method
.method static synthetic access$1200(Lcom/viatech/update/UpgradeDeviceActivity;)I
.locals 1
.prologue
.line 40
iget v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mCurVersion:I
return v0
.end method
.method static synthetic access$1300(Lcom/viatech/update/UpgradeDeviceActivity;)I
.locals 1
.prologue
.line 40
iget v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mProgressInterval:I
return v0
.end method
.method static synthetic access$1302(Lcom/viatech/update/UpgradeDeviceActivity;I)I
.locals 0
.prologue
.line 40
iput p1, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mProgressInterval:I
return p1
.end method
.method static synthetic access$1400(Lcom/viatech/update/UpgradeDeviceActivity;)Landroid/widget/ProgressBar;
.locals 1
.prologue
.line 40
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mProgressWait:Landroid/widget/ProgressBar;
return-object v0
.end method
.method static synthetic access$1500(Lcom/viatech/update/UpgradeDeviceActivity;)Landroid/widget/TextView;
.locals 1
.prologue
.line 40
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mChangelLogView:Landroid/widget/TextView;
return-object v0
.end method
.method static synthetic access$200(Lcom/viatech/update/UpgradeDeviceActivity;)I
.locals 1
.prologue
.line 40
iget v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mUpgradeStatus:I
return v0
.end method
.method static synthetic access$202(Lcom/viatech/update/UpgradeDeviceActivity;I)I
.locals 0
.prologue
.line 40
iput p1, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mUpgradeStatus:I
return p1
.end method
.method static synthetic access$300(Lcom/viatech/update/UpgradeDeviceActivity;)Landroid/os/Handler;
.locals 1
.prologue
.line 40
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mHandler:Landroid/os/Handler;
return-object v0
.end method
.method static synthetic access$400(Lcom/viatech/update/UpgradeDeviceActivity;)I
.locals 1
.prologue
.line 40
iget v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mPercent:I
return v0
.end method
.method static synthetic access$402(Lcom/viatech/update/UpgradeDeviceActivity;I)I
.locals 0
.prologue
.line 40
iput p1, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mPercent:I
return p1
.end method
.method static synthetic access$408(Lcom/viatech/update/UpgradeDeviceActivity;)I
.locals 2
.prologue
.line 40
iget v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mPercent:I
add-int/lit8 v1, v0, 0x1
iput v1, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mPercent:I
return v0
.end method
.method static synthetic access$500(Lcom/viatech/update/UpgradeDeviceActivity;)Landroid/widget/ProgressBar;
.locals 1
.prologue
.line 40
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mProgressBar:Landroid/widget/ProgressBar;
return-object v0
.end method
.method static synthetic access$600(Lcom/viatech/update/UpgradeDeviceActivity;)Landroid/widget/TextView;
.locals 1
.prologue
.line 40
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mPercentView:Landroid/widget/TextView;
return-object v0
.end method
.method static synthetic access$700(Lcom/viatech/update/UpgradeDeviceActivity;)Landroid/widget/TextView;
.locals 1
.prologue
.line 40
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mNoteView:Landroid/widget/TextView;
return-object v0
.end method
.method static synthetic access$800(Lcom/viatech/update/UpgradeDeviceActivity;)Landroid/app/ProgressDialog;
.locals 1
.prologue
.line 40
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mWaitRebootDialog:Landroid/app/ProgressDialog;
return-object v0
.end method
.method static synthetic access$900(Lcom/viatech/update/UpgradeDeviceActivity;)Z
.locals 1
.prologue
.line 40
iget-boolean v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mIsVisProgrees:Z
return v0
.end method
.method static synthetic access$902(Lcom/viatech/update/UpgradeDeviceActivity;Z)Z
.locals 0
.prologue
.line 40
iput-boolean p1, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mIsVisProgrees:Z
return p1
.end method
# virtual methods
.method public closeUpgrade()V
.locals 2
.prologue
const/4 v1, 0x0
.line 577
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mUpdateManager:Lcom/viatech/update/UpdateManager;
invoke-virtual {v0, v1}, Lcom/viatech/update/UpdateManager;->setUpgradeHandler(Landroid/os/Handler;)V
.line 578
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mUpdateManager:Lcom/viatech/update/UpdateManager;
invoke-virtual {v0}, Lcom/viatech/update/UpdateManager;->stopUpgradeDevice()V
.line 579
iput-object v1, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mUpdateManager:Lcom/viatech/update/UpdateManager;
.line 580
return-void
.end method
.method public createUpgradeTCPServer()V
.locals 2
.prologue
.line 583
const-string v0, "Vpai_Upgrade"
const-string v1, ">>> createUpgradeTCPServer"
invoke-static {v0, v1}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I
.line 584
new-instance v0, Ljava/lang/Thread;
new-instance v1, Lcom/viatech/update/UpgradeDeviceActivity$3;
invoke-direct {v1, p0}, Lcom/viatech/update/UpgradeDeviceActivity$3;-><init>(Lcom/viatech/update/UpgradeDeviceActivity;)V
invoke-direct {v0, v1}, Ljava/lang/Thread;-><init>(Ljava/lang/Runnable;)V
.line 639
invoke-virtual {v0}, Ljava/lang/Thread;->start()V
.line 640
return-void
.end method
.method public onBackPressed()V
.locals 2
.prologue
.line 550
iget v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mUpgradeStatus:I
const/4 v1, 0x6
if-ne v0, v1, :cond_0
.line 551
invoke-virtual {p0}, Lcom/viatech/update/UpgradeDeviceActivity;->closeUpgrade()V
.line 552
invoke-virtual {p0}, Lcom/viatech/update/UpgradeDeviceActivity;->finish()V
.line 554
:cond_0
return-void
.end method
.method protected onCreate(Landroid/os/Bundle;)V
.locals 10
.prologue
const/4 v9, 0x2
const/4 v8, 0x1
const/4 v1, 0x0
.line 98
invoke-super {p0, p1}, Landroid/app/Activity;->onCreate(Landroid/os/Bundle;)V
.line 99
sget-object v0, Lcom/viatech/update/UpgradeDeviceActivity;->sUpdateManager:Lcom/viatech/update/UpdateManager;
iput-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mUpdateManager:Lcom/viatech/update/UpdateManager;
.line 100
invoke-virtual {p0}, Lcom/viatech/update/UpgradeDeviceActivity;->getWindow()Landroid/view/Window;
move-result-object v0
const/16 v2, 0x80
invoke-virtual {v0, v2}, Landroid/view/Window;->addFlags(I)V
.line 101
const v0, 0x7f030034
invoke-virtual {p0, v0}, Lcom/viatech/update/UpgradeDeviceActivity;->setContentView(I)V
.line 102
invoke-static {}, Lcom/viatech/Config;->a()Lcom/viatech/Config;
move-result-object v0
invoke-virtual {v0, p0}, Lcom/viatech/Config;->a(Landroid/app/Activity;)V
.line 104
iput-object p0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mContext:Landroid/content/Context;
.line 105
invoke-virtual {p0}, Lcom/viatech/update/UpgradeDeviceActivity;->getIntent()Landroid/content/Intent;
move-result-object v0
.line 106
const-string v2, "curent_version"
invoke-virtual {v0, v2, v1}, Landroid/content/Intent;->getIntExtra(Ljava/lang/String;I)I
move-result v0
iput v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mCurVersion:I
.line 107
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mUpdateManager:Lcom/viatech/update/UpdateManager;
invoke-virtual {v0}, Lcom/viatech/update/UpdateManager;->getVpaiDevice()Lcom/viatech/device/VPaiDevice;
move-result-object v0
invoke-virtual {v0}, Lcom/viatech/device/VPaiDevice;->isUSBDevice()Z
move-result v0
iput-boolean v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mIsUSBCamera:Z
.line 109
const v0, 0x7f0c012b
invoke-virtual {p0, v0}, Lcom/viatech/update/UpgradeDeviceActivity;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/TextView;
iput-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mChangelLogView:Landroid/widget/TextView;
.line 110
const v0, 0x7f0c012d
invoke-virtual {p0, v0}, Lcom/viatech/update/UpgradeDeviceActivity;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/TextView;
iput-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mNoteView:Landroid/widget/TextView;
.line 111
const v0, 0x7f0c012c
invoke-virtual {p0, v0}, Lcom/viatech/update/UpgradeDeviceActivity;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/TextView;
iput-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mPercentView:Landroid/widget/TextView;
.line 112
const v0, 0x7f0c012e
invoke-virtual {p0, v0}, Lcom/viatech/update/UpgradeDeviceActivity;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/ProgressBar;
iput-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mProgressBar:Landroid/widget/ProgressBar;
.line 113
const v0, 0x7f0c012f
invoke-virtual {p0, v0}, Lcom/viatech/update/UpgradeDeviceActivity;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/ProgressBar;
iput-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mProgressWait:Landroid/widget/ProgressBar;
.line 115
iget-object v2, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mChangelLogView:Landroid/widget/TextView;
iget-boolean v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mIsUSBCamera:Z
if-eqz v0, :cond_1
const v0, 0x7f07011f
:goto_0
invoke-virtual {v2, v0}, Landroid/widget/TextView;->setText(I)V
.line 116
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mChangelLogView:Landroid/widget/TextView;
const/high16 v2, -0x10000
invoke-virtual {v0, v2}, Landroid/widget/TextView;->setTextColor(I)V
.line 117
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mProgressBar:Landroid/widget/ProgressBar;
const/16 v2, 0x64
invoke-virtual {v0, v2}, Landroid/widget/ProgressBar;->setMax(I)V
.line 118
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mProgressWait:Landroid/widget/ProgressBar;
const/16 v2, 0x8
invoke-virtual {v0, v2}, Landroid/widget/ProgressBar;->setVisibility(I)V
.line 119
new-instance v0, Landroid/app/ProgressDialog;
invoke-direct {v0, p0, v9}, Landroid/app/ProgressDialog;-><init>(Landroid/content/Context;I)V
iput-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mWaitRebootDialog:Landroid/app/ProgressDialog;
.line 120
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mWaitRebootDialog:Landroid/app/ProgressDialog;
const v2, 0x7f07011d
invoke-virtual {p0, v2}, Lcom/viatech/update/UpgradeDeviceActivity;->getString(I)Ljava/lang/String;
move-result-object v2
invoke-virtual {v0, v2}, Landroid/app/ProgressDialog;->setMessage(Ljava/lang/CharSequence;)V
.line 121
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mWaitRebootDialog:Landroid/app/ProgressDialog;
invoke-virtual {v0, v1}, Landroid/app/ProgressDialog;->setCancelable(Z)V
.line 123
invoke-virtual {p0}, Lcom/viatech/update/UpgradeDeviceActivity;->getResources()Landroid/content/res/Resources;
move-result-object v0
const/high16 v2, 0x7f050000
invoke-virtual {v0, v2}, Landroid/content/res/Resources;->getXml(I)Landroid/content/res/XmlResourceParser;
move-result-object v2
.line 126
:try_start_0
invoke-interface {v2}, Landroid/content/res/XmlResourceParser;->getEventType()I
move-result v0
.line 127
:goto_1
if-eq v0, v8, :cond_3
.line 128
invoke-interface {v2}, Landroid/content/res/XmlResourceParser;->getName()Ljava/lang/String;
move-result-object v0
.line 129
const-string v3, "usb-device"
invoke-virtual {v3, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v0
if-eqz v0, :cond_5
.line 130
invoke-interface {v2}, Landroid/content/res/XmlResourceParser;->getEventType()I
move-result v0
if-ne v0, v9, :cond_5
.line 131
const/4 v0, 0x2
new-array v3, v0, [I
.line 132
invoke-interface {v2}, Landroid/content/res/XmlResourceParser;->getAttributeCount()I
move-result v4
move v0, v1
.line 133
:goto_2
if-ge v0, v4, :cond_4
.line 134
invoke-interface {v2, v0}, Landroid/content/res/XmlResourceParser;->getAttributeName(I)Ljava/lang/String;
move-result-object v5
.line 135
invoke-interface {v2, v0}, Landroid/content/res/XmlResourceParser;->getAttributeValue(I)Ljava/lang/String;
move-result-object v6
invoke-static {v6}, Ljava/lang/Integer;->parseInt(Ljava/lang/String;)I
move-result v6
.line 136
const-string v7, "vendor-id"
invoke-virtual {v7, v5}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v7
if-eqz v7, :cond_2
.line 137
const/4 v5, 0x0
aput v6, v3, v5
.line 133
:cond_0
:goto_3
add-int/lit8 v0, v0, 0x1
goto :goto_2
.line 115
:cond_1
const v0, 0x7f07011c
goto :goto_0
.line 138
:cond_2
const-string v7, "product-id"
invoke-virtual {v7, v5}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v5
if-eqz v5, :cond_0
.line 139
const/4 v5, 0x1
aput v6, v3, v5
:try_end_0
.catch Lorg/xmlpull/v1/XmlPullParserException; {:try_start_0 .. :try_end_0} :catch_0
.catch Ljava/io/IOException; {:try_start_0 .. :try_end_0} :catch_1
goto :goto_3
.line 146
:catch_0
move-exception v0
.line 147
invoke-virtual {v0}, Lorg/xmlpull/v1/XmlPullParserException;->printStackTrace()V
.line 151
:cond_3
:goto_4
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mDeviceFilter:Ljava/util/ArrayList;
invoke-virtual {v0}, Ljava/util/ArrayList;->size()I
move-result v0
if-lez v0, :cond_6
.line 152
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mDeviceFilter:Ljava/util/ArrayList;
invoke-virtual {v0}, Ljava/util/ArrayList;->iterator()Ljava/util/Iterator;
move-result-object v2
:goto_5
invoke-interface {v2}, Ljava/util/Iterator;->hasNext()Z
move-result v0
if-eqz v0, :cond_7
invoke-interface {v2}, Ljava/util/Iterator;->next()Ljava/lang/Object;
move-result-object v0
check-cast v0, [I
.line 153
const-string v3, "Vpai_Upgrade"
new-instance v4, Ljava/lang/StringBuilder;
invoke-direct {v4}, Ljava/lang/StringBuilder;-><init>()V
const-string v5, "## onCreate, dump usbDevice filters: "
invoke-virtual {v4, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v4
aget v5, v0, v1
invoke-virtual {v4, v5}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;
move-result-object v4
const-string v5, ", "
invoke-virtual {v4, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v4
aget v0, v0, v8
invoke-virtual {v4, v0}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;
move-result-object v0
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v0
invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I
goto :goto_5
.line 142
:cond_4
:try_start_1
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mDeviceFilter:Ljava/util/ArrayList;
invoke-virtual {v0, v3}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z
.line 144
:cond_5
invoke-interface {v2}, Landroid/content/res/XmlResourceParser;->next()I
:try_end_1
.catch Lorg/xmlpull/v1/XmlPullParserException; {:try_start_1 .. :try_end_1} :catch_0
.catch Ljava/io/IOException; {:try_start_1 .. :try_end_1} :catch_1
move-result v0
goto/16 :goto_1
.line 148
:catch_1
move-exception v0
.line 149
invoke-virtual {v0}, Ljava/io/IOException;->printStackTrace()V
goto :goto_4
.line 156
:cond_6
const-string v0, "Vpai_Upgrade"
const-string v1, "## onCreate, no usbDevice filter!"
invoke-static {v0, v1}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I
.line 159
:cond_7
new-instance v0, Landroid/content/IntentFilter;
invoke-direct {v0}, Landroid/content/IntentFilter;-><init>()V
.line 160
const-string v1, "android.hardware.usb.action.USB_DEVICE_ATTACHED"
invoke-virtual {v0, v1}, Landroid/content/IntentFilter;->addAction(Ljava/lang/String;)V
.line 161
const-string v1, "android.hardware.usb.action.USB_DEVICE_DETACHED"
invoke-virtual {v0, v1}, Landroid/content/IntentFilter;->addAction(Ljava/lang/String;)V
.line 162
iget-object v1, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mReceiver:Landroid/content/BroadcastReceiver;
invoke-virtual {p0, v1, v0}, Lcom/viatech/update/UpgradeDeviceActivity;->registerReceiver(Landroid/content/BroadcastReceiver;Landroid/content/IntentFilter;)Landroid/content/Intent;
.line 167
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mHandler:Landroid/os/Handler;
const/16 v1, 0x3e8
const-wide/16 v2, 0x32
invoke-virtual {v0, v1, v2, v3}, Landroid/os/Handler;->sendEmptyMessageDelayed(IJ)Z
.line 168
return-void
.end method
.method protected onDestroy()V
.locals 1
.prologue
.line 558
invoke-virtual {p0}, Lcom/viatech/update/UpgradeDeviceActivity;->closeUpgrade()V
.line 559
invoke-super {p0}, Landroid/app/Activity;->onDestroy()V
.line 560
iget-object v0, p0, Lcom/viatech/update/UpgradeDeviceActivity;->mReceiver:Landroid/content/BroadcastReceiver;
invoke-virtual {p0, v0}, Lcom/viatech/update/UpgradeDeviceActivity;->unregisterReceiver(Landroid/content/BroadcastReceiver;)V
.line 561
return-void
.end method
.method protected onPause()V
.locals 0
.prologue
.line 571
invoke-super {p0}, Landroid/app/Activity;->onPause()V
.line 574
return-void
.end method
.method protected onResume()V
.locals 0
.prologue
.line 565
invoke-super {p0}, Landroid/app/Activity;->onResume()V
.line 567
return-void
.end method