Skip to content
This repository was archived by the owner on Oct 26, 2024. It is now read-only.

Commit 69a585d

Browse files
author
OxrxL
authored
feat(youtube/comments): hide shorts comments button (#188)
1 parent 7050cef commit 69a585d

2 files changed

Lines changed: 14 additions & 0 deletions

File tree

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
package app.revanced.integrations.patches;
2+
3+
import android.view.View;
4+
5+
import app.revanced.integrations.settings.SettingsEnum;
6+
7+
public class HideShortsCommentsButtonPatch {
8+
//Used by app.revanced.patches.youtube.layout.comments.patch.CommentsPatch
9+
public static void hideShortsCommentsButton(View view) {
10+
if (!SettingsEnum.HIDE_SHORTS_COMMENTS_BUTTON.getBoolean()) return;
11+
view.setVisibility(View.GONE);
12+
}
13+
}

app/src/main/java/app/revanced/integrations/settings/SettingsEnum.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ public enum SettingsEnum {
7373
HIDE_MIX_PLAYLISTS("revanced_mix_playlists_hidden", false, ReturnType.BOOLEAN, true),
7474
HIDE_CROWDFUNDING_BOX("revanced_hide_crowdfunding_box", false, ReturnType.BOOLEAN, true),
7575
HIDE_COMMENTS_SECTION("revanced_hide_comments_section", false, ReturnType.BOOLEAN, true),
76+
HIDE_SHORTS_COMMENTS_BUTTON("revanced_hide_shorts_comments_button", false, ReturnType.BOOLEAN),
7677
HIDE_PREVIEW_COMMENT("revanced_hide_preview_comment", false, ReturnType.BOOLEAN, true),
7778
HIDE_ALBUM_CARDS("revanced_hide_album_cards", false, ReturnType.BOOLEAN, true),
7879
HIDE_ARTIST_CARD("revanced_hide_artist_card", false, ReturnType.BOOLEAN),

0 commit comments

Comments
 (0)