refactor: simplify use of dependencies field in Dependencies annotations
This commit is contained in:
@@ -15,11 +15,7 @@ import org.w3c.dom.Element
|
||||
import java.io.File
|
||||
|
||||
@Patch
|
||||
@Dependencies(
|
||||
dependencies = [
|
||||
FixLocaleConfigErrorPatch::class
|
||||
]
|
||||
)
|
||||
@Dependencies([FixLocaleConfigErrorPatch::class])
|
||||
@Name("amoled")
|
||||
@Description("Enables pure black theme.")
|
||||
@AmoledCompatibility
|
||||
|
||||
+1
-1
@@ -18,7 +18,7 @@ import app.revanced.patches.youtube.misc.mapping.patch.ResourceIdMappingProvider
|
||||
import org.jf.dexlib2.iface.instruction.WideLiteralInstruction
|
||||
|
||||
@Patch
|
||||
@Dependencies(dependencies = [ResourceIdMappingProviderResourcePatch::class])
|
||||
@Dependencies([ResourceIdMappingProviderResourcePatch::class])
|
||||
@Name("hide-autoplay-button")
|
||||
@Description("Disables the autoplay button.")
|
||||
@AutoplayButtonCompatibility
|
||||
|
||||
+2
-4
@@ -17,9 +17,7 @@ import java.nio.file.StandardCopyOption
|
||||
import kotlin.io.path.exists
|
||||
|
||||
@Patch
|
||||
@Dependencies(
|
||||
dependencies = [FixLocaleConfigErrorPatch::class]
|
||||
)
|
||||
@Dependencies([FixLocaleConfigErrorPatch::class])
|
||||
@Name("premium-heading")
|
||||
@Description("Shows premium branding on the YouTube home screen.")
|
||||
@PremiumHeadingCompatibility
|
||||
@@ -34,7 +32,7 @@ class PremiumHeadingPatch : ResourcePatch() {
|
||||
|
||||
arrayOf("xxxhdpi", "xxhdpi", "xhdpi", "hdpi", "mdpi").forEach { size ->
|
||||
val headingDirectory = resDirectory.resolve("drawable-$size")
|
||||
modes.forEach {mode ->
|
||||
modes.forEach { mode ->
|
||||
val fromPath = headingDirectory.resolve("${original}_$mode.png").toPath()
|
||||
val toPath = headingDirectory.resolve("${replacement}_$mode.png").toPath()
|
||||
|
||||
|
||||
+1
-3
@@ -15,9 +15,7 @@ import app.revanced.patches.youtube.misc.manifest.patch.FixLocaleConfigErrorPatc
|
||||
import java.nio.file.Files
|
||||
|
||||
@Patch
|
||||
@Dependencies(
|
||||
dependencies = [FixLocaleConfigErrorPatch::class]
|
||||
)
|
||||
@Dependencies([FixLocaleConfigErrorPatch::class])
|
||||
@Name("custom-branding")
|
||||
@Description("Changes the branding of YouTube.")
|
||||
@CustomBrandingCompatibility
|
||||
|
||||
+1
-1
@@ -14,7 +14,7 @@ import app.revanced.patches.youtube.layout.castbutton.annotations.CastButtonComp
|
||||
import app.revanced.patches.youtube.misc.integrations.patch.IntegrationsPatch
|
||||
|
||||
@Patch
|
||||
@Dependencies(dependencies = [IntegrationsPatch::class])
|
||||
@Dependencies([IntegrationsPatch::class])
|
||||
@Name("hide-cast-button")
|
||||
@Description("Hides the cast button.")
|
||||
@CastButtonCompatibility
|
||||
|
||||
+1
-1
@@ -22,7 +22,7 @@ import org.jf.dexlib2.iface.instruction.WideLiteralInstruction
|
||||
import org.jf.dexlib2.iface.reference.MethodReference
|
||||
|
||||
@Patch
|
||||
@Dependencies(dependencies = [IntegrationsPatch::class, ResourceIdMappingProviderResourcePatch::class])
|
||||
@Dependencies([IntegrationsPatch::class, ResourceIdMappingProviderResourcePatch::class])
|
||||
@Name("disable-create-button")
|
||||
@Description("Disables the create button.")
|
||||
@CreateButtonCompatibility
|
||||
|
||||
+1
-1
@@ -20,7 +20,7 @@ import org.jf.dexlib2.Opcode
|
||||
import org.jf.dexlib2.builder.instruction.BuilderInstruction21t
|
||||
|
||||
@Patch
|
||||
@Dependencies(dependencies = [IntegrationsPatch::class])
|
||||
@Dependencies([IntegrationsPatch::class])
|
||||
@Name("old-quality-layout")
|
||||
@Description("Enables the original quality flyout menu.")
|
||||
@OldQualityLayoutCompatibility
|
||||
|
||||
+1
-1
@@ -17,7 +17,7 @@ import app.revanced.patches.youtube.misc.integrations.patch.IntegrationsPatch
|
||||
import org.jf.dexlib2.iface.instruction.OneRegisterInstruction
|
||||
|
||||
@Patch
|
||||
@Dependencies(dependencies = [IntegrationsPatch::class])
|
||||
@Dependencies([IntegrationsPatch::class])
|
||||
@Name("hide-shorts-button")
|
||||
@Description("Hides the shorts button.")
|
||||
@ShortsButtonCompatibility
|
||||
|
||||
+1
-1
@@ -19,7 +19,7 @@ import app.revanced.patches.youtube.layout.watermark.fingerprints.HideWatermarkF
|
||||
import app.revanced.patches.youtube.misc.integrations.patch.IntegrationsPatch
|
||||
|
||||
@Patch
|
||||
@Dependencies(dependencies = [IntegrationsPatch::class])
|
||||
@Dependencies([IntegrationsPatch::class])
|
||||
@Name("hide-watermark")
|
||||
@Description("Hides the creator's watermark on videos.")
|
||||
@HideWatermarkCompatibility
|
||||
|
||||
+1
-1
@@ -21,7 +21,7 @@ import app.revanced.patches.youtube.layout.widesearchbar.fingerprints.WideSearch
|
||||
import app.revanced.patches.youtube.misc.integrations.patch.IntegrationsPatch
|
||||
|
||||
@Patch(include = false)
|
||||
@Dependencies(dependencies = [IntegrationsPatch::class])
|
||||
@Dependencies([IntegrationsPatch::class])
|
||||
@Name("enable-wide-searchbar")
|
||||
@Description("Replaces the search icon with a wide search bar. This will hide the YouTube logo when active.")
|
||||
@WideSearchbarCompatibility
|
||||
|
||||
Reference in New Issue
Block a user