mirror of
https://github.com/revanced/revanced-integrations.git
synced 2025-01-23 18:27:32 +01:00
fix(YouTube - Spoof client): show video time and chapters while using seekbar (#435)
This commit is contained in:
parent
2f39f32a52
commit
a0f831ac3f
@ -2,6 +2,10 @@ package app.revanced.integrations.patches;
|
|||||||
|
|
||||||
import static app.revanced.integrations.utils.ReVancedUtils.containsAny;
|
import static app.revanced.integrations.utils.ReVancedUtils.containsAny;
|
||||||
|
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
import android.widget.ImageView;
|
||||||
|
|
||||||
import app.revanced.integrations.settings.SettingsEnum;
|
import app.revanced.integrations.settings.SettingsEnum;
|
||||||
import app.revanced.integrations.shared.PlayerType;
|
import app.revanced.integrations.shared.PlayerType;
|
||||||
import app.revanced.integrations.utils.LogHelper;
|
import app.revanced.integrations.utils.LogHelper;
|
||||||
@ -67,4 +71,25 @@ public class SpoofSignatureVerificationPatch {
|
|||||||
return originalValue;
|
return originalValue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Injection point.
|
||||||
|
*/
|
||||||
|
public static boolean getSeekbarThumbnailOverrideValue() {
|
||||||
|
return SettingsEnum.SPOOF_SIGNATURE_VERIFICATION.getBoolean();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Injection point.
|
||||||
|
*
|
||||||
|
* @param view seekbar thumbnail view. Includes both shorts and regular videos.
|
||||||
|
*/
|
||||||
|
public static void seekbarImageViewCreated(ImageView view) {
|
||||||
|
if (SettingsEnum.SPOOF_SIGNATURE_VERIFICATION.getBoolean()) {
|
||||||
|
view.setVisibility(View.GONE);
|
||||||
|
// Also hide the border around the thumbnail (otherwise a 1 pixel wide bordered frame is visible).
|
||||||
|
ViewGroup parentLayout = (ViewGroup) view.getParent();
|
||||||
|
parentLayout.setPadding(0, 0, 0, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -152,7 +152,8 @@ public enum SettingsEnum {
|
|||||||
EXTERNAL_BROWSER("revanced_external_browser", BOOLEAN, TRUE, true),
|
EXTERNAL_BROWSER("revanced_external_browser", BOOLEAN, TRUE, true),
|
||||||
AUTO_REPEAT("revanced_auto_repeat", BOOLEAN, FALSE),
|
AUTO_REPEAT("revanced_auto_repeat", BOOLEAN, FALSE),
|
||||||
SEEKBAR_TAPPING("revanced_seekbar_tapping", BOOLEAN, TRUE),
|
SEEKBAR_TAPPING("revanced_seekbar_tapping", BOOLEAN, TRUE),
|
||||||
SPOOF_SIGNATURE_VERIFICATION("revanced_spoof_signature_verification", BOOLEAN, TRUE, "revanced_spoof_signature_verification_user_dialog_message"),
|
SPOOF_SIGNATURE_VERIFICATION("revanced_spoof_signature_verification", BOOLEAN, TRUE, true,
|
||||||
|
"revanced_spoof_signature_verification_user_dialog_message"),
|
||||||
|
|
||||||
// Swipe controls
|
// Swipe controls
|
||||||
SWIPE_BRIGHTNESS("revanced_swipe_brightness", BOOLEAN, TRUE),
|
SWIPE_BRIGHTNESS("revanced_swipe_brightness", BOOLEAN, TRUE),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user