- Imported from https://github.com/supermegamestre/Project-Real-Resurrection-3 - APKTool decompilation (Smali bytecode) for modding and rebuilding APK - Supports both 32-bit (armeabi-v7a) and 64-bit (arm64-v8a) architectures - Includes full Smali source, resources, and native libraries - Ready to rebuild APK after modifications with apktool b command - Added comprehensive README-apktool.md with modding guide This branch complements the JADX branches: - Use JADX (main/discord-community) to UNDERSTAND code (readable Java) - Use APKTool (this branch) to MODIFY and REBUILD APK (editable Smali) Total: 44,417 files, 538.51 MB Smali source code
572 lines
13 KiB
Smali
572 lines
13 KiB
Smali
.class public abstract Lcom/google/android/exoplayer2/offline/DownloadService;
|
|
.super Landroid/app/Service;
|
|
.source "SourceFile"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/MemberClasses;
|
|
value = {
|
|
Lcom/google/android/exoplayer2/offline/DownloadService$DownloadManagerHelper;
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field public static final downloadManagerHelpers:Ljava/util/HashMap;
|
|
|
|
|
|
# instance fields
|
|
.field public final channelDescriptionResourceId:I
|
|
|
|
.field public final channelId:Ljava/lang/String;
|
|
|
|
.field public final channelNameResourceId:I
|
|
|
|
.field public isDestroyed:Z
|
|
|
|
.field public isStopped:Z
|
|
|
|
.field public lastStartId:I
|
|
|
|
.field public startedInForeground:Z
|
|
|
|
.field public taskRemoved:Z
|
|
|
|
|
|
# direct methods
|
|
.method static constructor <clinit>()V
|
|
.locals 1
|
|
|
|
.line 174
|
|
new-instance v0, Ljava/util/HashMap;
|
|
|
|
invoke-direct {v0}, Ljava/util/HashMap;-><init>()V
|
|
|
|
sput-object v0, Lcom/google/android/exoplayer2/offline/DownloadService;->downloadManagerHelpers:Ljava/util/HashMap;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public abstract getDownloadManager()Lcom/google/android/exoplayer2/offline/DownloadManager;
|
|
.end method
|
|
|
|
.method public abstract getScheduler()Lcom/google/android/exoplayer2/scheduler/Scheduler;
|
|
.end method
|
|
|
|
.method public final onBind(Landroid/content/Intent;)Landroid/os/IBinder;
|
|
.locals 0
|
|
|
|
.line 719
|
|
new-instance p1, Ljava/lang/UnsupportedOperationException;
|
|
|
|
invoke-direct {p1}, Ljava/lang/UnsupportedOperationException;-><init>()V
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public onCreate()V
|
|
.locals 4
|
|
|
|
iget-object v0, p0, Lcom/google/android/exoplayer2/offline/DownloadService;->channelId:Ljava/lang/String;
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
iget v1, p0, Lcom/google/android/exoplayer2/offline/DownloadService;->channelNameResourceId:I
|
|
|
|
iget v2, p0, Lcom/google/android/exoplayer2/offline/DownloadService;->channelDescriptionResourceId:I
|
|
|
|
const/4 v3, 0x2
|
|
|
|
.line 573
|
|
invoke-static {p0, v0, v1, v2, v3}, Lcom/google/android/exoplayer2/util/NotificationUtil;->createNotificationChannel(Landroid/content/Context;Ljava/lang/String;III)V
|
|
|
|
.line 580
|
|
:cond_0
|
|
invoke-virtual {p0}, Ljava/lang/Object;->getClass()Ljava/lang/Class;
|
|
|
|
move-result-object v0
|
|
|
|
sget-object v1, Lcom/google/android/exoplayer2/offline/DownloadService;->downloadManagerHelpers:Ljava/util/HashMap;
|
|
|
|
.line 581
|
|
invoke-virtual {v1, v0}, Ljava/util/HashMap;->get(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Lcom/google/android/exoplayer2/offline/DownloadService$DownloadManagerHelper;
|
|
|
|
.line 585
|
|
invoke-virtual {p0}, Lcom/google/android/exoplayer2/offline/DownloadService;->getDownloadManager()Lcom/google/android/exoplayer2/offline/DownloadManager;
|
|
|
|
const/4 v0, 0x0
|
|
|
|
.line 586
|
|
throw v0
|
|
.end method
|
|
|
|
.method public onDestroy()V
|
|
.locals 2
|
|
|
|
const/4 v0, 0x1
|
|
|
|
iput-boolean v0, p0, Lcom/google/android/exoplayer2/offline/DownloadService;->isDestroyed:Z
|
|
|
|
sget-object v0, Lcom/google/android/exoplayer2/offline/DownloadService;->downloadManagerHelpers:Ljava/util/HashMap;
|
|
|
|
.line 706
|
|
invoke-virtual {p0}, Ljava/lang/Object;->getClass()Ljava/lang/Class;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v0, v1}, Ljava/util/HashMap;->get(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Lcom/google/android/exoplayer2/offline/DownloadService$DownloadManagerHelper;
|
|
|
|
invoke-static {v0}, Lcom/google/android/exoplayer2/util/Assertions;->checkNotNull(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Lcom/google/android/exoplayer2/offline/DownloadService$DownloadManagerHelper;
|
|
|
|
.line 707
|
|
invoke-virtual {v0, p0}, Lcom/google/android/exoplayer2/offline/DownloadService$DownloadManagerHelper;->detachService(Lcom/google/android/exoplayer2/offline/DownloadService;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public onStartCommand(Landroid/content/Intent;II)I
|
|
.locals 7
|
|
|
|
iput p3, p0, Lcom/google/android/exoplayer2/offline/DownloadService;->lastStartId:I
|
|
|
|
const/4 p2, 0x0
|
|
|
|
iput-boolean p2, p0, Lcom/google/android/exoplayer2/offline/DownloadService;->taskRemoved:Z
|
|
|
|
const/4 p3, 0x1
|
|
|
|
const-string v0, "com.google.android.exoplayer.downloadService.action.RESTART"
|
|
|
|
const/4 v1, 0x0
|
|
|
|
if-eqz p1, :cond_2
|
|
|
|
.line 604
|
|
invoke-virtual {p1}, Landroid/content/Intent;->getAction()Ljava/lang/String;
|
|
|
|
move-result-object v2
|
|
|
|
const-string v3, "content_id"
|
|
|
|
.line 605
|
|
invoke-virtual {p1, v3}, Landroid/content/Intent;->getStringExtra(Ljava/lang/String;)Ljava/lang/String;
|
|
|
|
move-result-object v3
|
|
|
|
iget-boolean v4, p0, Lcom/google/android/exoplayer2/offline/DownloadService;->startedInForeground:Z
|
|
|
|
const-string v5, "foreground"
|
|
|
|
.line 607
|
|
invoke-virtual {p1, v5, p2}, Landroid/content/Intent;->getBooleanExtra(Ljava/lang/String;Z)Z
|
|
|
|
move-result v5
|
|
|
|
if-nez v5, :cond_1
|
|
|
|
invoke-virtual {v0, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
|
|
|
|
move-result v5
|
|
|
|
if-eqz v5, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
move v5, p2
|
|
|
|
goto :goto_1
|
|
|
|
:cond_1
|
|
:goto_0
|
|
move v5, p3
|
|
|
|
:goto_1
|
|
or-int/2addr v4, v5
|
|
|
|
iput-boolean v4, p0, Lcom/google/android/exoplayer2/offline/DownloadService;->startedInForeground:Z
|
|
|
|
goto :goto_2
|
|
|
|
:cond_2
|
|
move-object v2, v1
|
|
|
|
move-object v3, v2
|
|
|
|
:goto_2
|
|
const-string v4, "com.google.android.exoplayer.downloadService.action.INIT"
|
|
|
|
if-nez v2, :cond_3
|
|
|
|
move-object v2, v4
|
|
|
|
.line 613
|
|
:cond_3
|
|
invoke-static {v1}, Lcom/google/android/exoplayer2/util/Assertions;->checkNotNull(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
move-result-object v5
|
|
|
|
invoke-static {v5}, Lcom/amazonaws/handlers/HandlerChainFactory$$ExternalSyntheticThrowCCEIfNotNull0;->m(Ljava/lang/Object;)V
|
|
|
|
.line 614
|
|
invoke-virtual {v2}, Ljava/lang/String;->hashCode()I
|
|
|
|
move-result v5
|
|
|
|
const/4 v6, -0x1
|
|
|
|
sparse-switch v5, :sswitch_data_0
|
|
|
|
:goto_3
|
|
move p3, v6
|
|
|
|
goto/16 :goto_4
|
|
|
|
:sswitch_0
|
|
const-string p3, "com.google.android.exoplayer.downloadService.action.REMOVE_DOWNLOAD"
|
|
|
|
invoke-virtual {v2, p3}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
|
|
|
|
move-result p3
|
|
|
|
if-nez p3, :cond_4
|
|
|
|
goto :goto_3
|
|
|
|
:cond_4
|
|
const/16 p3, 0x8
|
|
|
|
goto :goto_4
|
|
|
|
:sswitch_1
|
|
invoke-virtual {v2, v4}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
|
|
|
|
move-result p3
|
|
|
|
if-nez p3, :cond_5
|
|
|
|
goto :goto_3
|
|
|
|
:cond_5
|
|
const/4 p3, 0x7
|
|
|
|
goto :goto_4
|
|
|
|
:sswitch_2
|
|
const-string p3, "com.google.android.exoplayer.downloadService.action.SET_STOP_REASON"
|
|
|
|
invoke-virtual {v2, p3}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
|
|
|
|
move-result p3
|
|
|
|
if-nez p3, :cond_6
|
|
|
|
goto :goto_3
|
|
|
|
:cond_6
|
|
const/4 p3, 0x6
|
|
|
|
goto :goto_4
|
|
|
|
:sswitch_3
|
|
const-string p3, "com.google.android.exoplayer.downloadService.action.PAUSE_DOWNLOADS"
|
|
|
|
invoke-virtual {v2, p3}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
|
|
|
|
move-result p3
|
|
|
|
if-nez p3, :cond_7
|
|
|
|
goto :goto_3
|
|
|
|
:cond_7
|
|
const/4 p3, 0x5
|
|
|
|
goto :goto_4
|
|
|
|
:sswitch_4
|
|
const-string p3, "com.google.android.exoplayer.downloadService.action.SET_REQUIREMENTS"
|
|
|
|
invoke-virtual {v2, p3}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
|
|
|
|
move-result p3
|
|
|
|
if-nez p3, :cond_8
|
|
|
|
goto :goto_3
|
|
|
|
:cond_8
|
|
const/4 p3, 0x4
|
|
|
|
goto :goto_4
|
|
|
|
:sswitch_5
|
|
const-string p3, "com.google.android.exoplayer.downloadService.action.REMOVE_ALL_DOWNLOADS"
|
|
|
|
invoke-virtual {v2, p3}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
|
|
|
|
move-result p3
|
|
|
|
if-nez p3, :cond_9
|
|
|
|
goto :goto_3
|
|
|
|
:cond_9
|
|
const/4 p3, 0x3
|
|
|
|
goto :goto_4
|
|
|
|
:sswitch_6
|
|
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
|
|
|
|
move-result p3
|
|
|
|
if-nez p3, :cond_a
|
|
|
|
goto :goto_3
|
|
|
|
:cond_a
|
|
const/4 p3, 0x2
|
|
|
|
goto :goto_4
|
|
|
|
:sswitch_7
|
|
const-string v0, "com.google.android.exoplayer.downloadService.action.RESUME_DOWNLOADS"
|
|
|
|
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
|
|
|
|
move-result v0
|
|
|
|
if-nez v0, :cond_c
|
|
|
|
goto :goto_3
|
|
|
|
:sswitch_8
|
|
const-string p3, "com.google.android.exoplayer.downloadService.action.ADD_DOWNLOAD"
|
|
|
|
invoke-virtual {v2, p3}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
|
|
|
|
move-result p3
|
|
|
|
if-nez p3, :cond_b
|
|
|
|
goto :goto_3
|
|
|
|
:cond_b
|
|
move p3, p2
|
|
|
|
:cond_c
|
|
:goto_4
|
|
const-string v0, "stop_reason"
|
|
|
|
const-string v4, "DownloadService"
|
|
|
|
packed-switch p3, :pswitch_data_0
|
|
|
|
.line 681
|
|
invoke-virtual {v2}, Ljava/lang/String;->length()I
|
|
|
|
move-result p1
|
|
|
|
const-string p3, "Ignored unrecognized action: "
|
|
|
|
if-eqz p1, :cond_d
|
|
|
|
invoke-virtual {p3, v2}, Ljava/lang/String;->concat(Ljava/lang/String;)Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
goto :goto_5
|
|
|
|
:cond_d
|
|
new-instance p1, Ljava/lang/String;
|
|
|
|
invoke-direct {p1, p3}, Ljava/lang/String;-><init>(Ljava/lang/String;)V
|
|
|
|
:goto_5
|
|
invoke-static {v4, p1}, Lcom/google/android/exoplayer2/util/Log;->e(Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
goto :goto_6
|
|
|
|
:pswitch_0
|
|
if-nez v3, :cond_e
|
|
|
|
const-string p1, "Ignored REMOVE_DOWNLOAD: Missing content_id extra"
|
|
|
|
.line 632
|
|
invoke-static {v4, p1}, Lcom/google/android/exoplayer2/util/Log;->e(Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
goto :goto_6
|
|
|
|
.line 634
|
|
:cond_e
|
|
throw v1
|
|
|
|
.line 647
|
|
:pswitch_1
|
|
invoke-static {p1}, Lcom/google/android/exoplayer2/util/Assertions;->checkNotNull(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
move-result-object p3
|
|
|
|
check-cast p3, Landroid/content/Intent;
|
|
|
|
invoke-virtual {p3, v0}, Landroid/content/Intent;->hasExtra(Ljava/lang/String;)Z
|
|
|
|
move-result p3
|
|
|
|
if-nez p3, :cond_f
|
|
|
|
const-string p1, "Ignored SET_STOP_REASON: Missing stop_reason extra"
|
|
|
|
.line 648
|
|
invoke-static {v4, p1}, Lcom/google/android/exoplayer2/util/Log;->e(Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
goto :goto_6
|
|
|
|
.line 650
|
|
:cond_f
|
|
invoke-virtual {p1, v0, p2}, Landroid/content/Intent;->getIntExtra(Ljava/lang/String;I)I
|
|
|
|
.line 651
|
|
throw v1
|
|
|
|
.line 644
|
|
:pswitch_2
|
|
throw v1
|
|
|
|
.line 657
|
|
:pswitch_3
|
|
invoke-static {p1}, Lcom/google/android/exoplayer2/util/Assertions;->checkNotNull(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
move-result-object p1
|
|
|
|
check-cast p1, Landroid/content/Intent;
|
|
|
|
const-string p3, "requirements"
|
|
|
|
invoke-virtual {p1, p3}, Landroid/content/Intent;->getParcelableExtra(Ljava/lang/String;)Landroid/os/Parcelable;
|
|
|
|
move-result-object p1
|
|
|
|
check-cast p1, Lcom/google/android/exoplayer2/scheduler/Requirements;
|
|
|
|
if-nez p1, :cond_10
|
|
|
|
const-string p1, "Ignored SET_REQUIREMENTS: Missing requirements extra"
|
|
|
|
.line 659
|
|
invoke-static {v4, p1}, Lcom/google/android/exoplayer2/util/Log;->e(Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
goto :goto_6
|
|
|
|
.line 661
|
|
:cond_10
|
|
invoke-virtual {p0}, Lcom/google/android/exoplayer2/offline/DownloadService;->getScheduler()Lcom/google/android/exoplayer2/scheduler/Scheduler;
|
|
|
|
.line 677
|
|
invoke-virtual {v1}, Ljava/lang/Object;->getClass()Ljava/lang/Class;
|
|
|
|
.line 663
|
|
throw v1
|
|
|
|
.line 638
|
|
:pswitch_4
|
|
throw v1
|
|
|
|
.line 641
|
|
:pswitch_5
|
|
throw v1
|
|
|
|
.line 622
|
|
:pswitch_6
|
|
invoke-static {p1}, Lcom/google/android/exoplayer2/util/Assertions;->checkNotNull(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
move-result-object p3
|
|
|
|
check-cast p3, Landroid/content/Intent;
|
|
|
|
const-string v2, "download_request"
|
|
|
|
invoke-virtual {p3, v2}, Landroid/content/Intent;->getParcelableExtra(Ljava/lang/String;)Landroid/os/Parcelable;
|
|
|
|
move-result-object p3
|
|
|
|
check-cast p3, Lcom/google/android/exoplayer2/offline/DownloadRequest;
|
|
|
|
if-nez p3, :cond_11
|
|
|
|
const-string p1, "Ignored ADD_DOWNLOAD: Missing download_request extra"
|
|
|
|
.line 624
|
|
invoke-static {v4, p1}, Lcom/google/android/exoplayer2/util/Log;->e(Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
.line 685
|
|
:goto_6
|
|
:pswitch_7
|
|
sget p1, Lcom/google/android/exoplayer2/util/Util;->SDK_INT:I
|
|
|
|
iput-boolean p2, p0, Lcom/google/android/exoplayer2/offline/DownloadService;->isStopped:Z
|
|
|
|
.line 691
|
|
throw v1
|
|
|
|
.line 626
|
|
:cond_11
|
|
invoke-virtual {p1, v0, p2}, Landroid/content/Intent;->getIntExtra(Ljava/lang/String;I)I
|
|
|
|
.line 627
|
|
throw v1
|
|
|
|
nop
|
|
|
|
:sswitch_data_0
|
|
.sparse-switch
|
|
-0x731c5e7b -> :sswitch_8
|
|
-0x378de948 -> :sswitch_7
|
|
-0x33ed2c70 -> :sswitch_6
|
|
-0x26c690ef -> :sswitch_5
|
|
-0x718ab14 -> :sswitch_4
|
|
0xb642643 -> :sswitch_3
|
|
0x2806a145 -> :sswitch_2
|
|
0x3c89ff0f -> :sswitch_1
|
|
0x5c3d4a84 -> :sswitch_0
|
|
.end sparse-switch
|
|
|
|
:pswitch_data_0
|
|
.packed-switch 0x0
|
|
:pswitch_6
|
|
:pswitch_5
|
|
:pswitch_7
|
|
:pswitch_4
|
|
:pswitch_3
|
|
:pswitch_2
|
|
:pswitch_1
|
|
:pswitch_7
|
|
:pswitch_0
|
|
.end packed-switch
|
|
.end method
|
|
|
|
.method public onTaskRemoved(Landroid/content/Intent;)V
|
|
.locals 0
|
|
|
|
const/4 p1, 0x1
|
|
|
|
iput-boolean p1, p0, Lcom/google/android/exoplayer2/offline/DownloadService;->taskRemoved:Z
|
|
|
|
return-void
|
|
.end method
|