diff --git a/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/autorepeat/fingerprints/AutoNavInformerFingerprint.kt b/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/alwaysrepeat/fingerprints/AutoNavInformerFingerprint.kt
similarity index 90%
rename from src/main/kotlin/app/revanced/patches/youtube/overlaybutton/autorepeat/fingerprints/AutoNavInformerFingerprint.kt
rename to src/main/kotlin/app/revanced/patches/youtube/overlaybutton/alwaysrepeat/fingerprints/AutoNavInformerFingerprint.kt
index 64bfdd44f..6dc7dd2be 100644
--- a/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/autorepeat/fingerprints/AutoNavInformerFingerprint.kt
+++ b/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/alwaysrepeat/fingerprints/AutoNavInformerFingerprint.kt
@@ -1,4 +1,4 @@
-package app.revanced.patches.youtube.overlaybutton.autorepeat.fingerprints
+package app.revanced.patches.youtube.overlaybutton.alwaysrepeat.fingerprints
import app.revanced.patcher.extensions.or
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
diff --git a/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/autorepeat/fingerprints/VideoEndFingerprint.kt b/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/alwaysrepeat/fingerprints/VideoEndFingerprint.kt
similarity index 85%
rename from src/main/kotlin/app/revanced/patches/youtube/overlaybutton/autorepeat/fingerprints/VideoEndFingerprint.kt
rename to src/main/kotlin/app/revanced/patches/youtube/overlaybutton/alwaysrepeat/fingerprints/VideoEndFingerprint.kt
index 0975e2198..cc120cde9 100644
--- a/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/autorepeat/fingerprints/VideoEndFingerprint.kt
+++ b/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/alwaysrepeat/fingerprints/VideoEndFingerprint.kt
@@ -1,4 +1,4 @@
-package app.revanced.patches.youtube.overlaybutton.autorepeat.fingerprints
+package app.revanced.patches.youtube.overlaybutton.alwaysrepeat.fingerprints
import app.revanced.patcher.extensions.or
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
diff --git a/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/autorepeat/fingerprints/VideoEndParentFingerprint.kt b/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/alwaysrepeat/fingerprints/VideoEndParentFingerprint.kt
similarity index 84%
rename from src/main/kotlin/app/revanced/patches/youtube/overlaybutton/autorepeat/fingerprints/VideoEndParentFingerprint.kt
rename to src/main/kotlin/app/revanced/patches/youtube/overlaybutton/alwaysrepeat/fingerprints/VideoEndParentFingerprint.kt
index c4c018d16..d0d9f7207 100644
--- a/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/autorepeat/fingerprints/VideoEndParentFingerprint.kt
+++ b/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/alwaysrepeat/fingerprints/VideoEndParentFingerprint.kt
@@ -1,4 +1,4 @@
-package app.revanced.patches.youtube.overlaybutton.autorepeat.fingerprints
+package app.revanced.patches.youtube.overlaybutton.alwaysrepeat.fingerprints
import app.revanced.patcher.extensions.or
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
diff --git a/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/autorepeat/patch/AutoRepeatPatch.kt b/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/alwaysrepeat/patch/AlwaysRepeatPatch.kt
similarity index 85%
rename from src/main/kotlin/app/revanced/patches/youtube/overlaybutton/autorepeat/patch/AutoRepeatPatch.kt
rename to src/main/kotlin/app/revanced/patches/youtube/overlaybutton/alwaysrepeat/patch/AlwaysRepeatPatch.kt
index f8ca72c03..e0af4045d 100644
--- a/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/autorepeat/patch/AutoRepeatPatch.kt
+++ b/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/alwaysrepeat/patch/AlwaysRepeatPatch.kt
@@ -1,4 +1,4 @@
-package app.revanced.patches.youtube.overlaybutton.autorepeat.patch
+package app.revanced.patches.youtube.overlaybutton.alwaysrepeat.patch
import app.revanced.extensions.toErrorResult
import app.revanced.patcher.annotation.Name
@@ -15,9 +15,9 @@ import app.revanced.patcher.patch.PatchResult
import app.revanced.patcher.patch.PatchResultSuccess
import app.revanced.patcher.util.proxy.mutableTypes.MutableMethod
import app.revanced.patcher.util.smali.ExternalLabel
-import app.revanced.patches.youtube.overlaybutton.autorepeat.fingerprints.AutoNavInformerFingerprint
-import app.revanced.patches.youtube.overlaybutton.autorepeat.fingerprints.VideoEndFingerprint
-import app.revanced.patches.youtube.overlaybutton.autorepeat.fingerprints.VideoEndParentFingerprint
+import app.revanced.patches.youtube.overlaybutton.alwaysrepeat.fingerprints.AutoNavInformerFingerprint
+import app.revanced.patches.youtube.overlaybutton.alwaysrepeat.fingerprints.VideoEndFingerprint
+import app.revanced.patches.youtube.overlaybutton.alwaysrepeat.fingerprints.VideoEndParentFingerprint
import app.revanced.patches.youtube.utils.annotations.YouTubeCompatibility
import app.revanced.patches.youtube.utils.fingerprints.PlayerPatchFingerprint
import app.revanced.util.integrations.Constants.INTEGRATIONS_PATH
@@ -28,7 +28,7 @@ import org.jf.dexlib2.iface.instruction.OneRegisterInstruction
@Name("always-repeat")
@YouTubeCompatibility
@Version("0.0.1")
-class AutoRepeatPatch : BytecodePatch(
+class AlwaysRepeatPatch : BytecodePatch(
listOf(
AutoNavInformerFingerprint,
PlayerPatchFingerprint,
@@ -42,11 +42,11 @@ class AutoRepeatPatch : BytecodePatch(
addInstructionsWithLabels(
0, """
invoke-static {}, $UTILS_PATH/AlwaysRepeatPatch;->shouldRepeatAndPause()V
- invoke-static {}, $VIDEO_PATH/VideoInformation;->shouldAutoRepeat()Z
+ invoke-static {}, $VIDEO_PATH/VideoInformation;->shouldAlwaysRepeat()Z
move-result v0
- if-eqz v0, :notrepeat
+ if-eqz v0, :end
return-void
- """, ExternalLabel("notrepeat", getInstruction(0))
+ """, ExternalLabel("end", getInstruction(0))
)
}
} ?: return VideoEndFingerprint.toErrorResult()
diff --git a/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/general/patch/OverlayButtonsPatch.kt b/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/general/patch/OverlayButtonsPatch.kt
index d710c4e4a..e3133e8d6 100644
--- a/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/general/patch/OverlayButtonsPatch.kt
+++ b/src/main/kotlin/app/revanced/patches/youtube/overlaybutton/general/patch/OverlayButtonsPatch.kt
@@ -10,7 +10,7 @@ import app.revanced.patcher.patch.PatchResultSuccess
import app.revanced.patcher.patch.ResourcePatch
import app.revanced.patcher.patch.annotations.DependsOn
import app.revanced.patcher.patch.annotations.Patch
-import app.revanced.patches.youtube.overlaybutton.autorepeat.patch.AutoRepeatPatch
+import app.revanced.patches.youtube.overlaybutton.alwaysrepeat.patch.AlwaysRepeatPatch
import app.revanced.patches.youtube.utils.annotations.YouTubeCompatibility
import app.revanced.patches.youtube.utils.overridespeed.patch.OverrideSpeedHookPatch
import app.revanced.patches.youtube.utils.playerbutton.patch.PlayerButtonHookPatch
@@ -26,10 +26,10 @@ import org.w3c.dom.Element
@Patch
@Name("overlay-buttons")
-@Description("Add overlay buttons to the player such as copy video link, auto-repeat, download and speed control.")
+@Description("Add overlay buttons to the player.")
@DependsOn(
[
- AutoRepeatPatch::class,
+ AlwaysRepeatPatch::class,
OverrideSpeedHookPatch::class,
PlayerButtonHookPatch::class,
PlayerControlsPatch::class,
@@ -47,11 +47,11 @@ class OverlayButtonsPatch : ResourcePatch {
* Inject hook
*/
arrayOf(
- "Download",
- "AutoRepeat",
- "CopyWithTimeStamp",
- "Copy",
- "Speed"
+ "AlwaysRepeat",
+ "CopyVideoUrl",
+ "CopyVideoUrlTimestamp",
+ "ExternalDownload",
+ "SpeedDialog"
).forEach {
PlayerControlsPatch.initializeControl("$BUTTON_PATH/$it;")
PlayerControlsPatch.injectVisibility("$BUTTON_PATH/$it;")
@@ -111,7 +111,7 @@ class OverlayButtonsPatch : ResourcePatch {
// Change the relationship between buttons
it.getAttributeNode("yt:layout_constraintRight_toLeftOf")?.let { attribute ->
if (attribute.textContent == "@id/fullscreen_button") {
- attribute.textContent = "@+id/speed_button"
+ attribute.textContent = "@+id/speed_dialog_button"
}
}
diff --git a/src/main/resources/youtube/overlaybuttons/host/layout/youtube_controls_bottom_ui_container.xml b/src/main/resources/youtube/overlaybuttons/host/layout/youtube_controls_bottom_ui_container.xml
index 4a9af3c94..6a3bb5372 100644
--- a/src/main/resources/youtube/overlaybuttons/host/layout/youtube_controls_bottom_ui_container.xml
+++ b/src/main/resources/youtube/overlaybuttons/host/layout/youtube_controls_bottom_ui_container.xml
@@ -1,8 +1,8 @@
-
-
-
-
-
+
+
+
+
+
diff --git a/src/main/resources/youtube/overlaybuttons/host/values/arrays.xml b/src/main/resources/youtube/overlaybuttons/host/values/arrays.xml
index f736212ba..df2983ba3 100644
--- a/src/main/resources/youtube/overlaybuttons/host/values/arrays.xml
+++ b/src/main/resources/youtube/overlaybuttons/host/values/arrays.xml
@@ -1,18 +1,18 @@
-
+
- NewPipe
- NewPipe x SponsorBlock
- Seal
- YTDLnis
-
+
- org.schabi.newpipe
- org.polymorphicshade.newpipe
- com.junkfood.seal
- com.deniscerri.ytdl
-
+
- https://github.com/TeamNewPipe/NewPipe/releases/latest
- https://github.com/polymorphicshade/NewPipe/releases/latest
- https://github.com/JunkFood02/Seal/releases/latest
diff --git a/src/main/resources/youtube/settings/host/values/strings.xml b/src/main/resources/youtube/settings/host/values/strings.xml
index 3727f9b1e..4291aa6ba 100644
--- a/src/main/resources/youtube/settings/host/values/strings.xml
+++ b/src/main/resources/youtube/settings/host/values/strings.xml
@@ -16,7 +16,7 @@
Current homepage: Subscriptions
Change homepage to subscriptions
Comments
- Time Stamp copied to clipboard
+ Time Stamp copied to clipboard
Filter components by line-separated names
Edit custom filter
Custom filter is disabled
@@ -65,11 +65,6 @@
Disable QUIC protocol
The amount of seconds the double press back to exit
Double back timeout
- is not installed. Please install it.
- "Package name of the downloader app such as NewPipe's"
- Downloader package name
- Default downloader related settings
- Downloader settings
Compact controls overlay is disabled
Compact controls overlay is enabled
Enable compact controls overlay
@@ -150,6 +145,13 @@
Export settings
Report issues or leave suggestions here
Support Center
+ Installed
+ Package name of your installed external downloader app, such as NewPipe or YTDLnis
+ External downloader package name
+ Not installed
+ %s is not installed. Please install it.
+ Settings for using an external downloader
+ External downloader settings
Flyout menu
Fullscreen
General
@@ -481,22 +483,22 @@
Open library on app startup
Others
Overlay button
- Auto repeat button is hidden
- Auto repeat button is shown
- Show auto repeat button
- Copy link button is hidden
- Copy link button is shown
- Show copy link button
- Copy link with timestamp button is hidden
- Copy link with timestamp button is shown
- Show copy link with timestamp button
- Download button is hidden
- Download button is shown
- Show download button
- Video speed reseted (1.0x)
- Speed button is hidden
- Speed button is shown
- Show speed button
+ Tap and hold to toggle pause after repeat states
+ "Tap to toggle always repeat states
+Tap and hold to toggle pause after repeat states"
+ Show always repeat button
+ "Tap to copy video URL
+Tap and hold to copy video URL with timestamp"
+ Show copy video URL button
+ "Tap to copy video URL with timestamp
+Tap and hold to copy video timestamp"
+ Show copy timestamp URL button
+ Tap to launch external downloader
+ Show external download button
+ Video speed reseted (1.0x)
+ "Tap to open speed dialog
+Tap and hold to set video speed to 1.0x"
+ Show speed button
Current Header: Default Header
Current Header: Premium Header
Premium Header
diff --git a/src/main/resources/youtube/settings/xml/revanced_prefs.xml b/src/main/resources/youtube/settings/xml/revanced_prefs.xml
index 2759714bd..9b52a601a 100644
--- a/src/main/resources/youtube/settings/xml/revanced_prefs.xml
+++ b/src/main/resources/youtube/settings/xml/revanced_prefs.xml
@@ -414,14 +414,14 @@