mirror of
https://github.com/revanced/revanced-patches.git
synced 2025-12-07 09:53:55 +01:00
Compare commits
12 Commits
v4.0.0-dev
...
v4.0.1
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
acee384a90 | ||
|
|
1d7d31e979 | ||
|
|
781b8e2d40 | ||
|
|
6ecf53fd8f | ||
|
|
8c2f895e52 | ||
|
|
ec3371ffb5 | ||
|
|
44e36fead6 | ||
|
|
3b0ecdd7a7 | ||
|
|
279ac0dc28 | ||
|
|
31824713d7 | ||
|
|
be6a35fde6 | ||
|
|
d28d9f13bc |
79
CHANGELOG.md
79
CHANGELOG.md
@@ -1,3 +1,82 @@
|
||||
## [4.0.1](https://github.com/ReVanced/revanced-patches/compare/v4.0.0...v4.0.1) (2024-01-27)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* Indent patch option description correctly ([bd86ef6](https://github.com/ReVanced/revanced-patches/commit/bd86ef6fc2344fa049077e9aa4bcd5d7ffa4c7f9))
|
||||
* Only set Android key if not null to prevent build errors ([1181b0b](https://github.com/ReVanced/revanced-patches/commit/1181b0bca24c524c376f7ea26ae02ee771645e6b))
|
||||
|
||||
## [4.0.1-dev.2](https://github.com/ReVanced/revanced-patches/compare/v4.0.1-dev.1...v4.0.1-dev.2) (2024-01-27)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* Only set Android key if not null to prevent build errors ([1181b0b](https://github.com/ReVanced/revanced-patches/commit/1181b0bca24c524c376f7ea26ae02ee771645e6b))
|
||||
|
||||
## [4.0.1-dev.1](https://github.com/ReVanced/revanced-patches/compare/v4.0.0...v4.0.1-dev.1) (2024-01-27)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* Indent patch option description correctly ([bd86ef6](https://github.com/ReVanced/revanced-patches/commit/bd86ef6fc2344fa049077e9aa4bcd5d7ffa4c7f9))
|
||||
|
||||
# [4.0.0](https://github.com/ReVanced/revanced-patches/compare/v3.2.0...v4.0.0) (2024-01-27)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* Use new integrations patch path ([51e2f3b](https://github.com/ReVanced/revanced-patches/commit/51e2f3b476b49460e2f3fc2b5f302a3a72d7963f))
|
||||
* **YouTube - Change header:** Improve patch descriptions ([#2581](https://github.com/ReVanced/revanced-patches/issues/2581)) ([43a5677](https://github.com/ReVanced/revanced-patches/commit/43a5677397380f14a049ae95532fd5096b94c938))
|
||||
* **YouTube - Enable slide to seek:** Change patch default to excluded and add description disclaimer ([#2610](https://github.com/ReVanced/revanced-patches/issues/2610)) ([2fdc4c2](https://github.com/ReVanced/revanced-patches/commit/2fdc4c23b5f39153ad71071359274c39129d691f))
|
||||
* **YouTube:** Shorten setting titles to fit on screen ([#2579](https://github.com/ReVanced/revanced-patches/issues/2579)) ([b2a5dd3](https://github.com/ReVanced/revanced-patches/commit/b2a5dd3efc39ae8a42159858b9c00b5b2f8655a4))
|
||||
|
||||
|
||||
### Code Refactoring
|
||||
|
||||
* Fix package and code structure ([#2541](https://github.com/ReVanced/revanced-patches/issues/2541)) ([a08457e](https://github.com/ReVanced/revanced-patches/commit/a08457e406f4b2e37458a4835c11d370a02d2ce6))
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* **Change package name:** Mention caveat of the patch in the description ([427b81a](https://github.com/ReVanced/revanced-patches/commit/427b81a79a5a1de79f14d2261059fb098b22227f))
|
||||
* **ID Austria:** Remove constraint on any version ([#2526](https://github.com/ReVanced/revanced-patches/issues/2526)) ([de2cb88](https://github.com/ReVanced/revanced-patches/commit/de2cb886169b3963b9ed70154bde0b7c6baaae40))
|
||||
* Move strings to resources for localization ([#2440](https://github.com/ReVanced/revanced-patches/issues/2440)) ([060ab8f](https://github.com/ReVanced/revanced-patches/commit/060ab8fbfeee212f9a93f52f4d24584f2c630047))
|
||||
* **MyFitnessPal:** Add `Hide ads` patch ([#2594](https://github.com/ReVanced/revanced-patches/issues/2594)) ([fd4b3c7](https://github.com/ReVanced/revanced-patches/commit/fd4b3c79a83f8de6256611629263d3e29e66f2c2))
|
||||
* **Photomath:** Add `Hide update popup` patch ([#2637](https://github.com/ReVanced/revanced-patches/issues/2637)) ([fbbecd3](https://github.com/ReVanced/revanced-patches/commit/fbbecd33bbc92999d79d74f0abf54d129e3ee407))
|
||||
* **Tiktok - Playback speed:** Remember playback speed ([#2506](https://github.com/ReVanced/revanced-patches/issues/2506)) ([d2970e5](https://github.com/ReVanced/revanced-patches/commit/d2970e54fbbd7e4b1ae1d354ae2d5c4bbe9336b0))
|
||||
* **YouTube - Change header:** Change to ReVanced borderless logo header by default ([#2512](https://github.com/ReVanced/revanced-patches/issues/2512)) ([75f785d](https://github.com/ReVanced/revanced-patches/commit/75f785d1ef6026cbbdf7073c10aace1b28d93a30))
|
||||
* **YouTube - Spoof app version:** Add `18.09.39` to restore library tab ([#2643](https://github.com/ReVanced/revanced-patches/issues/2643)) ([dd108ff](https://github.com/ReVanced/revanced-patches/commit/dd108ff70f54c16694624ab30d3e1085ac0c215a))
|
||||
* **YouTube:** Improve patch descriptions ([#2519](https://github.com/ReVanced/revanced-patches/issues/2519)) ([e8d1389](https://github.com/ReVanced/revanced-patches/commit/e8d1389d3367b2fb688f0b85c136c512981b4fdc))
|
||||
* **YouTube:** Support version `19.02.34` ([#2627](https://github.com/ReVanced/revanced-patches/issues/2627)) ([94e08b7](https://github.com/ReVanced/revanced-patches/commit/94e08b74ced394abf9ae7d4fe6355bfe4d0be248))
|
||||
* **YouTube:** Support version `19.03.35` ([#2640](https://github.com/ReVanced/revanced-patches/issues/2640)) ([ff08f58](https://github.com/ReVanced/revanced-patches/commit/ff08f58ac4ff4d66a8dce599caa1ce47f3366fc6))
|
||||
* **YouTube:** Support versions `18.48.39`, `18.49.37` and `19.01.34` ([#2551](https://github.com/ReVanced/revanced-patches/issues/2551)) ([a938e73](https://github.com/ReVanced/revanced-patches/commit/a938e736fa2aed1792cfdce5656efa15d0791d71))
|
||||
|
||||
|
||||
### BREAKING CHANGES
|
||||
|
||||
* **Photomath:** Some packages have changed locations.
|
||||
* Various APIs have been changed.
|
||||
* Various public APIs have changed names and packages or were removed entirely
|
||||
|
||||
# [4.0.0-dev.15](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.14...v4.0.0-dev.15) (2024-01-27)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* **Photomath:** Add `Hide update popup` patch ([#2637](https://github.com/ReVanced/revanced-patches/issues/2637)) ([fbbecd3](https://github.com/ReVanced/revanced-patches/commit/fbbecd33bbc92999d79d74f0abf54d129e3ee407))
|
||||
|
||||
|
||||
### BREAKING CHANGES
|
||||
|
||||
* **Photomath:** Some packages have changed locations.
|
||||
|
||||
# [4.0.0-dev.14](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.13...v4.0.0-dev.14) (2024-01-27)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* **YouTube - Spoof app version:** Add `18.09.39` to restore library tab ([#2643](https://github.com/ReVanced/revanced-patches/issues/2643)) ([dd108ff](https://github.com/ReVanced/revanced-patches/commit/dd108ff70f54c16694624ab30d3e1085ac0c215a))
|
||||
|
||||
# [4.0.0-dev.13](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.12...v4.0.0-dev.13) (2024-01-27)
|
||||
|
||||
|
||||
|
||||
@@ -418,8 +418,14 @@ public final class app/revanced/patches/photomath/detection/signature/SignatureD
|
||||
public synthetic fun execute (Lapp/revanced/patcher/data/Context;)V
|
||||
}
|
||||
|
||||
public final class app/revanced/patches/photomath/misc/unlockplus/UnlockPlusPatch : app/revanced/patcher/patch/BytecodePatch {
|
||||
public static final field INSTANCE Lapp/revanced/patches/photomath/misc/unlockplus/UnlockPlusPatch;
|
||||
public final class app/revanced/patches/photomath/misc/annoyances/HideUpdatePopupPatch : app/revanced/patcher/patch/BytecodePatch {
|
||||
public static final field INSTANCE Lapp/revanced/patches/photomath/misc/annoyances/HideUpdatePopupPatch;
|
||||
public fun execute (Lapp/revanced/patcher/data/BytecodeContext;)V
|
||||
public synthetic fun execute (Lapp/revanced/patcher/data/Context;)V
|
||||
}
|
||||
|
||||
public final class app/revanced/patches/photomath/misc/unlock/plus/UnlockPlusPatch : app/revanced/patcher/patch/BytecodePatch {
|
||||
public static final field INSTANCE Lapp/revanced/patches/photomath/misc/unlock/plus/UnlockPlusPatch;
|
||||
public fun execute (Lapp/revanced/patcher/data/BytecodeContext;)V
|
||||
public synthetic fun execute (Lapp/revanced/patcher/data/Context;)V
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
org.gradle.parallel = true
|
||||
org.gradle.caching = true
|
||||
kotlin.code.style = official
|
||||
version = 4.0.0-dev.13
|
||||
version = 4.0.1
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1,26 @@
|
||||
package app.revanced.patches.photomath.misc.annoyances
|
||||
|
||||
import app.revanced.patcher.data.BytecodeContext
|
||||
import app.revanced.patcher.extensions.InstructionExtensions.addInstructions
|
||||
import app.revanced.patcher.patch.BytecodePatch
|
||||
import app.revanced.patcher.patch.annotation.CompatiblePackage
|
||||
import app.revanced.patcher.patch.annotation.Patch
|
||||
import app.revanced.patches.photomath.detection.signature.SignatureDetectionPatch
|
||||
import app.revanced.patches.photomath.misc.annoyances.fingerprints.HideUpdatePopupFingerprint
|
||||
import app.revanced.util.exception
|
||||
|
||||
@Patch(
|
||||
name = "Hide update popup",
|
||||
description = "Prevents the update popup from showing up.",
|
||||
dependencies = [SignatureDetectionPatch::class],
|
||||
compatiblePackages = [CompatiblePackage("com.microblink.photomath", ["8.32.0"])]
|
||||
)
|
||||
@Suppress("unused")
|
||||
object HideUpdatePopupPatch : BytecodePatch(
|
||||
setOf(HideUpdatePopupFingerprint)
|
||||
) {
|
||||
override fun execute(context: BytecodeContext) = HideUpdatePopupFingerprint.result?.mutableMethod?.addInstructions(
|
||||
2, // Insert after the null check.
|
||||
"return-void"
|
||||
) ?: throw HideUpdatePopupFingerprint.exception
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
package app.revanced.patches.photomath.misc.annoyances.fingerprints
|
||||
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.MethodFingerprint
|
||||
import com.android.tools.smali.dexlib2.AccessFlags
|
||||
import com.android.tools.smali.dexlib2.Opcode
|
||||
|
||||
internal object HideUpdatePopupFingerprint : MethodFingerprint(
|
||||
customFingerprint = { _, classDef ->
|
||||
// The popup is shown only in the main activity
|
||||
classDef.type == "Lcom/microblink/photomath/main/activity/MainActivity;"
|
||||
},
|
||||
opcodes = listOf(
|
||||
Opcode.CONST_HIGH16,
|
||||
Opcode.INVOKE_VIRTUAL, // ViewPropertyAnimator.alpha(1.0f)
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CONST_WIDE_16,
|
||||
Opcode.INVOKE_VIRTUAL, // ViewPropertyAnimator.setDuration(1000L)
|
||||
),
|
||||
accessFlags = AccessFlags.FINAL or AccessFlags.PUBLIC,
|
||||
returnType = "V",
|
||||
)
|
||||
@@ -1,11 +1,11 @@
|
||||
package app.revanced.patches.photomath.misc.bookpoint
|
||||
package app.revanced.patches.photomath.misc.unlock.bookpoint
|
||||
|
||||
import app.revanced.util.exception
|
||||
import app.revanced.patcher.data.BytecodeContext
|
||||
import app.revanced.patcher.extensions.InstructionExtensions.replaceInstructions
|
||||
import app.revanced.patcher.patch.BytecodePatch
|
||||
import app.revanced.patcher.patch.annotation.Patch
|
||||
import app.revanced.patches.photomath.misc.bookpoint.fingerprints.IsBookpointEnabledFingerprint
|
||||
import app.revanced.patches.photomath.misc.unlock.bookpoint.fingerprints.IsBookpointEnabledFingerprint
|
||||
|
||||
@Patch(description = "Enables textbook access")
|
||||
internal object EnableBookpointPatch : BytecodePatch(
|
||||
@@ -1,4 +1,4 @@
|
||||
package app.revanced.patches.photomath.misc.bookpoint.fingerprints
|
||||
package app.revanced.patches.photomath.misc.unlock.bookpoint.fingerprints
|
||||
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.MethodFingerprint
|
||||
@@ -1,4 +1,4 @@
|
||||
package app.revanced.patches.photomath.misc.unlockplus
|
||||
package app.revanced.patches.photomath.misc.unlock.plus
|
||||
|
||||
import app.revanced.util.exception
|
||||
import app.revanced.patcher.data.BytecodeContext
|
||||
@@ -7,8 +7,8 @@ import app.revanced.patcher.patch.BytecodePatch
|
||||
import app.revanced.patcher.patch.annotation.CompatiblePackage
|
||||
import app.revanced.patcher.patch.annotation.Patch
|
||||
import app.revanced.patches.photomath.detection.signature.SignatureDetectionPatch
|
||||
import app.revanced.patches.photomath.misc.bookpoint.EnableBookpointPatch
|
||||
import app.revanced.patches.photomath.misc.unlockplus.fingerprints.IsPlusUnlockedFingerprint
|
||||
import app.revanced.patches.photomath.misc.unlock.bookpoint.EnableBookpointPatch
|
||||
import app.revanced.patches.photomath.misc.unlock.plus.fingerprints.IsPlusUnlockedFingerprint
|
||||
|
||||
@Patch(
|
||||
name = "Unlock plus",
|
||||
@@ -1,4 +1,4 @@
|
||||
package app.revanced.patches.photomath.misc.unlockplus.fingerprints
|
||||
package app.revanced.patches.photomath.misc.unlock.plus.fingerprints
|
||||
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.MethodFingerprint
|
||||
@@ -30,7 +30,7 @@ abstract class BasePreference(
|
||||
*/
|
||||
open fun serialize(ownerDocument: Document, resourceCallback: (BaseResource) -> Unit): Element =
|
||||
ownerDocument.createElement(tag).apply {
|
||||
setAttribute("android:key", key)
|
||||
key?.let { setAttribute("android:key", it) }
|
||||
setAttribute("android:title", "@string/${titleKey}")
|
||||
summaryKey?.let { addSummary(it) }
|
||||
}
|
||||
|
||||
@@ -6,6 +6,7 @@ import app.revanced.patcher.patch.annotation.CompatiblePackage
|
||||
import app.revanced.patcher.patch.annotation.Patch
|
||||
import app.revanced.patcher.patch.options.PatchOption.PatchExtensions.stringPatchOption
|
||||
import app.revanced.util.ResourceGroup
|
||||
import app.revanced.util.Utils.trimIndentMultiline
|
||||
import app.revanced.util.copyResources
|
||||
import java.io.File
|
||||
import java.nio.file.Files
|
||||
@@ -64,10 +65,7 @@ object CustomBrandingPatch : ResourcePatch() {
|
||||
Each of these folders has to have the following files:
|
||||
|
||||
${iconResourceFileNames.joinToString("\n") { "- $it" }}
|
||||
"""
|
||||
.split("\n")
|
||||
.joinToString("\n") { it.trimIndent() } // Remove the leading whitespace from each line.
|
||||
.trimIndent(), // Remove the leading newline.
|
||||
""".trimIndentMultiline()
|
||||
)
|
||||
|
||||
override fun execute(context: ResourceContext) {
|
||||
|
||||
@@ -7,6 +7,7 @@ import app.revanced.patcher.patch.annotation.CompatiblePackage
|
||||
import app.revanced.patcher.patch.annotation.Patch
|
||||
import app.revanced.patcher.patch.options.PatchOption.PatchExtensions.stringPatchOption
|
||||
import app.revanced.util.ResourceGroup
|
||||
import app.revanced.util.Utils.trimIndentMultiline
|
||||
import app.revanced.util.copyResources
|
||||
import java.io.File
|
||||
|
||||
@@ -56,7 +57,7 @@ object ChangeHeaderPatch : ResourcePatch() {
|
||||
These folders must contain the following files:
|
||||
|
||||
${variants.joinToString("\n") { variant -> "- ${HEADER_NAME}_$variant.png" }}
|
||||
""".trimIndent(),
|
||||
""".trimIndentMultiline(),
|
||||
required = true,
|
||||
)
|
||||
|
||||
|
||||
8
src/main/kotlin/app/revanced/util/Utils.kt
Normal file
8
src/main/kotlin/app/revanced/util/Utils.kt
Normal file
@@ -0,0 +1,8 @@
|
||||
package app.revanced.util
|
||||
|
||||
internal object Utils {
|
||||
internal fun String.trimIndentMultiline() =
|
||||
this.split("\n")
|
||||
.joinToString("\n") { it.trimIndent() } // Remove the leading whitespace from each line.
|
||||
.trimIndent() // Remove the leading newline.
|
||||
}
|
||||
@@ -7,10 +7,12 @@
|
||||
<item>@string/revanced_spoof_app_version_target_entry_3</item>
|
||||
<item>@string/revanced_spoof_app_version_target_entry_4</item>
|
||||
<item>@string/revanced_spoof_app_version_target_entry_5</item>
|
||||
<item>@string/revanced_spoof_app_version_target_entry_6</item>
|
||||
</string-array>
|
||||
<string-array name="revanced_spoof_app_version_target_entry_values">
|
||||
<item>18.33.40</item>
|
||||
<item>18.20.39</item>
|
||||
<item>18.09.39</item>
|
||||
<item>17.08.35</item>
|
||||
<item>16.08.35</item>
|
||||
<item>16.01.35</item>
|
||||
|
||||
@@ -782,9 +782,10 @@
|
||||
<string name="revanced_spoof_app_version_target_title">Spoof app version target</string>
|
||||
<string name="revanced_spoof_app_version_target_entry_1">18.33.40 - Restore RYD Shorts incognito mode</string>
|
||||
<string name="revanced_spoof_app_version_target_entry_2">18.20.39 - Restore wide video speed & quality menu</string>
|
||||
<string name="revanced_spoof_app_version_target_entry_3">17.08.35 - Restore old UI layout</string>
|
||||
<string name="revanced_spoof_app_version_target_entry_4">16.08.35 - Restore explore tab</string>
|
||||
<string name="revanced_spoof_app_version_target_entry_5">16.01.35 - Restore fewer video player action buttons</string>
|
||||
<string name="revanced_spoof_app_version_target_entry_3">18.09.39 - Restore library tab</string>
|
||||
<string name="revanced_spoof_app_version_target_entry_4">17.08.35 - Restore old UI layout</string>
|
||||
<string name="revanced_spoof_app_version_target_entry_5">16.08.35 - Restore explore tab</string>
|
||||
<string name="revanced_spoof_app_version_target_entry_6">16.01.35 - Restore fewer video player action buttons</string>
|
||||
</patch>
|
||||
<patch id="layout.startpage.ChangeStartPagePatch">
|
||||
<string name="revanced_start_page_title">Set start page</string>
|
||||
|
||||
Reference in New Issue
Block a user