From a5d39c3bbe63a8b3132df162a29ac9046ed82ddb Mon Sep 17 00:00:00 2001 From: LisoUseInAIKyrios <118716522+LisoUseInAIKyrios@users.noreply.github.com> Date: Wed, 19 Nov 2025 16:54:31 +0200 Subject: [PATCH] fix splash screen changes not working and remove obsolete debugging code (issue was caused by bad merge of main branch) --- .../patches/theme/SeekbarColorPatch.java | 10 ---------- .../youtube/layout/seekbar/Fingerprints.kt | 19 ------------------- .../layout/seekbar/SeekbarColorPatch.kt | 15 --------------- 3 files changed, 44 deletions(-) diff --git a/extensions/youtube/src/main/java/app/revanced/extension/youtube/patches/theme/SeekbarColorPatch.java b/extensions/youtube/src/main/java/app/revanced/extension/youtube/patches/theme/SeekbarColorPatch.java index 65f31d813..29fdb7e88 100644 --- a/extensions/youtube/src/main/java/app/revanced/extension/youtube/patches/theme/SeekbarColorPatch.java +++ b/extensions/youtube/src/main/java/app/revanced/extension/youtube/patches/theme/SeekbarColorPatch.java @@ -102,16 +102,6 @@ public final class SeekbarColorPatch { return customSeekbarColor; } - /** - * injection point. - */ - public static boolean useLotteLaunchSplashScreen(boolean original) { - // This method is only used for development purposes to force the old style launch screen. - // Forcing this off on some devices can cause unexplained startup crashes, - // where the lottie animation is still used even though this condition appears to bypass it. - return original; // false = drawable style, true = lottie style. - } - /** * Injection point. * Modern Lottie style animation. diff --git a/patches/src/main/kotlin/app/revanced/patches/youtube/layout/seekbar/Fingerprints.kt b/patches/src/main/kotlin/app/revanced/patches/youtube/layout/seekbar/Fingerprints.kt index 442290e5b..5014126ef 100644 --- a/patches/src/main/kotlin/app/revanced/patches/youtube/layout/seekbar/Fingerprints.kt +++ b/patches/src/main/kotlin/app/revanced/patches/youtube/layout/seekbar/Fingerprints.kt @@ -106,25 +106,6 @@ internal val playerLinearGradientLegacyFingerprint = fingerprint { ) } -internal const val launchScreenLayoutTypeLotteFeatureLegacyFlag = 268507948L -internal const val launchScreenLayoutTypeLotteFeatureFlag = 1073814316L - -internal val launchScreenLayoutTypeFingerprint = fingerprint { - accessFlags(AccessFlags.PUBLIC, AccessFlags.CONSTRUCTOR) - instructions( - anyInstruction( - literal(launchScreenLayoutTypeLotteFeatureLegacyFlag), - literal(launchScreenLayoutTypeLotteFeatureFlag) - ) - ) - custom { method, _ -> - val firstParameter = method.parameterTypes.firstOrNull() - // 19.25 - 19.45 - firstParameter == YOUTUBE_MAIN_ACTIVITY_CLASS_TYPE - || firstParameter == "Landroid/app/Activity;" // 19.46+ - } -} - internal const val LOTTIE_ANIMATION_VIEW_CLASS_TYPE = "Lcom/airbnb/lottie/LottieAnimationView;" internal val lottieAnimationViewSetAnimationIntFingerprint = fingerprint { diff --git a/patches/src/main/kotlin/app/revanced/patches/youtube/layout/seekbar/SeekbarColorPatch.kt b/patches/src/main/kotlin/app/revanced/patches/youtube/layout/seekbar/SeekbarColorPatch.kt index 6ef30e769..06a0b1717 100644 --- a/patches/src/main/kotlin/app/revanced/patches/youtube/layout/seekbar/SeekbarColorPatch.kt +++ b/patches/src/main/kotlin/app/revanced/patches/youtube/layout/seekbar/SeekbarColorPatch.kt @@ -154,21 +154,6 @@ val seekbarColorPatch = bytecodePatch( return@execute // 19.25 does not have a cairo launch animation. } - // Add development hook to force old drawable splash animation. - arrayOf( - launchScreenLayoutTypeFingerprint, - mainActivityOnCreateFingerprint - ).forEach { fingerprint -> - fingerprint.method.insertLiteralOverride( - if (is_20_30_or_greater) { - launchScreenLayoutTypeLotteFeatureFlag - } else { - launchScreenLayoutTypeLotteFeatureLegacyFlag - }, - "$EXTENSION_CLASS_DESCRIPTOR->useLotteLaunchSplashScreen(Z)Z" - ) - } - // Hook the splash animation to set the a seekbar color. mainActivityOnCreateFingerprint.method.apply { val setAnimationIntMethodName =