- 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
387 lines
9.4 KiB
Smali
387 lines
9.4 KiB
Smali
.class public Landroidx/appcompat/widget/TintContextWrapper;
|
|
.super Landroid/content/ContextWrapper;
|
|
.source "SourceFile"
|
|
|
|
|
|
# annotations
|
|
.annotation build Landroidx/annotation/RestrictTo;
|
|
value = {
|
|
.enum Landroidx/annotation/RestrictTo$Scope;->LIBRARY_GROUP_PREFIX:Landroidx/annotation/RestrictTo$Scope;
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field private static final CACHE_LOCK:Ljava/lang/Object;
|
|
|
|
.field private static sCache:Ljava/util/ArrayList;
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"Ljava/util/ArrayList<",
|
|
"Ljava/lang/ref/WeakReference<",
|
|
"Landroidx/appcompat/widget/TintContextWrapper;",
|
|
">;>;"
|
|
}
|
|
.end annotation
|
|
.end field
|
|
|
|
|
|
# instance fields
|
|
.field private final mResources:Landroid/content/res/Resources;
|
|
|
|
.field private final mTheme:Landroid/content/res/Resources$Theme;
|
|
|
|
|
|
# direct methods
|
|
.method static constructor <clinit>()V
|
|
.locals 1
|
|
|
|
.line 41
|
|
new-instance v0, Ljava/lang/Object;
|
|
|
|
invoke-direct {v0}, Ljava/lang/Object;-><init>()V
|
|
|
|
sput-object v0, Landroidx/appcompat/widget/TintContextWrapper;->CACHE_LOCK:Ljava/lang/Object;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private constructor <init>(Landroid/content/Context;)V
|
|
.locals 2
|
|
.param p1 # Landroid/content/Context;
|
|
.annotation build Landroidx/annotation/NonNull;
|
|
.end annotation
|
|
.end param
|
|
|
|
.line 91
|
|
invoke-direct {p0, p1}, Landroid/content/ContextWrapper;-><init>(Landroid/content/Context;)V
|
|
|
|
.line 93
|
|
invoke-static {}, Landroidx/appcompat/widget/VectorEnabledTintResources;->shouldBeUsed()Z
|
|
|
|
move-result v0
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
.line 96
|
|
new-instance v0, Landroidx/appcompat/widget/VectorEnabledTintResources;
|
|
|
|
invoke-virtual {p1}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-direct {v0, p0, v1}, Landroidx/appcompat/widget/VectorEnabledTintResources;-><init>(Landroid/content/Context;Landroid/content/res/Resources;)V
|
|
|
|
iput-object v0, p0, Landroidx/appcompat/widget/TintContextWrapper;->mResources:Landroid/content/res/Resources;
|
|
|
|
.line 97
|
|
invoke-virtual {v0}, Landroid/content/res/Resources;->newTheme()Landroid/content/res/Resources$Theme;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Landroidx/appcompat/widget/TintContextWrapper;->mTheme:Landroid/content/res/Resources$Theme;
|
|
|
|
.line 98
|
|
invoke-virtual {p1}, Landroid/content/Context;->getTheme()Landroid/content/res/Resources$Theme;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {v0, p1}, Landroid/content/res/Resources$Theme;->setTo(Landroid/content/res/Resources$Theme;)V
|
|
|
|
goto :goto_0
|
|
|
|
.line 100
|
|
:cond_0
|
|
new-instance v0, Landroidx/appcompat/widget/TintResources;
|
|
|
|
invoke-virtual {p1}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-direct {v0, p0, p1}, Landroidx/appcompat/widget/TintResources;-><init>(Landroid/content/Context;Landroid/content/res/Resources;)V
|
|
|
|
iput-object v0, p0, Landroidx/appcompat/widget/TintContextWrapper;->mResources:Landroid/content/res/Resources;
|
|
|
|
const/4 p1, 0x0
|
|
|
|
iput-object p1, p0, Landroidx/appcompat/widget/TintContextWrapper;->mTheme:Landroid/content/res/Resources$Theme;
|
|
|
|
:goto_0
|
|
return-void
|
|
.end method
|
|
|
|
.method private static shouldWrap(Landroid/content/Context;)Z
|
|
.locals 1
|
|
.param p0 # Landroid/content/Context;
|
|
.annotation build Landroidx/annotation/NonNull;
|
|
.end annotation
|
|
.end param
|
|
|
|
.line 77
|
|
instance-of v0, p0, Landroidx/appcompat/widget/TintContextWrapper;
|
|
|
|
if-nez v0, :cond_1
|
|
|
|
.line 78
|
|
invoke-virtual {p0}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
|
|
|
|
move-result-object v0
|
|
|
|
instance-of v0, v0, Landroidx/appcompat/widget/TintResources;
|
|
|
|
if-nez v0, :cond_1
|
|
|
|
.line 79
|
|
invoke-virtual {p0}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
|
|
|
|
move-result-object p0
|
|
|
|
instance-of p0, p0, Landroidx/appcompat/widget/VectorEnabledTintResources;
|
|
|
|
if-eqz p0, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
.line 84
|
|
:cond_0
|
|
invoke-static {}, Landroidx/appcompat/widget/VectorEnabledTintResources;->shouldBeUsed()Z
|
|
|
|
move-result p0
|
|
|
|
return p0
|
|
|
|
:cond_1
|
|
:goto_0
|
|
const/4 p0, 0x0
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method public static wrap(Landroid/content/Context;)Landroid/content/Context;
|
|
.locals 4
|
|
.param p0 # Landroid/content/Context;
|
|
.annotation build Landroidx/annotation/NonNull;
|
|
.end annotation
|
|
.end param
|
|
|
|
.line 45
|
|
invoke-static {p0}, Landroidx/appcompat/widget/TintContextWrapper;->shouldWrap(Landroid/content/Context;)Z
|
|
|
|
move-result v0
|
|
|
|
if-eqz v0, :cond_7
|
|
|
|
sget-object v0, Landroidx/appcompat/widget/TintContextWrapper;->CACHE_LOCK:Ljava/lang/Object;
|
|
|
|
.line 46
|
|
monitor-enter v0
|
|
|
|
:try_start_0
|
|
sget-object v1, Landroidx/appcompat/widget/TintContextWrapper;->sCache:Ljava/util/ArrayList;
|
|
|
|
if-nez v1, :cond_0
|
|
|
|
.line 48
|
|
new-instance v1, Ljava/util/ArrayList;
|
|
|
|
invoke-direct {v1}, Ljava/util/ArrayList;-><init>()V
|
|
|
|
sput-object v1, Landroidx/appcompat/widget/TintContextWrapper;->sCache:Ljava/util/ArrayList;
|
|
|
|
goto :goto_3
|
|
|
|
:catchall_0
|
|
move-exception p0
|
|
|
|
goto :goto_4
|
|
|
|
.line 51
|
|
:cond_0
|
|
invoke-virtual {v1}, Ljava/util/ArrayList;->size()I
|
|
|
|
move-result v1
|
|
|
|
add-int/lit8 v1, v1, -0x1
|
|
|
|
:goto_0
|
|
if-ltz v1, :cond_3
|
|
|
|
sget-object v2, Landroidx/appcompat/widget/TintContextWrapper;->sCache:Ljava/util/ArrayList;
|
|
|
|
.line 52
|
|
invoke-virtual {v2, v1}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;
|
|
|
|
move-result-object v2
|
|
|
|
check-cast v2, Ljava/lang/ref/WeakReference;
|
|
|
|
if-eqz v2, :cond_1
|
|
|
|
.line 53
|
|
invoke-virtual {v2}, Ljava/lang/ref/Reference;->get()Ljava/lang/Object;
|
|
|
|
move-result-object v2
|
|
|
|
if-nez v2, :cond_2
|
|
|
|
:cond_1
|
|
sget-object v2, Landroidx/appcompat/widget/TintContextWrapper;->sCache:Ljava/util/ArrayList;
|
|
|
|
.line 54
|
|
invoke-virtual {v2, v1}, Ljava/util/ArrayList;->remove(I)Ljava/lang/Object;
|
|
|
|
:cond_2
|
|
add-int/lit8 v1, v1, -0x1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_3
|
|
sget-object v1, Landroidx/appcompat/widget/TintContextWrapper;->sCache:Ljava/util/ArrayList;
|
|
|
|
.line 58
|
|
invoke-virtual {v1}, Ljava/util/ArrayList;->size()I
|
|
|
|
move-result v1
|
|
|
|
add-int/lit8 v1, v1, -0x1
|
|
|
|
:goto_1
|
|
if-ltz v1, :cond_6
|
|
|
|
sget-object v2, Landroidx/appcompat/widget/TintContextWrapper;->sCache:Ljava/util/ArrayList;
|
|
|
|
.line 59
|
|
invoke-virtual {v2, v1}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;
|
|
|
|
move-result-object v2
|
|
|
|
check-cast v2, Ljava/lang/ref/WeakReference;
|
|
|
|
if-eqz v2, :cond_4
|
|
|
|
.line 60
|
|
invoke-virtual {v2}, Ljava/lang/ref/Reference;->get()Ljava/lang/Object;
|
|
|
|
move-result-object v2
|
|
|
|
check-cast v2, Landroidx/appcompat/widget/TintContextWrapper;
|
|
|
|
goto :goto_2
|
|
|
|
:cond_4
|
|
const/4 v2, 0x0
|
|
|
|
:goto_2
|
|
if-eqz v2, :cond_5
|
|
|
|
.line 61
|
|
invoke-virtual {v2}, Landroid/content/ContextWrapper;->getBaseContext()Landroid/content/Context;
|
|
|
|
move-result-object v3
|
|
|
|
if-ne v3, p0, :cond_5
|
|
|
|
.line 62
|
|
monitor-exit v0
|
|
|
|
return-object v2
|
|
|
|
:cond_5
|
|
add-int/lit8 v1, v1, -0x1
|
|
|
|
goto :goto_1
|
|
|
|
.line 68
|
|
:cond_6
|
|
:goto_3
|
|
new-instance v1, Landroidx/appcompat/widget/TintContextWrapper;
|
|
|
|
invoke-direct {v1, p0}, Landroidx/appcompat/widget/TintContextWrapper;-><init>(Landroid/content/Context;)V
|
|
|
|
sget-object p0, Landroidx/appcompat/widget/TintContextWrapper;->sCache:Ljava/util/ArrayList;
|
|
|
|
.line 69
|
|
new-instance v2, Ljava/lang/ref/WeakReference;
|
|
|
|
invoke-direct {v2, v1}, Ljava/lang/ref/WeakReference;-><init>(Ljava/lang/Object;)V
|
|
|
|
invoke-virtual {p0, v2}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z
|
|
|
|
.line 70
|
|
monitor-exit v0
|
|
|
|
return-object v1
|
|
|
|
.line 71
|
|
:goto_4
|
|
monitor-exit v0
|
|
:try_end_0
|
|
.catchall {:try_start_0 .. :try_end_0} :catchall_0
|
|
|
|
throw p0
|
|
|
|
:cond_7
|
|
return-object p0
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public getAssets()Landroid/content/res/AssetManager;
|
|
.locals 1
|
|
|
|
iget-object v0, p0, Landroidx/appcompat/widget/TintContextWrapper;->mResources:Landroid/content/res/Resources;
|
|
|
|
.line 127
|
|
invoke-virtual {v0}, Landroid/content/res/Resources;->getAssets()Landroid/content/res/AssetManager;
|
|
|
|
move-result-object v0
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method public getResources()Landroid/content/res/Resources;
|
|
.locals 1
|
|
|
|
iget-object v0, p0, Landroidx/appcompat/widget/TintContextWrapper;->mResources:Landroid/content/res/Resources;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method public getTheme()Landroid/content/res/Resources$Theme;
|
|
.locals 1
|
|
|
|
iget-object v0, p0, Landroidx/appcompat/widget/TintContextWrapper;->mTheme:Landroid/content/res/Resources$Theme;
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
.line 107
|
|
invoke-super {p0}, Landroid/content/ContextWrapper;->getTheme()Landroid/content/res/Resources$Theme;
|
|
|
|
move-result-object v0
|
|
|
|
:cond_0
|
|
return-object v0
|
|
.end method
|
|
|
|
.method public setTheme(I)V
|
|
.locals 2
|
|
|
|
iget-object v0, p0, Landroidx/appcompat/widget/TintContextWrapper;->mTheme:Landroid/content/res/Resources$Theme;
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
.line 113
|
|
invoke-super {p0, p1}, Landroid/content/ContextWrapper;->setTheme(I)V
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 v1, 0x1
|
|
|
|
.line 115
|
|
invoke-virtual {v0, p1, v1}, Landroid/content/res/Resources$Theme;->applyStyle(IZ)V
|
|
|
|
:goto_0
|
|
return-void
|
|
.end method
|