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

Commit 85971bc

Browse files
OxrxLoSumAtrIX
andauthored
fix(youtube/hide-info-cards): remove initial popup of info-cards (#199)
Co-authored-by: oSumAtrIX <johan.melkonyan1@web.de>
1 parent f475c28 commit 85971bc

3 files changed

Lines changed: 17 additions & 15 deletions

File tree

app/src/main/java/app/revanced/integrations/patches/HideInfoCardSuggestionsPatch.java

Lines changed: 0 additions & 14 deletions
This file was deleted.
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
package app.revanced.integrations.patches;
2+
3+
import android.view.View;
4+
5+
import app.revanced.integrations.settings.SettingsEnum;
6+
7+
public class HideInfocardsPatch {
8+
public static void hideInfocardsIncognito(View view) {
9+
if (!SettingsEnum.HIDE_INFO_CARDS.getBoolean()) return;
10+
view.setVisibility(View.GONE);
11+
}
12+
13+
public static boolean hideInfocardsMethodCall() {
14+
return SettingsEnum.HIDE_INFO_CARDS.getBoolean();
15+
}
16+
}

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ public enum SettingsEnum {
5656

5757
// Layout settings
5858
REEL_BUTTON_SHOWN("revanced_reel_button_enabled", false, ReturnType.BOOLEAN, true),
59-
INFO_CARDS_SHOWN("revanced_info_cards_enabled", false, ReturnType.BOOLEAN),
59+
HIDE_INFO_CARDS("revanced_hide_infocards", true, ReturnType.BOOLEAN),
6060
BRANDING_SHOWN("revanced_branding_watermark_enabled", false, ReturnType.BOOLEAN),
6161
CAST_BUTTON_SHOWN("revanced_cast_button_enabled", false, ReturnType.BOOLEAN, true),
6262
AUTOPLAY_BUTTON_SHOWN("revanced_autoplay_button_enabled", false, ReturnType.BOOLEAN, true),

0 commit comments

Comments
 (0)