* 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>
214 lines
6.7 KiB
Java
214 lines
6.7 KiB
Java
package com.google.android.gms.common.api;
|
|
|
|
import android.app.Activity;
|
|
import android.app.ActivityOptions;
|
|
import android.app.PendingIntent;
|
|
import android.os.Bundle;
|
|
import android.os.Parcel;
|
|
import android.os.Parcelable;
|
|
import androidx.activity.result.ActivityResultLauncher;
|
|
import androidx.activity.result.IntentSenderRequest;
|
|
import androidx.annotation.NonNull;
|
|
import androidx.annotation.Nullable;
|
|
import com.google.android.gms.common.ConnectionResult;
|
|
import com.google.android.gms.common.annotation.KeepForSdk;
|
|
import com.google.android.gms.common.internal.Objects;
|
|
import com.google.android.gms.common.internal.Preconditions;
|
|
import com.google.android.gms.common.internal.ReflectedParcelable;
|
|
import com.google.android.gms.common.internal.ShowFirstParty;
|
|
import com.google.android.gms.common.internal.safeparcel.AbstractSafeParcelable;
|
|
import com.google.android.gms.common.internal.safeparcel.SafeParcelWriter;
|
|
import com.google.android.gms.common.internal.safeparcel.SafeParcelable;
|
|
import com.google.android.gms.common.util.PlatformVersion;
|
|
|
|
@SafeParcelable.Class(creator = "StatusCreator")
|
|
/* loaded from: classes.dex */
|
|
public final class Status extends AbstractSafeParcelable implements Result, ReflectedParcelable {
|
|
|
|
@SafeParcelable.Field(getter = "getStatusCode", id = 1)
|
|
private final int zza;
|
|
|
|
@Nullable
|
|
@SafeParcelable.Field(getter = "getStatusMessage", id = 2)
|
|
private final String zzb;
|
|
|
|
@Nullable
|
|
@SafeParcelable.Field(getter = "getPendingIntent", id = 3)
|
|
private final PendingIntent zzc;
|
|
|
|
@Nullable
|
|
@SafeParcelable.Field(getter = "getConnectionResult", id = 4)
|
|
private final ConnectionResult zzd;
|
|
|
|
@NonNull
|
|
@ShowFirstParty
|
|
@KeepForSdk
|
|
public static final Status RESULT_SUCCESS_CACHE = new Status(-1);
|
|
|
|
@NonNull
|
|
@ShowFirstParty
|
|
@KeepForSdk
|
|
public static final Status RESULT_SUCCESS = new Status(0);
|
|
|
|
@NonNull
|
|
@ShowFirstParty
|
|
@KeepForSdk
|
|
public static final Status RESULT_INTERRUPTED = new Status(14);
|
|
|
|
@NonNull
|
|
@ShowFirstParty
|
|
@KeepForSdk
|
|
public static final Status RESULT_INTERNAL_ERROR = new Status(8);
|
|
|
|
@NonNull
|
|
@ShowFirstParty
|
|
@KeepForSdk
|
|
public static final Status RESULT_TIMEOUT = new Status(15);
|
|
|
|
@NonNull
|
|
@ShowFirstParty
|
|
@KeepForSdk
|
|
public static final Status RESULT_CANCELED = new Status(16);
|
|
|
|
@NonNull
|
|
@ShowFirstParty
|
|
@KeepForSdk
|
|
public static final Status RESULT_API_NOT_CONNECTED = new Status(17);
|
|
|
|
@NonNull
|
|
@KeepForSdk
|
|
public static final Status RESULT_DEAD_CLIENT = new Status(18);
|
|
|
|
@NonNull
|
|
public static final Parcelable.Creator<Status> CREATOR = new zze();
|
|
|
|
@SafeParcelable.Constructor
|
|
public Status(@SafeParcelable.Param(id = 1) int i, @Nullable @SafeParcelable.Param(id = 2) String str, @Nullable @SafeParcelable.Param(id = 3) PendingIntent pendingIntent, @Nullable @SafeParcelable.Param(id = 4) ConnectionResult connectionResult) {
|
|
this.zza = i;
|
|
this.zzb = str;
|
|
this.zzc = pendingIntent;
|
|
this.zzd = connectionResult;
|
|
}
|
|
|
|
public boolean equals(@Nullable Object obj) {
|
|
if (!(obj instanceof Status)) {
|
|
return false;
|
|
}
|
|
Status status = (Status) obj;
|
|
if (this.zza != status.zza || !Objects.equal(this.zzb, status.zzb) || !Objects.equal(this.zzc, status.zzc) || !Objects.equal(this.zzd, status.zzd)) {
|
|
return false;
|
|
}
|
|
return true;
|
|
}
|
|
|
|
@Nullable
|
|
public ConnectionResult getConnectionResult() {
|
|
return this.zzd;
|
|
}
|
|
|
|
@Nullable
|
|
public PendingIntent getResolution() {
|
|
return this.zzc;
|
|
}
|
|
|
|
@Override // com.google.android.gms.common.api.Result
|
|
@NonNull
|
|
public Status getStatus() {
|
|
return this;
|
|
}
|
|
|
|
public int getStatusCode() {
|
|
return this.zza;
|
|
}
|
|
|
|
@Nullable
|
|
public String getStatusMessage() {
|
|
return this.zzb;
|
|
}
|
|
|
|
public boolean hasResolution() {
|
|
return this.zzc != null;
|
|
}
|
|
|
|
public int hashCode() {
|
|
return Objects.hashCode(Integer.valueOf(this.zza), this.zzb, this.zzc, this.zzd);
|
|
}
|
|
|
|
public boolean isCanceled() {
|
|
return this.zza == 16;
|
|
}
|
|
|
|
public boolean isInterrupted() {
|
|
return this.zza == 14;
|
|
}
|
|
|
|
public boolean isSuccess() {
|
|
return this.zza <= 0;
|
|
}
|
|
|
|
public void startResolutionForResult(@NonNull Activity activity, int i) {
|
|
if (hasResolution()) {
|
|
Bundle bundle = PlatformVersion.isAtLeastU() ? ActivityOptions.makeBasic().setPendingIntentBackgroundActivityStartMode(1).toBundle() : null;
|
|
PendingIntent pendingIntent = this.zzc;
|
|
Preconditions.checkNotNull(pendingIntent);
|
|
activity.startIntentSenderForResult(pendingIntent.getIntentSender(), i, null, 0, 0, 0, bundle);
|
|
}
|
|
}
|
|
|
|
@NonNull
|
|
public String toString() {
|
|
Objects.ToStringHelper stringHelper = Objects.toStringHelper(this);
|
|
stringHelper.add("statusCode", zza());
|
|
stringHelper.add("resolution", this.zzc);
|
|
return stringHelper.toString();
|
|
}
|
|
|
|
@Override // android.os.Parcelable
|
|
public void writeToParcel(@NonNull Parcel parcel, int i) {
|
|
int beginObjectHeader = SafeParcelWriter.beginObjectHeader(parcel);
|
|
SafeParcelWriter.writeInt(parcel, 1, getStatusCode());
|
|
SafeParcelWriter.writeString(parcel, 2, getStatusMessage(), false);
|
|
SafeParcelWriter.writeParcelable(parcel, 3, this.zzc, i, false);
|
|
SafeParcelWriter.writeParcelable(parcel, 4, getConnectionResult(), i, false);
|
|
SafeParcelWriter.finishObjectHeader(parcel, beginObjectHeader);
|
|
}
|
|
|
|
@NonNull
|
|
public final String zza() {
|
|
String str = this.zzb;
|
|
if (str != null) {
|
|
return str;
|
|
}
|
|
return CommonStatusCodes.getStatusCodeString(this.zza);
|
|
}
|
|
|
|
public Status(int i) {
|
|
this(i, (String) null);
|
|
}
|
|
|
|
public Status(@NonNull ConnectionResult connectionResult, @NonNull String str) {
|
|
this(connectionResult, str, 17);
|
|
}
|
|
|
|
public Status(int i, @Nullable String str) {
|
|
this(i, str, (PendingIntent) null);
|
|
}
|
|
|
|
@KeepForSdk
|
|
@Deprecated
|
|
public Status(@NonNull ConnectionResult connectionResult, @NonNull String str, int i) {
|
|
this(i, str, connectionResult.getResolution(), connectionResult);
|
|
}
|
|
|
|
public Status(int i, @Nullable String str, @Nullable PendingIntent pendingIntent) {
|
|
this(i, str, pendingIntent, null);
|
|
}
|
|
|
|
public void startResolutionForResult(@NonNull ActivityResultLauncher<IntentSenderRequest> activityResultLauncher) {
|
|
if (hasResolution()) {
|
|
PendingIntent pendingIntent = this.zzc;
|
|
Preconditions.checkNotNull(pendingIntent);
|
|
activityResultLauncher.a(new IntentSenderRequest.Builder(pendingIntent.getIntentSender()).a());
|
|
}
|
|
}
|
|
}
|