mirror of
https://github.com/inotia00/revanced-patches.git
synced 2025-05-09 02:54:37 +02:00
fix(YouTube Music/Replace dismiss queue): use built-in icons
This commit is contained in:
parent
7d44bd6c49
commit
0ef43e4a0b
@ -8,7 +8,6 @@ import app.revanced.patcher.patch.annotation.CompatiblePackage
|
||||
import app.revanced.patcher.patch.annotation.Patch
|
||||
import app.revanced.patches.music.flyoutpanel.utils.EnumUtils.getEnumIndex
|
||||
import app.revanced.patches.music.utils.fingerprints.MenuItemFingerprint
|
||||
import app.revanced.patches.music.utils.flyoutbutton.FlyoutButtonItemResourcePatch
|
||||
import app.revanced.patches.music.utils.integrations.Constants.FLYOUT
|
||||
import app.revanced.patches.music.utils.settings.CategoryType
|
||||
import app.revanced.patches.music.utils.settings.SettingsPatch
|
||||
@ -20,7 +19,6 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
|
||||
name = "Replace dismiss queue",
|
||||
description = "Adds an option to replace \"Dismiss queue\" with \"Watch on YouTube\" in the flyout menu.",
|
||||
dependencies = [
|
||||
FlyoutButtonItemResourcePatch::class,
|
||||
SettingsPatch::class,
|
||||
VideoInformationPatch::class
|
||||
],
|
||||
|
@ -1,29 +0,0 @@
|
||||
package app.revanced.patches.music.utils.flyoutbutton
|
||||
|
||||
import app.revanced.patcher.data.ResourceContext
|
||||
import app.revanced.patcher.patch.ResourcePatch
|
||||
import app.revanced.util.ResourceGroup
|
||||
import app.revanced.util.copyResources
|
||||
|
||||
object FlyoutButtonItemResourcePatch : ResourcePatch() {
|
||||
override fun execute(context: ResourceContext) {
|
||||
|
||||
fun copyResources(resourceGroups: List<ResourceGroup>) {
|
||||
resourceGroups.forEach { context.copyResources("music/flyout", it) }
|
||||
}
|
||||
|
||||
val resourceFileNames = arrayOf(
|
||||
"yt_outline_youtube_logo_icon_black_24"
|
||||
).map { "$it.png" }.toTypedArray()
|
||||
|
||||
fun createGroup(directory: String) = ResourceGroup(
|
||||
directory, *resourceFileNames
|
||||
)
|
||||
|
||||
arrayOf("xxxhdpi", "xxhdpi", "xhdpi", "hdpi", "mdpi")
|
||||
.map { "drawable-$it" }
|
||||
.map(::createGroup)
|
||||
.let(::copyResources)
|
||||
|
||||
}
|
||||
}
|
Binary file not shown.
Before Width: | Height: | Size: 303 B |
Binary file not shown.
Before Width: | Height: | Size: 216 B |
Binary file not shown.
Before Width: | Height: | Size: 410 B |
Binary file not shown.
Before Width: | Height: | Size: 565 B |
Binary file not shown.
Before Width: | Height: | Size: 749 B |
Loading…
x
Reference in New Issue
Block a user