mirror of
https://github.com/revanced/revanced-patches.git
synced 2025-04-29 22:24:27 +02:00
fix(YouTube - Hide video action buttons): Add option to hide 'Ask' button (#4852)
This commit is contained in:
parent
f6f06dcd02
commit
43bcf5a098
@ -68,15 +68,19 @@ final class ButtonsFilter extends Filter {
|
|||||||
Settings.HIDE_REMIX_BUTTON,
|
Settings.HIDE_REMIX_BUTTON,
|
||||||
"yt_outline_youtube_shorts_plus"
|
"yt_outline_youtube_shorts_plus"
|
||||||
),
|
),
|
||||||
|
new ByteArrayFilterGroup(
|
||||||
|
Settings.HIDE_THANKS_BUTTON,
|
||||||
|
"yt_outline_dollar_sign_heart"
|
||||||
|
),
|
||||||
|
new ByteArrayFilterGroup(
|
||||||
|
Settings.HIDE_ASK_BUTTON,
|
||||||
|
"yt_fill_spark"
|
||||||
|
),
|
||||||
// Check for clip button both here and using a path filter,
|
// Check for clip button both here and using a path filter,
|
||||||
// as there's a chance the path is a generic action button and won't contain 'clip_button'
|
// as there's a chance the path is a generic action button and won't contain 'clip_button'
|
||||||
new ByteArrayFilterGroup(
|
new ByteArrayFilterGroup(
|
||||||
Settings.HIDE_CLIP_BUTTON,
|
Settings.HIDE_CLIP_BUTTON,
|
||||||
"yt_outline_scissors"
|
"yt_outline_scissors"
|
||||||
),
|
|
||||||
new ByteArrayFilterGroup(
|
|
||||||
Settings.HIDE_THANKS_BUTTON,
|
|
||||||
"yt_outline_dollar_sign_heart"
|
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -199,6 +199,7 @@ public class Settings extends BaseSettings {
|
|||||||
public static final BooleanSetting HIDE_REPORT_BUTTON = new BooleanSetting("revanced_hide_report_button", FALSE);
|
public static final BooleanSetting HIDE_REPORT_BUTTON = new BooleanSetting("revanced_hide_report_button", FALSE);
|
||||||
public static final BooleanSetting HIDE_SHARE_BUTTON = new BooleanSetting("revanced_hide_share_button", FALSE);
|
public static final BooleanSetting HIDE_SHARE_BUTTON = new BooleanSetting("revanced_hide_share_button", FALSE);
|
||||||
public static final BooleanSetting HIDE_THANKS_BUTTON = new BooleanSetting("revanced_hide_thanks_button", TRUE);
|
public static final BooleanSetting HIDE_THANKS_BUTTON = new BooleanSetting("revanced_hide_thanks_button", TRUE);
|
||||||
|
public static final BooleanSetting HIDE_ASK_BUTTON = new BooleanSetting("revanced_hide_ask_button", FALSE);
|
||||||
// Player flyout menu items
|
// Player flyout menu items
|
||||||
public static final BooleanSetting HIDE_PLAYER_FLYOUT_ADDITIONAL_SETTINGS = new BooleanSetting("revanced_hide_player_flyout_additional_settings", FALSE);
|
public static final BooleanSetting HIDE_PLAYER_FLYOUT_ADDITIONAL_SETTINGS = new BooleanSetting("revanced_hide_player_flyout_additional_settings", FALSE);
|
||||||
public static final BooleanSetting HIDE_PLAYER_FLYOUT_AMBIENT_MODE = new BooleanSetting("revanced_hide_player_flyout_ambient_mode", FALSE);
|
public static final BooleanSetting HIDE_PLAYER_FLYOUT_AMBIENT_MODE = new BooleanSetting("revanced_hide_player_flyout_ambient_mode", FALSE);
|
||||||
|
@ -46,10 +46,11 @@ val hideButtonsPatch = resourcePatch(
|
|||||||
SwitchPreference("revanced_hide_remix_button"),
|
SwitchPreference("revanced_hide_remix_button"),
|
||||||
SwitchPreference("revanced_hide_download_button"),
|
SwitchPreference("revanced_hide_download_button"),
|
||||||
SwitchPreference("revanced_hide_thanks_button"),
|
SwitchPreference("revanced_hide_thanks_button"),
|
||||||
|
SwitchPreference("revanced_hide_ask_button"),
|
||||||
SwitchPreference("revanced_hide_clip_button"),
|
SwitchPreference("revanced_hide_clip_button"),
|
||||||
SwitchPreference("revanced_hide_playlist_button"),
|
SwitchPreference("revanced_hide_playlist_button"),
|
||||||
),
|
)
|
||||||
),
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
addLithoFilter("Lapp/revanced/extension/youtube/patches/components/ButtonsFilter;")
|
addLithoFilter("Lapp/revanced/extension/youtube/patches/components/ButtonsFilter;")
|
||||||
|
@ -583,6 +583,11 @@ Adjust volume by swiping vertically on the right side of the screen"</string>
|
|||||||
<string name="revanced_hide_thanks_button_title">Hide Thanks</string>
|
<string name="revanced_hide_thanks_button_title">Hide Thanks</string>
|
||||||
<string name="revanced_hide_thanks_button_summary_on">Thanks button is hidden</string>
|
<string name="revanced_hide_thanks_button_summary_on">Thanks button is hidden</string>
|
||||||
<string name="revanced_hide_thanks_button_summary_off">Thanks button is shown</string>
|
<string name="revanced_hide_thanks_button_summary_off">Thanks button is shown</string>
|
||||||
|
<!-- 'Ask' should be translated with the same localized wording that YouTube displays.
|
||||||
|
Button only shows if the user ip is from specific region such as the USA or EU. -->
|
||||||
|
<string name="revanced_hide_ask_button_title">Hide Ask</string>
|
||||||
|
<string name="revanced_hide_ask_button_summary_on">Ask button is hidden</string>
|
||||||
|
<string name="revanced_hide_ask_button_summary_off">Ask button is shown</string>
|
||||||
<!-- 'Clip' should be translated with the same localized wording that YouTube displays. -->
|
<!-- 'Clip' should be translated with the same localized wording that YouTube displays. -->
|
||||||
<string name="revanced_hide_clip_button_title">Hide Clip</string>
|
<string name="revanced_hide_clip_button_title">Hide Clip</string>
|
||||||
<string name="revanced_hide_clip_button_summary_on">Clip button is hidden</string>
|
<string name="revanced_hide_clip_button_summary_on">Clip button is hidden</string>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user