Add Discord community version (64-bit only)

- Added realracing3-community.apk (71.57 MB)
- Removed 32-bit support (armeabi-v7a)
- Only includes arm64-v8a libraries
- Decompiled source code included
- Added README-community.md with analysis
This commit is contained in:
2026-02-18 15:48:36 -08:00
parent c19eb3d7ff
commit c080f0d97f
26930 changed files with 2529574 additions and 0 deletions

View File

@@ -0,0 +1,99 @@
package com.google.firebase.messaging;
import android.app.ActivityManager;
import android.app.KeyguardManager;
import android.app.NotificationManager;
import android.content.Context;
import android.graphics.Bitmap;
import android.os.Process;
import android.os.SystemClock;
import android.util.Log;
import androidx.core.app.NotificationCompat;
import com.google.android.gms.common.util.PlatformVersion;
import com.google.android.gms.tasks.Tasks;
import com.google.firebase.messaging.CommonNotificationBuilder;
import java.util.List;
import java.util.concurrent.ExecutionException;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.TimeoutException;
/* loaded from: classes3.dex */
public class DisplayNotification {
public final Context context;
public final ExecutorService networkIoExecutor;
public final NotificationParams params;
public DisplayNotification(Context context, NotificationParams notificationParams, ExecutorService executorService) {
this.networkIoExecutor = executorService;
this.context = context;
this.params = notificationParams;
}
public final boolean isAppForeground() {
if (((KeyguardManager) this.context.getSystemService("keyguard")).inKeyguardRestrictedInputMode()) {
return false;
}
if (!PlatformVersion.isAtLeastLollipop()) {
SystemClock.sleep(10L);
}
int myPid = Process.myPid();
List<ActivityManager.RunningAppProcessInfo> runningAppProcesses = ((ActivityManager) this.context.getSystemService("activity")).getRunningAppProcesses();
if (runningAppProcesses == null) {
return false;
}
for (ActivityManager.RunningAppProcessInfo runningAppProcessInfo : runningAppProcesses) {
if (runningAppProcessInfo.pid == myPid) {
return runningAppProcessInfo.importance == 100;
}
}
return false;
}
public boolean handleNotification() {
if (this.params.getBoolean("gcm.n.noui")) {
return true;
}
if (isAppForeground()) {
return false;
}
ImageDownload startImageDownloadInBackground = startImageDownloadInBackground();
CommonNotificationBuilder.DisplayNotificationInfo createNotificationInfo = CommonNotificationBuilder.createNotificationInfo(this.context, this.params);
waitForAndApplyImageDownload(createNotificationInfo.notificationBuilder, startImageDownloadInBackground);
showNotification(createNotificationInfo);
return true;
}
public final ImageDownload startImageDownloadInBackground() {
ImageDownload create = ImageDownload.create(this.params.getString("gcm.n.image"));
if (create != null) {
create.start(this.networkIoExecutor);
}
return create;
}
public final void waitForAndApplyImageDownload(NotificationCompat.Builder builder, ImageDownload imageDownload) {
if (imageDownload == null) {
return;
}
try {
Bitmap bitmap = (Bitmap) Tasks.await(imageDownload.getTask(), 5L, TimeUnit.SECONDS);
builder.setLargeIcon(bitmap);
builder.setStyle(new NotificationCompat.BigPictureStyle().bigPicture(bitmap).bigLargeIcon((Bitmap) null));
} catch (InterruptedException unused) {
Log.w("FirebaseMessaging", "Interrupted while downloading image, showing notification without it");
imageDownload.close();
Thread.currentThread().interrupt();
} catch (ExecutionException e) {
Log.w("FirebaseMessaging", "Failed to download image: " + e.getCause());
} catch (TimeoutException unused2) {
Log.w("FirebaseMessaging", "Failed to download image in time, showing notification without it");
imageDownload.close();
}
}
public final void showNotification(CommonNotificationBuilder.DisplayNotificationInfo displayNotificationInfo) {
Log.isLoggable("FirebaseMessaging", 3);
((NotificationManager) this.context.getSystemService("notification")).notify(displayNotificationInfo.tag, displayNotificationInfo.id, displayNotificationInfo.notificationBuilder.build());
}
}