soul-browser/app/smali_classes2/j$/util/y.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

334 lines
6.1 KiB
Smali

.class public final Lj$/util/y;
.super Ljava/lang/Object;
.source "SourceFile"
# interfaces
.implements Ljava/util/function/DoubleConsumer;
# instance fields
.field public a:D
.field public b:D
.field private count:J
.field private max:D
.field private min:D
.field private sum:D
# direct methods
.method public constructor <init>()V
.locals 2
.line 77
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
const-wide/high16 v0, 0x7ff0000000000000L # Double.POSITIVE_INFINITY
.line 69
iput-wide v0, p0, Lj$/util/y;->min:D
const-wide/high16 v0, -0x10000000000000L # Double.NEGATIVE_INFINITY
.line 70
iput-wide v0, p0, Lj$/util/y;->max:D
return-void
.end method
# virtual methods
.method public final a(Lj$/util/y;)V
.locals 4
.line 154
iget-wide v0, p0, Lj$/util/y;->count:J
iget-wide v2, p1, Lj$/util/y;->count:J
add-long/2addr v0, v2
iput-wide v0, p0, Lj$/util/y;->count:J
.line 155
iget-wide v0, p0, Lj$/util/y;->b:D
iget-wide v2, p1, Lj$/util/y;->b:D
add-double/2addr v0, v2
iput-wide v0, p0, Lj$/util/y;->b:D
.line 156
iget-wide v0, p1, Lj$/util/y;->sum:D
invoke-virtual {p0, v0, v1}, Lj$/util/y;->b(D)V
.line 157
iget-wide v0, p1, Lj$/util/y;->a:D
invoke-virtual {p0, v0, v1}, Lj$/util/y;->b(D)V
.line 158
iget-wide v0, p0, Lj$/util/y;->min:D
iget-wide v2, p1, Lj$/util/y;->min:D
invoke-static {v0, v1, v2, v3}, Ljava/lang/Math;->min(DD)D
move-result-wide v0
iput-wide v0, p0, Lj$/util/y;->min:D
.line 159
iget-wide v0, p0, Lj$/util/y;->max:D
iget-wide v2, p1, Lj$/util/y;->max:D
invoke-static {v0, v1, v2, v3}, Ljava/lang/Math;->max(DD)D
move-result-wide v0
iput-wide v0, p0, Lj$/util/y;->max:D
return-void
.end method
.method public final accept(D)V
.locals 4
.line 139
iget-wide v0, p0, Lj$/util/y;->count:J
const-wide/16 v2, 0x1
add-long/2addr v0, v2
iput-wide v0, p0, Lj$/util/y;->count:J
.line 140
iget-wide v0, p0, Lj$/util/y;->b:D
add-double/2addr v0, p1
iput-wide v0, p0, Lj$/util/y;->b:D
.line 141
invoke-virtual {p0, p1, p2}, Lj$/util/y;->b(D)V
.line 142
iget-wide v0, p0, Lj$/util/y;->min:D
invoke-static {v0, v1, p1, p2}, Ljava/lang/Math;->min(DD)D
move-result-wide v0
iput-wide v0, p0, Lj$/util/y;->min:D
.line 143
iget-wide v0, p0, Lj$/util/y;->max:D
invoke-static {v0, v1, p1, p2}, Ljava/lang/Math;->max(DD)D
move-result-wide p1
iput-wide p1, p0, Lj$/util/y;->max:D
return-void
.end method
.method public final synthetic andThen(Ljava/util/function/DoubleConsumer;)Ljava/util/function/DoubleConsumer;
.locals 0
invoke-static {p0, p1}, Lj$/util/function/DoubleConsumer$-CC;->$default$andThen(Ljava/util/function/DoubleConsumer;Ljava/util/function/DoubleConsumer;)Ljava/util/function/DoubleConsumer;
move-result-object p1
return-object p1
.end method
.method public final b(D)V
.locals 4
.line 167
iget-wide v0, p0, Lj$/util/y;->a:D
sub-double/2addr p1, v0
.line 168
iget-wide v0, p0, Lj$/util/y;->sum:D
add-double v2, v0, p1
sub-double v0, v2, v0
sub-double/2addr v0, p1
.line 169
iput-wide v0, p0, Lj$/util/y;->a:D
.line 170
iput-wide v2, p0, Lj$/util/y;->sum:D
return-void
.end method
.method public final toString()Ljava/lang/String;
.locals 8
.line 307
const-class v0, Lj$/util/y;
invoke-virtual {v0}, Ljava/lang/Class;->getSimpleName()Ljava/lang/String;
move-result-object v0
.line 179
iget-wide v1, p0, Lj$/util/y;->count:J
.line 308
invoke-static {v1, v2}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;
move-result-object v1
.line 242
iget-wide v2, p0, Lj$/util/y;->sum:D
iget-wide v4, p0, Lj$/util/y;->a:D
add-double/2addr v2, v4
.line 243
invoke-static {v2, v3}, Ljava/lang/Double;->isNaN(D)Z
move-result v4
if-eqz v4, :cond_0
iget-wide v4, p0, Lj$/util/y;->b:D
invoke-static {v4, v5}, Ljava/lang/Double;->isInfinite(D)Z
move-result v4
if-eqz v4, :cond_0
.line 248
iget-wide v2, p0, Lj$/util/y;->b:D
.line 309
:cond_0
invoke-static {v2, v3}, Ljava/lang/Double;->valueOf(D)Ljava/lang/Double;
move-result-object v2
.line 264
iget-wide v3, p0, Lj$/util/y;->min:D
.line 310
invoke-static {v3, v4}, Ljava/lang/Double;->valueOf(D)Ljava/lang/Double;
move-result-object v3
.line 179
iget-wide v4, p0, Lj$/util/y;->count:J
const-wide/16 v6, 0x0
cmp-long v4, v4, v6
if-lez v4, :cond_2
.line 242
iget-wide v4, p0, Lj$/util/y;->sum:D
iget-wide v6, p0, Lj$/util/y;->a:D
add-double/2addr v4, v6
.line 243
invoke-static {v4, v5}, Ljava/lang/Double;->isNaN(D)Z
move-result v6
if-eqz v6, :cond_1
iget-wide v6, p0, Lj$/util/y;->b:D
invoke-static {v6, v7}, Ljava/lang/Double;->isInfinite(D)Z
move-result v6
if-eqz v6, :cond_1
.line 248
iget-wide v4, p0, Lj$/util/y;->b:D
.line 179
:cond_1
iget-wide v6, p0, Lj$/util/y;->count:J
long-to-double v6, v6
div-double/2addr v4, v6
goto :goto_0
:cond_2
const-wide/16 v4, 0x0
.line 311
:goto_0
invoke-static {v4, v5}, Ljava/lang/Double;->valueOf(D)Ljava/lang/Double;
move-result-object v4
.line 278
iget-wide v5, p0, Lj$/util/y;->max:D
.line 312
invoke-static {v5, v6}, Ljava/lang/Double;->valueOf(D)Ljava/lang/Double;
move-result-object v5
const/4 v6, 0x6
new-array v6, v6, [Ljava/lang/Object;
const/4 v7, 0x0
aput-object v0, v6, v7
const/4 v0, 0x1
aput-object v1, v6, v0
const/4 v0, 0x2
aput-object v2, v6, v0
const/4 v0, 0x3
aput-object v3, v6, v0
const/4 v0, 0x4
aput-object v4, v6, v0
const/4 v0, 0x5
aput-object v5, v6, v0
.line 305
const-string v0, "%s{count=%d, sum=%f, min=%f, average=%f, max=%f}"
invoke-static {v0, v6}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
move-result-object v0
return-object v0
.end method