* 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>
326 lines
9 KiB
Java
326 lines
9 KiB
Java
package com.mycompany.app.view;
|
|
|
|
import android.content.Context;
|
|
import android.graphics.Canvas;
|
|
import android.graphics.Paint;
|
|
import android.graphics.RectF;
|
|
import android.widget.FrameLayout;
|
|
import com.mycompany.app.main.MainApp;
|
|
|
|
/* loaded from: classes3.dex */
|
|
public class MyRoundFrame extends FrameLayout {
|
|
|
|
/* renamed from: c, reason: collision with root package name */
|
|
public boolean f18929c;
|
|
public int f;
|
|
public float g;
|
|
public int h;
|
|
public Paint i;
|
|
public RectF j;
|
|
public boolean k;
|
|
public RectF l;
|
|
public Paint m;
|
|
|
|
public MyRoundFrame(Context context) {
|
|
super(context);
|
|
this.f18929c = true;
|
|
this.g = MainApp.v1;
|
|
if (this.h != 0) {
|
|
Paint paint = new Paint();
|
|
this.i = paint;
|
|
paint.setAntiAlias(true);
|
|
this.i.setStyle(Paint.Style.FILL);
|
|
this.i.setColor(this.h);
|
|
}
|
|
this.j = new RectF();
|
|
}
|
|
|
|
public final void a() {
|
|
this.f18929c = false;
|
|
this.i = null;
|
|
this.j = null;
|
|
this.l = null;
|
|
this.m = null;
|
|
}
|
|
|
|
public final void b(int i, int i2) {
|
|
RectF rectF = this.j;
|
|
if (rectF != null) {
|
|
int i3 = this.f;
|
|
if (i3 == 2) {
|
|
if (this.l != null) {
|
|
return;
|
|
}
|
|
rectF.set(0.0f, getPaddingTop(), i, i2);
|
|
} else {
|
|
if (i3 == 3) {
|
|
rectF.set(0.0f, getPaddingTop(), i, i2 + this.g);
|
|
return;
|
|
}
|
|
if (i3 == 4) {
|
|
rectF.set(0.0f, -this.g, i, i2);
|
|
return;
|
|
}
|
|
if (i3 == 5) {
|
|
if (this.k) {
|
|
rectF.set(0.0f, -this.g, i, i2 - getPaddingBottom());
|
|
return;
|
|
} else {
|
|
rectF.set(0.0f, 0.0f, i, i2 - getPaddingBottom());
|
|
return;
|
|
}
|
|
}
|
|
rectF.set(0.0f, 0.0f, i, i2);
|
|
}
|
|
}
|
|
}
|
|
|
|
public final void c(int i, int i2) {
|
|
this.f = 0;
|
|
this.k = false;
|
|
if (this.h == i && this.g == i2) {
|
|
return;
|
|
}
|
|
this.h = i;
|
|
this.g = i2;
|
|
if (i == 0) {
|
|
this.i = null;
|
|
invalidate();
|
|
return;
|
|
}
|
|
if (this.i == null) {
|
|
Paint paint = new Paint();
|
|
this.i = paint;
|
|
paint.setAntiAlias(true);
|
|
this.i.setStyle(Paint.Style.FILL);
|
|
}
|
|
this.i.setColor(this.h);
|
|
invalidate();
|
|
}
|
|
|
|
public final void d(int i, boolean z) {
|
|
this.f = 5;
|
|
this.g = MainApp.v1 + MainApp.G1;
|
|
if (this.h != i || this.k != z) {
|
|
this.h = i;
|
|
this.k = z;
|
|
if (i == 0) {
|
|
this.i = null;
|
|
invalidate();
|
|
return;
|
|
}
|
|
if (this.i == null) {
|
|
Paint paint = new Paint();
|
|
this.i = paint;
|
|
paint.setAntiAlias(true);
|
|
this.i.setStyle(Paint.Style.FILL);
|
|
}
|
|
this.i.setColor(this.h);
|
|
int width = getWidth();
|
|
int height = getHeight();
|
|
if (width != 0 && height != 0) {
|
|
b(width, height);
|
|
invalidate();
|
|
}
|
|
}
|
|
}
|
|
|
|
@Override // android.view.ViewGroup, android.view.View
|
|
public final void dispatchDraw(Canvas canvas) {
|
|
RectF rectF;
|
|
RectF rectF2;
|
|
if (this.f18929c) {
|
|
Paint paint = this.i;
|
|
if (paint != null && (rectF2 = this.j) != null) {
|
|
float f = this.g;
|
|
canvas.drawRoundRect(rectF2, f, f, paint);
|
|
}
|
|
super.dispatchDraw(canvas);
|
|
Paint paint2 = this.m;
|
|
if (paint2 != null && (rectF = this.l) != null) {
|
|
float f2 = this.g;
|
|
canvas.drawRoundRect(rectF, f2, f2, paint2);
|
|
}
|
|
}
|
|
}
|
|
|
|
@Override // android.view.View
|
|
public final void invalidate() {
|
|
if (!this.f18929c) {
|
|
return;
|
|
}
|
|
super.invalidate();
|
|
}
|
|
|
|
@Override // android.view.View
|
|
public final void onSizeChanged(int i, int i2, int i3, int i4) {
|
|
RectF rectF;
|
|
super.onSizeChanged(i, i2, i3, i4);
|
|
int i5 = this.f;
|
|
if (i5 == 2 && (rectF = this.l) != null) {
|
|
float f = MainApp.n1 / 2.0f;
|
|
rectF.set(f, getPaddingTop() + f, i - f, i2 - f);
|
|
return;
|
|
}
|
|
if (i5 == 1) {
|
|
this.g = i / 2.0f;
|
|
} else {
|
|
b(i, i2);
|
|
}
|
|
RectF rectF2 = this.l;
|
|
if (rectF2 != null) {
|
|
float f2 = MainApp.n1 / 2.0f;
|
|
rectF2.set(f2, f2, i - f2, i2 - f2);
|
|
}
|
|
}
|
|
|
|
public void setBgColor(int i) {
|
|
this.f = 0;
|
|
this.g = MainApp.v1;
|
|
this.k = false;
|
|
if (this.h == i) {
|
|
return;
|
|
}
|
|
this.h = i;
|
|
if (i == 0) {
|
|
this.i = null;
|
|
invalidate();
|
|
return;
|
|
}
|
|
if (this.i == null) {
|
|
Paint paint = new Paint();
|
|
this.i = paint;
|
|
paint.setAntiAlias(true);
|
|
this.i.setStyle(Paint.Style.FILL);
|
|
}
|
|
this.i.setColor(this.h);
|
|
invalidate();
|
|
}
|
|
|
|
public void setBgOutColor(int i) {
|
|
this.l = new RectF();
|
|
Paint paint = new Paint();
|
|
this.m = paint;
|
|
paint.setAntiAlias(true);
|
|
this.m.setStyle(Paint.Style.STROKE);
|
|
this.m.setStrokeWidth(MainApp.n1);
|
|
this.m.setColor(i);
|
|
}
|
|
|
|
public void setCircle(int i) {
|
|
this.f = 1;
|
|
this.g = getWidth() / 2.0f;
|
|
this.k = false;
|
|
if (MainApp.K1 && i == -460552) {
|
|
i = -11513776;
|
|
}
|
|
if (this.h == i) {
|
|
return;
|
|
}
|
|
this.h = i;
|
|
if (this.i == null) {
|
|
Paint paint = new Paint();
|
|
this.i = paint;
|
|
paint.setAntiAlias(true);
|
|
this.i.setStyle(Paint.Style.FILL);
|
|
}
|
|
this.i.setColor(this.h);
|
|
invalidate();
|
|
}
|
|
|
|
public void setNewsAllowColor(int i) {
|
|
this.f = 2;
|
|
this.g = MainApp.v1 + MainApp.G1;
|
|
this.k = false;
|
|
if (this.h != i) {
|
|
this.h = i;
|
|
if (i == -2434342) {
|
|
this.i = null;
|
|
if (this.l == null) {
|
|
setBgOutColor(i);
|
|
if (this.l == null) {
|
|
return;
|
|
}
|
|
}
|
|
int width = getWidth();
|
|
int height = getHeight();
|
|
if (width != 0 && height != 0) {
|
|
float f = MainApp.n1 / 2.0f;
|
|
this.l.set(f, getPaddingTop() + f, width - f, height - f);
|
|
invalidate();
|
|
return;
|
|
}
|
|
return;
|
|
}
|
|
this.l = null;
|
|
this.m = null;
|
|
if (this.i == null) {
|
|
Paint paint = new Paint();
|
|
this.i = paint;
|
|
paint.setAntiAlias(true);
|
|
this.i.setStyle(Paint.Style.FILL);
|
|
}
|
|
this.i.setColor(this.h);
|
|
int width2 = getWidth();
|
|
int height2 = getHeight();
|
|
if (width2 != 0 && height2 != 0) {
|
|
b(width2, height2);
|
|
invalidate();
|
|
}
|
|
}
|
|
}
|
|
|
|
public void setNewsHeadColor(int i) {
|
|
this.f = 3;
|
|
this.g = MainApp.v1 + MainApp.G1;
|
|
this.k = false;
|
|
if (this.h != i) {
|
|
this.h = i;
|
|
if (i == 0) {
|
|
this.i = null;
|
|
invalidate();
|
|
return;
|
|
}
|
|
if (this.i == null) {
|
|
Paint paint = new Paint();
|
|
this.i = paint;
|
|
paint.setAntiAlias(true);
|
|
this.i.setStyle(Paint.Style.FILL);
|
|
}
|
|
this.i.setColor(this.h);
|
|
int width = getWidth();
|
|
int height = getHeight();
|
|
if (width != 0 && height != 0) {
|
|
b(width, height);
|
|
invalidate();
|
|
}
|
|
}
|
|
}
|
|
|
|
public void setNewsNotiColor(int i) {
|
|
this.f = 4;
|
|
this.g = MainApp.v1 + MainApp.G1;
|
|
this.k = false;
|
|
if (this.h != i) {
|
|
this.h = i;
|
|
if (i == 0) {
|
|
this.i = null;
|
|
invalidate();
|
|
return;
|
|
}
|
|
if (this.i == null) {
|
|
Paint paint = new Paint();
|
|
this.i = paint;
|
|
paint.setAntiAlias(true);
|
|
this.i.setStyle(Paint.Style.FILL);
|
|
}
|
|
this.i.setColor(this.h);
|
|
int width = getWidth();
|
|
int height = getHeight();
|
|
if (width != 0 && height != 0) {
|
|
b(width, height);
|
|
invalidate();
|
|
}
|
|
}
|
|
}
|
|
}
|