mirror of
https://github.com/inotia00/revanced-patches.git
synced 2025-05-01 23:24:28 +02:00
improve AbstractSettingsResourcePatch
This commit is contained in:
parent
490efb6476
commit
17a18b59b2
@ -21,6 +21,13 @@ abstract class AbstractSettingsResourcePatch(
|
||||
private val isYouTube: Boolean,
|
||||
) : ResourcePatch {
|
||||
override fun execute(context: ResourceContext): PatchResult {
|
||||
/*
|
||||
* Copy strings
|
||||
*/
|
||||
context.copyXmlNode(sourcehostDirectory, "values/strings.xml", "resources")
|
||||
|
||||
/* initialize ReVanced Settings */
|
||||
if (isYouTube) {
|
||||
/*
|
||||
* used for self-restart
|
||||
*/
|
||||
@ -32,13 +39,6 @@ abstract class AbstractSettingsResourcePatch(
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* Copy strings
|
||||
*/
|
||||
context.copyXmlNode(sourcehostDirectory, "values/strings.xml", "resources")
|
||||
|
||||
/* initialize ReVanced Settings */
|
||||
if (isYouTube == true) {
|
||||
context.copyResources(sourceDirectory, ResourceUtils.ResourceGroup("xml", "revanced_prefs.xml"))
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user