soul-browser/app/smali/androidx/room/RoomSQLiteQuery.smali
KaKi87 550ddb0413
Decompile and recreate Soul Browser v1.4.85 with APK CI builds (#1)
* Decompile and recreate Soul Browser v1.4.85 with APK CI builds

Co-authored-by: KaKi87 <KaKi87@pm.me>

* Fix CI build: include bundled google.jks and remove PR trigger

The apktool build failed in CI because app/unknown/.../google.jks was
excluded by the *.jks gitignore rule. Whitelist app-bundled JKS files
and commit the missing resource.

Also remove the redundant pull_request workflow trigger.

Co-authored-by: KaKi87 <KaKi87@pm.me>

* Change package ID to com.github.kaki87.soulbrowser

Rename the application ID so the rebuilt APK can be installed
alongside the original Soul Browser from Google Play.

- Update AndroidManifest package, permissions, providers, and actions
- Update R class references in smali (com/github/kaki87/soulbrowser/R)
- Update shortcuts.xml targetPackage
- Rename app label to "Soul Rebuild" for easy identification

Co-authored-by: KaKi87 <KaKi87@pm.me>

* Fix install compatibility: remove split APK metadata and bundle native libs

The rebuilt APK still declared requiredSplitTypes and Play Store split
metadata, causing Android to reject standalone installs as incompatible.

- Remove requiredSplitTypes and split-related manifest meta-data
- Merge native libs from all ABI splits with uncompressed storage
- Page-align before signing for extractNativeLibs=false
- Add .so to apktool doNotCompress list

Co-authored-by: KaKi87 <KaKi87@pm.me>

* Fix install failure: use apksigner v2/v3 and bundle arm64 native libs

Target SDK 36 requires APK Signature Scheme v2+, but jarsigner only
produces v1 signatures, causing Android to reject the install.

- Sign with apksigner (v1+v2+v3) instead of jarsigner
- Add arm64-v8a native libraries from universal Soul Browser 1.4.79
- Set extractNativeLibs=true for reliable sideload installs
- Commit stable debug keystore for consistent signatures across builds

Co-authored-by: KaKi87 <KaKi87@pm.me>

* Add committed debug keystore for consistent APK signatures

Co-authored-by: KaKi87 <KaKi87@pm.me>

* Fix startup crash: use original classes2.dex desugar libraries

Apktool recompiles smali_classes2 into a broken classes2.dex, causing
ClassNotFoundException for j$.com.android.tools.r8.a at ML Kit init.

Inject the original classes2.dex (Java 8+ desugar libs) after apktool
build instead of using the recompiled version.

Co-authored-by: KaKi87 <KaKi87@pm.me>

* Fix missing drawable resources from density split APKs

The base APK is an app bundle module; density-specific drawables like
seek_thumb_nor_b live in config.xhdpi.apk and were missing after rebuild,
causing Resources$NotFoundException at runtime.

- Merge non-9-patch resources from split APKs before apktool build
- Sync public.xml IDs from R smali only when backing files exist
- Add 713 density-specific resource IDs to public.xml

Co-authored-by: KaKi87 <KaKi87@pm.me>

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
2026-08-10 16:07:14 +02:00

636 lines
10 KiB
Smali

.class public Landroidx/room/RoomSQLiteQuery;
.super Ljava/lang/Object;
.source "SourceFile"
# interfaces
.implements Landroidx/sqlite/db/SupportSQLiteQuery;
.implements Landroidx/sqlite/db/SupportSQLiteProgram;
# annotations
.annotation build Landroidx/annotation/RestrictTo;
.end annotation
# static fields
.field public static final m:Ljava/util/TreeMap;
# instance fields
.field public volatile c:Ljava/lang/String;
.field public final f:[J
.field public final g:[D
.field public final h:[Ljava/lang/String;
.field public final i:[[B
.field public final j:[I
.field public final k:I
.field public l:I
# direct methods
.method static constructor <clinit>()V
.locals 1
.line 1
new-instance v0, Ljava/util/TreeMap;
.line 2
.line 3
invoke-direct {v0}, Ljava/util/TreeMap;-><init>()V
.line 4
.line 5
.line 6
sput-object v0, Landroidx/room/RoomSQLiteQuery;->m:Ljava/util/TreeMap;
.line 7
.line 8
return-void
.end method
.method public constructor <init>(I)V
.locals 1
.line 1
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
.line 2
.line 3
.line 4
iput p1, p0, Landroidx/room/RoomSQLiteQuery;->k:I
.line 5
.line 6
add-int/lit8 p1, p1, 0x1
.line 7
.line 8
new-array v0, p1, [I
.line 9
.line 10
iput-object v0, p0, Landroidx/room/RoomSQLiteQuery;->j:[I
.line 11
.line 12
new-array v0, p1, [J
.line 13
.line 14
iput-object v0, p0, Landroidx/room/RoomSQLiteQuery;->f:[J
.line 15
.line 16
new-array v0, p1, [D
.line 17
.line 18
iput-object v0, p0, Landroidx/room/RoomSQLiteQuery;->g:[D
.line 19
.line 20
new-array v0, p1, [Ljava/lang/String;
.line 21
.line 22
iput-object v0, p0, Landroidx/room/RoomSQLiteQuery;->h:[Ljava/lang/String;
.line 23
.line 24
new-array p1, p1, [[B
.line 25
.line 26
iput-object p1, p0, Landroidx/room/RoomSQLiteQuery;->i:[[B
.line 27
.line 28
return-void
.end method
.method public static d(ILjava/lang/String;)Landroidx/room/RoomSQLiteQuery;
.locals 3
.line 1
sget-object v0, Landroidx/room/RoomSQLiteQuery;->m:Ljava/util/TreeMap;
.line 2
.line 3
monitor-enter v0
.line 4
:try_start_0
invoke-static {p0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
.line 5
.line 6
.line 7
move-result-object v1
.line 8
invoke-virtual {v0, v1}, Ljava/util/TreeMap;->ceilingEntry(Ljava/lang/Object;)Ljava/util/Map$Entry;
.line 9
.line 10
.line 11
move-result-object v1
.line 12
if-eqz v1, :cond_0
.line 13
.line 14
invoke-interface {v1}, Ljava/util/Map$Entry;->getKey()Ljava/lang/Object;
.line 15
.line 16
.line 17
move-result-object v2
.line 18
invoke-virtual {v0, v2}, Ljava/util/TreeMap;->remove(Ljava/lang/Object;)Ljava/lang/Object;
.line 19
.line 20
.line 21
invoke-interface {v1}, Ljava/util/Map$Entry;->getValue()Ljava/lang/Object;
.line 22
.line 23
.line 24
move-result-object v1
.line 25
check-cast v1, Landroidx/room/RoomSQLiteQuery;
.line 26
.line 27
iput-object p1, v1, Landroidx/room/RoomSQLiteQuery;->c:Ljava/lang/String;
.line 28
.line 29
iput p0, v1, Landroidx/room/RoomSQLiteQuery;->l:I
.line 30
.line 31
monitor-exit v0
.line 32
return-object v1
.line 33
:catchall_0
move-exception p0
.line 34
goto :goto_0
.line 35
:cond_0
monitor-exit v0
:try_end_0
.catchall {:try_start_0 .. :try_end_0} :catchall_0
.line 36
new-instance v0, Landroidx/room/RoomSQLiteQuery;
.line 37
.line 38
invoke-direct {v0, p0}, Landroidx/room/RoomSQLiteQuery;-><init>(I)V
.line 39
.line 40
.line 41
iput-object p1, v0, Landroidx/room/RoomSQLiteQuery;->c:Ljava/lang/String;
.line 42
.line 43
iput p0, v0, Landroidx/room/RoomSQLiteQuery;->l:I
.line 44
.line 45
return-object v0
.line 46
:goto_0
:try_start_1
monitor-exit v0
:try_end_1
.catchall {:try_start_1 .. :try_end_1} :catchall_0
.line 47
throw p0
.end method
# virtual methods
.method public final I(IJ)V
.locals 2
.line 1
iget-object v0, p0, Landroidx/room/RoomSQLiteQuery;->j:[I
.line 2
.line 3
const/4 v1, 0x2
.line 4
aput v1, v0, p1
.line 5
.line 6
iget-object v0, p0, Landroidx/room/RoomSQLiteQuery;->f:[J
.line 7
.line 8
aput-wide p2, v0, p1
.line 9
.line 10
return-void
.end method
.method public final R([BI)V
.locals 2
.line 1
iget-object v0, p0, Landroidx/room/RoomSQLiteQuery;->j:[I
.line 2
.line 3
const/4 v1, 0x5
.line 4
aput v1, v0, p2
.line 5
.line 6
iget-object v0, p0, Landroidx/room/RoomSQLiteQuery;->i:[[B
.line 7
.line 8
aput-object p1, v0, p2
.line 9
.line 10
return-void
.end method
.method public final a()Ljava/lang/String;
.locals 1
.line 1
iget-object v0, p0, Landroidx/room/RoomSQLiteQuery;->c:Ljava/lang/String;
.line 2
.line 3
return-object v0
.end method
.method public final b(Landroidx/sqlite/db/SupportSQLiteProgram;)V
.locals 5
.line 1
const/4 v0, 0x1
.line 2
move v1, v0
.line 3
:goto_0
iget v2, p0, Landroidx/room/RoomSQLiteQuery;->l:I
.line 4
.line 5
if-gt v1, v2, :cond_5
.line 6
.line 7
iget-object v2, p0, Landroidx/room/RoomSQLiteQuery;->j:[I
.line 8
.line 9
aget v2, v2, v1
.line 10
.line 11
if-eq v2, v0, :cond_4
.line 12
.line 13
const/4 v3, 0x2
.line 14
if-eq v2, v3, :cond_3
.line 15
.line 16
const/4 v3, 0x3
.line 17
if-eq v2, v3, :cond_2
.line 18
.line 19
const/4 v3, 0x4
.line 20
if-eq v2, v3, :cond_1
.line 21
.line 22
const/4 v3, 0x5
.line 23
if-eq v2, v3, :cond_0
.line 24
.line 25
goto :goto_1
.line 26
:cond_0
iget-object v2, p0, Landroidx/room/RoomSQLiteQuery;->i:[[B
.line 27
.line 28
aget-object v2, v2, v1
.line 29
.line 30
invoke-interface {p1, v2, v1}, Landroidx/sqlite/db/SupportSQLiteProgram;->R([BI)V
.line 31
.line 32
.line 33
goto :goto_1
.line 34
:cond_1
iget-object v2, p0, Landroidx/room/RoomSQLiteQuery;->h:[Ljava/lang/String;
.line 35
.line 36
aget-object v2, v2, v1
.line 37
.line 38
invoke-interface {p1, v1, v2}, Landroidx/sqlite/db/SupportSQLiteProgram;->t(ILjava/lang/String;)V
.line 39
.line 40
.line 41
goto :goto_1
.line 42
:cond_2
iget-object v2, p0, Landroidx/room/RoomSQLiteQuery;->g:[D
.line 43
.line 44
aget-wide v3, v2, v1
.line 45
.line 46
invoke-interface {p1, v3, v4, v1}, Landroidx/sqlite/db/SupportSQLiteProgram;->d0(DI)V
.line 47
.line 48
.line 49
goto :goto_1
.line 50
:cond_3
iget-object v2, p0, Landroidx/room/RoomSQLiteQuery;->f:[J
.line 51
.line 52
aget-wide v3, v2, v1
.line 53
.line 54
invoke-interface {p1, v1, v3, v4}, Landroidx/sqlite/db/SupportSQLiteProgram;->I(IJ)V
.line 55
.line 56
.line 57
goto :goto_1
.line 58
:cond_4
invoke-interface {p1, v1}, Landroidx/sqlite/db/SupportSQLiteProgram;->g0(I)V
.line 59
.line 60
.line 61
:goto_1
add-int/lit8 v1, v1, 0x1
.line 62
.line 63
goto :goto_0
.line 64
:cond_5
return-void
.end method
.method public final close()V
.locals 0
return-void
.end method
.method public final d0(DI)V
.locals 2
.line 1
iget-object v0, p0, Landroidx/room/RoomSQLiteQuery;->j:[I
.line 2
.line 3
const/4 v1, 0x3
.line 4
aput v1, v0, p3
.line 5
.line 6
iget-object v0, p0, Landroidx/room/RoomSQLiteQuery;->g:[D
.line 7
.line 8
aput-wide p1, v0, p3
.line 9
.line 10
return-void
.end method
.method public final g0(I)V
.locals 2
.line 1
iget-object v0, p0, Landroidx/room/RoomSQLiteQuery;->j:[I
.line 2
.line 3
const/4 v1, 0x1
.line 4
aput v1, v0, p1
.line 5
.line 6
return-void
.end method
.method public final release()V
.locals 4
.line 1
sget-object v0, Landroidx/room/RoomSQLiteQuery;->m:Ljava/util/TreeMap;
.line 2
.line 3
monitor-enter v0
.line 4
:try_start_0
iget v1, p0, Landroidx/room/RoomSQLiteQuery;->k:I
.line 5
.line 6
invoke-static {v1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
.line 7
.line 8
.line 9
move-result-object v1
.line 10
invoke-virtual {v0, v1, p0}, Ljava/util/TreeMap;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
.line 11
.line 12
.line 13
invoke-virtual {v0}, Ljava/util/TreeMap;->size()I
.line 14
.line 15
.line 16
move-result v1
.line 17
const/16 v2, 0xf
.line 18
.line 19
if-le v1, v2, :cond_0
.line 20
.line 21
invoke-virtual {v0}, Ljava/util/TreeMap;->size()I
.line 22
.line 23
.line 24
move-result v1
.line 25
add-int/lit8 v1, v1, -0xa
.line 26
.line 27
invoke-virtual {v0}, Ljava/util/TreeMap;->descendingKeySet()Ljava/util/NavigableSet;
.line 28
.line 29
.line 30
move-result-object v2
.line 31
invoke-interface {v2}, Ljava/util/NavigableSet;->iterator()Ljava/util/Iterator;
.line 32
.line 33
.line 34
move-result-object v2
.line 35
:goto_0
add-int/lit8 v3, v1, -0x1
.line 36
.line 37
if-lez v1, :cond_0
.line 38
.line 39
invoke-interface {v2}, Ljava/util/Iterator;->next()Ljava/lang/Object;
.line 40
.line 41
.line 42
invoke-interface {v2}, Ljava/util/Iterator;->remove()V
.line 43
.line 44
.line 45
move v1, v3
.line 46
goto :goto_0
.line 47
:cond_0
monitor-exit v0
.line 48
return-void
.line 49
:catchall_0
move-exception v1
.line 50
monitor-exit v0
:try_end_0
.catchall {:try_start_0 .. :try_end_0} :catchall_0
.line 51
throw v1
.end method
.method public final t(ILjava/lang/String;)V
.locals 2
.line 1
iget-object v0, p0, Landroidx/room/RoomSQLiteQuery;->j:[I
.line 2
.line 3
const/4 v1, 0x4
.line 4
aput v1, v0, p1
.line 5
.line 6
iget-object v0, p0, Landroidx/room/RoomSQLiteQuery;->h:[Ljava/lang/String;
.line 7
.line 8
aput-object p2, v0, p1
.line 9
.line 10
return-void
.end method