mirror of
https://github.com/ReVanced/revanced-patches.git
synced 2026-01-28 21:21:02 +00:00
Compare commits
5 Commits
v5.38.1-de
...
v5.39.0-de
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
cba44ccfc8 | ||
|
|
a84db7be7f | ||
|
|
2520129ace | ||
|
|
7eeffd3392 | ||
|
|
6c3391164e |
14
CHANGELOG.md
14
CHANGELOG.md
@@ -1,3 +1,17 @@
|
|||||||
|
# [5.39.0-dev.1](https://github.com/ReVanced/revanced-patches/compare/v5.38.1-dev.2...v5.39.0-dev.1) (2025-09-17)
|
||||||
|
|
||||||
|
|
||||||
|
### Features
|
||||||
|
|
||||||
|
* **YouTube - Hide video action buttons:** Add "Hide Shop button" setting ([a84db7b](https://github.com/ReVanced/revanced-patches/commit/a84db7be7fde2e9bb3ac41aec709a1681e845fe1))
|
||||||
|
|
||||||
|
## [5.38.1-dev.2](https://github.com/ReVanced/revanced-patches/compare/v5.38.1-dev.1...v5.38.1-dev.2) (2025-09-16)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* **YouTube Music - Spoof video streams:** Remove iPadOS client ([7eeffd3](https://github.com/ReVanced/revanced-patches/commit/7eeffd3392c57555342173103d3a417c038d0970))
|
||||||
|
|
||||||
## [5.38.1-dev.1](https://github.com/ReVanced/revanced-patches/compare/v5.38.0...v5.38.1-dev.1) (2025-09-16)
|
## [5.38.1-dev.1](https://github.com/ReVanced/revanced-patches/compare/v5.38.0...v5.38.1-dev.1) (2025-09-16)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
package app.revanced.extension.music.patches.spoof;
|
package app.revanced.extension.music.patches.spoof;
|
||||||
|
|
||||||
|
import static app.revanced.extension.music.settings.Settings.SPOOF_VIDEO_STREAMS_CLIENT_TYPE;
|
||||||
import static app.revanced.extension.shared.spoof.ClientType.ANDROID_VR_1_43_32;
|
import static app.revanced.extension.shared.spoof.ClientType.ANDROID_VR_1_43_32;
|
||||||
import static app.revanced.extension.shared.spoof.ClientType.ANDROID_VR_1_61_48;
|
import static app.revanced.extension.shared.spoof.ClientType.ANDROID_VR_1_61_48;
|
||||||
import static app.revanced.extension.shared.spoof.ClientType.VISIONOS;
|
import static app.revanced.extension.shared.spoof.ClientType.VISIONOS;
|
||||||
@@ -22,6 +23,8 @@ public class SpoofVideoStreamsPatch {
|
|||||||
VISIONOS
|
VISIONOS
|
||||||
);
|
);
|
||||||
|
|
||||||
StreamingDataRequest.setClientOrderToUse(availableClients, ANDROID_VR_1_43_32);
|
ClientType client = SPOOF_VIDEO_STREAMS_CLIENT_TYPE.get();
|
||||||
|
app.revanced.extension.shared.spoof.SpoofVideoStreamsPatch.setPreferredClient(client);
|
||||||
|
StreamingDataRequest.setClientOrderToUse(availableClients, client);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,8 +3,12 @@ package app.revanced.extension.music.settings;
|
|||||||
import static java.lang.Boolean.FALSE;
|
import static java.lang.Boolean.FALSE;
|
||||||
import static java.lang.Boolean.TRUE;
|
import static java.lang.Boolean.TRUE;
|
||||||
|
|
||||||
|
import static app.revanced.extension.shared.settings.Setting.parent;
|
||||||
|
|
||||||
import app.revanced.extension.shared.settings.BaseSettings;
|
import app.revanced.extension.shared.settings.BaseSettings;
|
||||||
import app.revanced.extension.shared.settings.BooleanSetting;
|
import app.revanced.extension.shared.settings.BooleanSetting;
|
||||||
|
import app.revanced.extension.shared.settings.EnumSetting;
|
||||||
|
import app.revanced.extension.shared.spoof.ClientType;
|
||||||
|
|
||||||
public class Settings extends BaseSettings {
|
public class Settings extends BaseSettings {
|
||||||
|
|
||||||
@@ -18,4 +22,8 @@ public class Settings extends BaseSettings {
|
|||||||
|
|
||||||
// Player
|
// Player
|
||||||
public static final BooleanSetting PERMANENT_REPEAT = new BooleanSetting("revanced_music_play_permanent_repeat", FALSE, true);
|
public static final BooleanSetting PERMANENT_REPEAT = new BooleanSetting("revanced_music_play_permanent_repeat", FALSE, true);
|
||||||
|
|
||||||
|
// Miscellaneous
|
||||||
|
public static final EnumSetting<ClientType> SPOOF_VIDEO_STREAMS_CLIENT_TYPE = new EnumSetting<>("revanced_spoof_video_streams_client_type",
|
||||||
|
ClientType.ANDROID_VR_1_43_32, true, parent(SPOOF_VIDEO_STREAMS));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,9 +5,6 @@ import static java.lang.Boolean.TRUE;
|
|||||||
import static app.revanced.extension.shared.settings.Setting.parent;
|
import static app.revanced.extension.shared.settings.Setting.parent;
|
||||||
import static app.revanced.extension.shared.spoof.SpoofVideoStreamsPatch.AudioStreamLanguageOverrideAvailability;
|
import static app.revanced.extension.shared.spoof.SpoofVideoStreamsPatch.AudioStreamLanguageOverrideAvailability;
|
||||||
|
|
||||||
import app.revanced.extension.shared.Logger;
|
|
||||||
import app.revanced.extension.shared.spoof.ClientType;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Settings shared across multiple apps.
|
* Settings shared across multiple apps.
|
||||||
* <p>
|
* <p>
|
||||||
@@ -31,13 +28,4 @@ public class BaseSettings {
|
|||||||
public static final BooleanSetting SPOOF_VIDEO_STREAMS = new BooleanSetting("revanced_spoof_video_streams", TRUE, true, "revanced_spoof_video_streams_user_dialog_message");
|
public static final BooleanSetting SPOOF_VIDEO_STREAMS = new BooleanSetting("revanced_spoof_video_streams", TRUE, true, "revanced_spoof_video_streams_user_dialog_message");
|
||||||
public static final EnumSetting<AppLanguage> SPOOF_VIDEO_STREAMS_LANGUAGE = new EnumSetting<>("revanced_spoof_video_streams_language", AppLanguage.DEFAULT, new AudioStreamLanguageOverrideAvailability());
|
public static final EnumSetting<AppLanguage> SPOOF_VIDEO_STREAMS_LANGUAGE = new EnumSetting<>("revanced_spoof_video_streams_language", AppLanguage.DEFAULT, new AudioStreamLanguageOverrideAvailability());
|
||||||
public static final BooleanSetting SPOOF_STREAMING_DATA_STATS_FOR_NERDS = new BooleanSetting("revanced_spoof_streaming_data_stats_for_nerds", TRUE, parent(SPOOF_VIDEO_STREAMS));
|
public static final BooleanSetting SPOOF_STREAMING_DATA_STATS_FOR_NERDS = new BooleanSetting("revanced_spoof_streaming_data_stats_for_nerds", TRUE, parent(SPOOF_VIDEO_STREAMS));
|
||||||
// Client type must be last spoof setting due to cyclic references.
|
|
||||||
public static final EnumSetting<ClientType> SPOOF_VIDEO_STREAMS_CLIENT_TYPE = new EnumSetting<>("revanced_spoof_video_streams_client_type", ClientType.ANDROID_VR_1_61_48, true, parent(SPOOF_VIDEO_STREAMS));
|
|
||||||
|
|
||||||
static {
|
|
||||||
if (SPOOF_VIDEO_STREAMS_CLIENT_TYPE.get() == ClientType.IOS_UNPLUGGED) {
|
|
||||||
Logger.printInfo(() -> "Migrating from iOS Unplugged to iPadOS");
|
|
||||||
SPOOF_VIDEO_STREAMS_CLIENT_TYPE.save(ClientType.IPADOS);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -31,7 +31,6 @@ public enum ClientType {
|
|||||||
"132.0.6808.3",
|
"132.0.6808.3",
|
||||||
"1.61.48",
|
"1.61.48",
|
||||||
false,
|
false,
|
||||||
false,
|
|
||||||
"Android VR 1.61"
|
"Android VR 1.61"
|
||||||
),
|
),
|
||||||
/**
|
/**
|
||||||
@@ -50,7 +49,6 @@ public enum ClientType {
|
|||||||
Objects.requireNonNull(ANDROID_VR_1_61_48.buildId),
|
Objects.requireNonNull(ANDROID_VR_1_61_48.buildId),
|
||||||
"107.0.5284.2",
|
"107.0.5284.2",
|
||||||
"1.43.32",
|
"1.43.32",
|
||||||
ANDROID_VR_1_61_48.requiresAuth,
|
|
||||||
ANDROID_VR_1_61_48.useAuth,
|
ANDROID_VR_1_61_48.useAuth,
|
||||||
"Android VR 1.43"
|
"Android VR 1.43"
|
||||||
),
|
),
|
||||||
@@ -71,7 +69,6 @@ public enum ClientType {
|
|||||||
"132.0.6779.0",
|
"132.0.6779.0",
|
||||||
"23.47.101",
|
"23.47.101",
|
||||||
true,
|
true,
|
||||||
true,
|
|
||||||
"Android Creator"
|
"Android Creator"
|
||||||
),
|
),
|
||||||
/**
|
/**
|
||||||
@@ -86,7 +83,6 @@ public enum ClientType {
|
|||||||
"0.1",
|
"0.1",
|
||||||
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/18.0 Safari/605.1.15",
|
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/18.0 Safari/605.1.15",
|
||||||
false,
|
false,
|
||||||
false,
|
|
||||||
"visionOS"
|
"visionOS"
|
||||||
),
|
),
|
||||||
/**
|
/**
|
||||||
@@ -111,25 +107,7 @@ public enum ClientType {
|
|||||||
"19.22.3",
|
"19.22.3",
|
||||||
"com.google.ios.youtube/19.22.3 (iPad7,6; U; CPU iPadOS 17_7_10 like Mac OS X; " + Locale.getDefault() + ")",
|
"com.google.ios.youtube/19.22.3 (iPad7,6; U; CPU iPadOS 17_7_10 like Mac OS X; " + Locale.getDefault() + ")",
|
||||||
false,
|
false,
|
||||||
false,
|
|
||||||
"iPadOS"
|
"iPadOS"
|
||||||
),
|
|
||||||
/**
|
|
||||||
* Obsolete and broken client. Here only to migrate data.
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
IOS_UNPLUGGED(
|
|
||||||
33,
|
|
||||||
"IOS_UNPLUGGED",
|
|
||||||
"Apple",
|
|
||||||
"iPhone16,2",
|
|
||||||
"iOS",
|
|
||||||
"18.2.22C152",
|
|
||||||
"8.49",
|
|
||||||
"dummy user-agent",
|
|
||||||
true,
|
|
||||||
true,
|
|
||||||
"iOS TV"
|
|
||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -197,12 +175,6 @@ public enum ClientType {
|
|||||||
*/
|
*/
|
||||||
public final String clientVersion;
|
public final String clientVersion;
|
||||||
|
|
||||||
/**
|
|
||||||
* If this client requires authentication and does not work
|
|
||||||
* if logged out or in incognito mode.
|
|
||||||
*/
|
|
||||||
public final boolean requiresAuth;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* If the client should use authentication if available.
|
* If the client should use authentication if available.
|
||||||
*/
|
*/
|
||||||
@@ -227,7 +199,6 @@ public enum ClientType {
|
|||||||
@NonNull String buildId,
|
@NonNull String buildId,
|
||||||
@NonNull String cronetVersion,
|
@NonNull String cronetVersion,
|
||||||
String clientVersion,
|
String clientVersion,
|
||||||
boolean requiresAuth,
|
|
||||||
boolean useAuth,
|
boolean useAuth,
|
||||||
String friendlyName) {
|
String friendlyName) {
|
||||||
this.id = id;
|
this.id = id;
|
||||||
@@ -241,7 +212,6 @@ public enum ClientType {
|
|||||||
this.buildId = buildId;
|
this.buildId = buildId;
|
||||||
this.cronetVersion = cronetVersion;
|
this.cronetVersion = cronetVersion;
|
||||||
this.clientVersion = clientVersion;
|
this.clientVersion = clientVersion;
|
||||||
this.requiresAuth = requiresAuth;
|
|
||||||
this.useAuth = useAuth;
|
this.useAuth = useAuth;
|
||||||
this.friendlyName = friendlyName;
|
this.friendlyName = friendlyName;
|
||||||
|
|
||||||
@@ -267,7 +237,6 @@ public enum ClientType {
|
|||||||
String osVersion,
|
String osVersion,
|
||||||
String clientVersion,
|
String clientVersion,
|
||||||
String userAgent,
|
String userAgent,
|
||||||
boolean requiresAuth,
|
|
||||||
boolean useAuth,
|
boolean useAuth,
|
||||||
String friendlyName) {
|
String friendlyName) {
|
||||||
this.id = id;
|
this.id = id;
|
||||||
@@ -278,7 +247,6 @@ public enum ClientType {
|
|||||||
this.osVersion = osVersion;
|
this.osVersion = osVersion;
|
||||||
this.clientVersion = clientVersion;
|
this.clientVersion = clientVersion;
|
||||||
this.userAgent = userAgent;
|
this.userAgent = userAgent;
|
||||||
this.requiresAuth = requiresAuth;
|
|
||||||
this.useAuth = useAuth;
|
this.useAuth = useAuth;
|
||||||
this.friendlyName = friendlyName;
|
this.friendlyName = friendlyName;
|
||||||
this.packageName = null;
|
this.packageName = null;
|
||||||
|
|||||||
@@ -7,6 +7,7 @@ import androidx.annotation.Nullable;
|
|||||||
|
|
||||||
import java.nio.ByteBuffer;
|
import java.nio.ByteBuffer;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
import java.util.Objects;
|
||||||
|
|
||||||
import app.revanced.extension.shared.Logger;
|
import app.revanced.extension.shared.Logger;
|
||||||
import app.revanced.extension.shared.Utils;
|
import app.revanced.extension.shared.Utils;
|
||||||
@@ -17,14 +18,6 @@ import app.revanced.extension.shared.spoof.requests.StreamingDataRequest;
|
|||||||
|
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
public class SpoofVideoStreamsPatch {
|
public class SpoofVideoStreamsPatch {
|
||||||
private static final boolean SPOOF_STREAMING_DATA = BaseSettings.SPOOF_VIDEO_STREAMS.get();
|
|
||||||
|
|
||||||
private static final boolean FIX_HLS_CURRENT_TIME = SPOOF_STREAMING_DATA
|
|
||||||
&& BaseSettings.SPOOF_VIDEO_STREAMS_CLIENT_TYPE.get() == ClientType.VISIONOS;
|
|
||||||
|
|
||||||
@Nullable
|
|
||||||
private static volatile AppLanguage languageOverride;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Domain used for internet connectivity verification.
|
* Domain used for internet connectivity verification.
|
||||||
* It has an empty response body and is only used to check for a 204 response code.
|
* It has an empty response body and is only used to check for a 204 response code.
|
||||||
@@ -40,6 +33,13 @@ public class SpoofVideoStreamsPatch {
|
|||||||
private static final String INTERNET_CONNECTION_CHECK_URI_STRING = "https://www.google.com/gen_204";
|
private static final String INTERNET_CONNECTION_CHECK_URI_STRING = "https://www.google.com/gen_204";
|
||||||
private static final Uri INTERNET_CONNECTION_CHECK_URI = Uri.parse(INTERNET_CONNECTION_CHECK_URI_STRING);
|
private static final Uri INTERNET_CONNECTION_CHECK_URI = Uri.parse(INTERNET_CONNECTION_CHECK_URI_STRING);
|
||||||
|
|
||||||
|
private static final boolean SPOOF_STREAMING_DATA = BaseSettings.SPOOF_VIDEO_STREAMS.get();
|
||||||
|
|
||||||
|
@Nullable
|
||||||
|
private static volatile AppLanguage languageOverride;
|
||||||
|
|
||||||
|
private static volatile ClientType preferredClient = ClientType.ANDROID_VR_1_61_48;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return If this patch was included during patching.
|
* @return If this patch was included during patching.
|
||||||
*/
|
*/
|
||||||
@@ -47,10 +47,9 @@ public class SpoofVideoStreamsPatch {
|
|||||||
return false; // Modified during patching.
|
return false; // Modified during patching.
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean spoofingToClientWithNoMultiAudioStreams() {
|
@Nullable
|
||||||
return isPatchIncluded()
|
public static AppLanguage getLanguageOverride() {
|
||||||
&& BaseSettings.SPOOF_VIDEO_STREAMS.get()
|
return languageOverride;
|
||||||
&& BaseSettings.SPOOF_VIDEO_STREAMS_CLIENT_TYPE.get() != ClientType.IPADOS;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -61,9 +60,14 @@ public class SpoofVideoStreamsPatch {
|
|||||||
languageOverride = language;
|
languageOverride = language;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Nullable
|
public static void setPreferredClient(ClientType client) {
|
||||||
public static AppLanguage getLanguageOverride() {
|
preferredClient = Objects.requireNonNull(client);
|
||||||
return languageOverride;
|
}
|
||||||
|
|
||||||
|
public static boolean spoofingToClientWithNoMultiAudioStreams() {
|
||||||
|
return isPatchIncluded()
|
||||||
|
&& SPOOF_STREAMING_DATA
|
||||||
|
&& preferredClient != ClientType.IPADOS;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -278,8 +282,7 @@ public class SpoofVideoStreamsPatch {
|
|||||||
public static final class AudioStreamLanguageOverrideAvailability implements Setting.Availability {
|
public static final class AudioStreamLanguageOverrideAvailability implements Setting.Availability {
|
||||||
@Override
|
@Override
|
||||||
public boolean isAvailable() {
|
public boolean isAvailable() {
|
||||||
// Since all current clients are un-authenticated, this works for all spoof clients.
|
return BaseSettings.SPOOF_VIDEO_STREAMS.get() && !preferredClient.useAuth;
|
||||||
return BaseSettings.SPOOF_VIDEO_STREAMS.get();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -42,10 +42,10 @@ final class PlayerRoutes {
|
|||||||
JSONObject context = new JSONObject();
|
JSONObject context = new JSONObject();
|
||||||
|
|
||||||
AppLanguage language = SpoofVideoStreamsPatch.getLanguageOverride();
|
AppLanguage language = SpoofVideoStreamsPatch.getLanguageOverride();
|
||||||
if (language == null || BaseSettings.SPOOF_VIDEO_STREAMS_CLIENT_TYPE.get() == ANDROID_VR_1_43_32) {
|
if (language == null || clientType == ANDROID_VR_1_43_32) {
|
||||||
// Force original audio has not overrode the language.
|
// Force original audio has not overrode the language.
|
||||||
// Or if YT has fallen over to the very last client (VR 1.43), then always
|
// Or if YT has fallen over to the last unauthenticated client (VR 1.43), then
|
||||||
// use the app language because forcing an audio stream of specific languages
|
// always use the app language because forcing an audio stream of specific languages
|
||||||
// can sometimes fail so it's better to try and load something rather than nothing.
|
// can sometimes fail so it's better to try and load something rather than nothing.
|
||||||
language = BaseSettings.SPOOF_VIDEO_STREAMS_LANGUAGE.get();
|
language = BaseSettings.SPOOF_VIDEO_STREAMS_LANGUAGE.get();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -177,7 +177,7 @@ public class StreamingDataRequest {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!authHeadersIncludes && clientType.requiresAuth) {
|
if (!authHeadersIncludes && clientType.useAuth) {
|
||||||
Logger.printDebug(() -> "Skipping client since user is not logged in: " + clientType
|
Logger.printDebug(() -> "Skipping client since user is not logged in: " + clientType
|
||||||
+ " videoId: " + videoId);
|
+ " videoId: " + videoId);
|
||||||
return null;
|
return null;
|
||||||
|
|||||||
@@ -74,6 +74,10 @@ final class ButtonsFilter extends Filter {
|
|||||||
Settings.HIDE_ASK_BUTTON,
|
Settings.HIDE_ASK_BUTTON,
|
||||||
"yt_fill_spark"
|
"yt_fill_spark"
|
||||||
),
|
),
|
||||||
|
new ByteArrayFilterGroup(
|
||||||
|
Settings.HIDE_SHOP_BUTTON,
|
||||||
|
"yt_outline_bag"
|
||||||
|
),
|
||||||
new ByteArrayFilterGroup(
|
new ByteArrayFilterGroup(
|
||||||
Settings.HIDE_STOP_ADS_BUTTON,
|
Settings.HIDE_STOP_ADS_BUTTON,
|
||||||
"yt_outline_slash_circle_left"
|
"yt_outline_slash_circle_left"
|
||||||
|
|||||||
@@ -8,9 +8,9 @@ import static app.revanced.extension.shared.spoof.ClientType.VISIONOS;
|
|||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import app.revanced.extension.shared.settings.BaseSettings;
|
|
||||||
import app.revanced.extension.shared.spoof.ClientType;
|
import app.revanced.extension.shared.spoof.ClientType;
|
||||||
import app.revanced.extension.shared.spoof.requests.StreamingDataRequest;
|
import app.revanced.extension.shared.spoof.requests.StreamingDataRequest;
|
||||||
|
import app.revanced.extension.youtube.settings.Settings;
|
||||||
|
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
public class SpoofVideoStreamsPatch {
|
public class SpoofVideoStreamsPatch {
|
||||||
@@ -27,7 +27,8 @@ public class SpoofVideoStreamsPatch {
|
|||||||
IPADOS
|
IPADOS
|
||||||
);
|
);
|
||||||
|
|
||||||
StreamingDataRequest.setClientOrderToUse(availableClients,
|
ClientType client = Settings.SPOOF_VIDEO_STREAMS_CLIENT_TYPE.get();
|
||||||
BaseSettings.SPOOF_VIDEO_STREAMS_CLIENT_TYPE.get());
|
app.revanced.extension.shared.spoof.SpoofVideoStreamsPatch.setPreferredClient(client);
|
||||||
|
StreamingDataRequest.setClientOrderToUse(availableClients, client);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -41,6 +41,7 @@ import app.revanced.extension.shared.settings.LongSetting;
|
|||||||
import app.revanced.extension.shared.settings.Setting;
|
import app.revanced.extension.shared.settings.Setting;
|
||||||
import app.revanced.extension.shared.settings.StringSetting;
|
import app.revanced.extension.shared.settings.StringSetting;
|
||||||
import app.revanced.extension.shared.settings.preference.SharedPrefCategory;
|
import app.revanced.extension.shared.settings.preference.SharedPrefCategory;
|
||||||
|
import app.revanced.extension.shared.spoof.ClientType;
|
||||||
import app.revanced.extension.youtube.patches.AlternativeThumbnailsPatch.DeArrowAvailability;
|
import app.revanced.extension.youtube.patches.AlternativeThumbnailsPatch.DeArrowAvailability;
|
||||||
import app.revanced.extension.youtube.patches.AlternativeThumbnailsPatch.StillImagesAvailability;
|
import app.revanced.extension.youtube.patches.AlternativeThumbnailsPatch.StillImagesAvailability;
|
||||||
import app.revanced.extension.youtube.patches.AlternativeThumbnailsPatch.ThumbnailOption;
|
import app.revanced.extension.youtube.patches.AlternativeThumbnailsPatch.ThumbnailOption;
|
||||||
@@ -229,6 +230,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_SAVE_BUTTON = new BooleanSetting("revanced_hide_save_button", FALSE);
|
public static final BooleanSetting HIDE_SAVE_BUTTON = new BooleanSetting("revanced_hide_save_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_SHOP_BUTTON = new BooleanSetting("revanced_hide_shop_button", FALSE);
|
||||||
public static final BooleanSetting HIDE_STOP_ADS_BUTTON = new BooleanSetting("revanced_hide_stop_ads_button", TRUE);
|
public static final BooleanSetting HIDE_STOP_ADS_BUTTON = new BooleanSetting("revanced_hide_stop_ads_button", TRUE);
|
||||||
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);
|
||||||
|
|
||||||
@@ -356,6 +358,7 @@ public class Settings extends BaseSettings {
|
|||||||
public static final BooleanSetting REMOVE_TRACKING_QUERY_PARAMETER = new BooleanSetting("revanced_remove_tracking_query_parameter", TRUE);
|
public static final BooleanSetting REMOVE_TRACKING_QUERY_PARAMETER = new BooleanSetting("revanced_remove_tracking_query_parameter", TRUE);
|
||||||
public static final BooleanSetting SPOOF_DEVICE_DIMENSIONS = new BooleanSetting("revanced_spoof_device_dimensions", FALSE, true,
|
public static final BooleanSetting SPOOF_DEVICE_DIMENSIONS = new BooleanSetting("revanced_spoof_device_dimensions", FALSE, true,
|
||||||
"revanced_spoof_device_dimensions_user_dialog_message");
|
"revanced_spoof_device_dimensions_user_dialog_message");
|
||||||
|
public static final EnumSetting<ClientType> SPOOF_VIDEO_STREAMS_CLIENT_TYPE = new EnumSetting<>("revanced_spoof_video_streams_client_type", ClientType.ANDROID_VR_1_61_48, true, parent(SPOOF_VIDEO_STREAMS));
|
||||||
public static final BooleanSetting DEBUG_PROTOBUFFER = new BooleanSetting("revanced_debug_protobuffer", FALSE, false,
|
public static final BooleanSetting DEBUG_PROTOBUFFER = new BooleanSetting("revanced_debug_protobuffer", FALSE, false,
|
||||||
"revanced_debug_protobuffer_user_dialog_message", parent(BaseSettings.DEBUG));
|
"revanced_debug_protobuffer_user_dialog_message", parent(BaseSettings.DEBUG));
|
||||||
|
|
||||||
|
|||||||
@@ -15,6 +15,7 @@ import app.revanced.extension.shared.Utils;
|
|||||||
import app.revanced.extension.shared.settings.BaseSettings;
|
import app.revanced.extension.shared.settings.BaseSettings;
|
||||||
import app.revanced.extension.shared.settings.Setting;
|
import app.revanced.extension.shared.settings.Setting;
|
||||||
import app.revanced.extension.shared.spoof.ClientType;
|
import app.revanced.extension.shared.spoof.ClientType;
|
||||||
|
import app.revanced.extension.youtube.settings.Settings;
|
||||||
|
|
||||||
@SuppressWarnings({"deprecation", "unused"})
|
@SuppressWarnings({"deprecation", "unused"})
|
||||||
public class SpoofStreamingDataSideEffectsPreference extends Preference {
|
public class SpoofStreamingDataSideEffectsPreference extends Preference {
|
||||||
@@ -69,7 +70,7 @@ public class SpoofStreamingDataSideEffectsPreference extends Preference {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void updateUI() {
|
private void updateUI() {
|
||||||
ClientType clientType = BaseSettings.SPOOF_VIDEO_STREAMS_CLIENT_TYPE.get();
|
ClientType clientType = Settings.SPOOF_VIDEO_STREAMS_CLIENT_TYPE.get();
|
||||||
if (currentClientType == clientType) {
|
if (currentClientType == clientType) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,4 +3,4 @@ org.gradle.jvmargs = -Xms512M -Xmx2048M
|
|||||||
org.gradle.parallel = true
|
org.gradle.parallel = true
|
||||||
android.useAndroidX = true
|
android.useAndroidX = true
|
||||||
kotlin.code.style = official
|
kotlin.code.style = official
|
||||||
version = 5.38.1-dev.1
|
version = 5.39.0-dev.1
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ val spoofVideoStreamsPatch = spoofVideoStreamsPatch(
|
|||||||
)
|
)
|
||||||
},
|
},
|
||||||
executeBlock = {
|
executeBlock = {
|
||||||
addResources("shared", "misc.spoof.spoofVideoStreamsPatch")
|
addResources("music", "misc.fix.playback.spoofVideoStreamsPatch")
|
||||||
|
|
||||||
PreferenceScreen.MISC.addPreferences(
|
PreferenceScreen.MISC.addPreferences(
|
||||||
PreferenceScreenPreference(
|
PreferenceScreenPreference(
|
||||||
|
|||||||
@@ -49,6 +49,7 @@ val hideButtonsPatch = resourcePatch(
|
|||||||
SwitchPreference("revanced_hide_report_button"),
|
SwitchPreference("revanced_hide_report_button"),
|
||||||
SwitchPreference("revanced_hide_save_button"),
|
SwitchPreference("revanced_hide_save_button"),
|
||||||
SwitchPreference("revanced_hide_share_button"),
|
SwitchPreference("revanced_hide_share_button"),
|
||||||
|
SwitchPreference("revanced_hide_shop_button"),
|
||||||
SwitchPreference("revanced_hide_stop_ads_button"),
|
SwitchPreference("revanced_hide_stop_ads_button"),
|
||||||
SwitchPreference("revanced_hide_thanks_button"),
|
SwitchPreference("revanced_hide_thanks_button"),
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -121,6 +121,20 @@
|
|||||||
<item>ZH</item>
|
<item>ZH</item>
|
||||||
</string-array>
|
</string-array>
|
||||||
</patch>
|
</patch>
|
||||||
|
</app>
|
||||||
|
<app id="music">
|
||||||
|
<patch id="misc.fix.playback.spoofVideoStreamsPatch">
|
||||||
|
<string-array name="revanced_spoof_video_streams_client_type_entries">
|
||||||
|
<item>Android VR</item>
|
||||||
|
<item>visionOS</item>
|
||||||
|
</string-array>
|
||||||
|
<string-array name="revanced_spoof_video_streams_client_type_entry_values">
|
||||||
|
<item>ANDROID_VR_1_43_32</item>
|
||||||
|
<item>VISIONOS</item>
|
||||||
|
</string-array>
|
||||||
|
</patch>
|
||||||
|
</app>
|
||||||
|
<app id="youtube">
|
||||||
<patch id="misc.fix.playback.spoofVideoStreamsPatch">
|
<patch id="misc.fix.playback.spoofVideoStreamsPatch">
|
||||||
<string-array name="revanced_spoof_video_streams_client_type_entries">
|
<string-array name="revanced_spoof_video_streams_client_type_entries">
|
||||||
<item>Android VR</item>
|
<item>Android VR</item>
|
||||||
@@ -133,8 +147,6 @@
|
|||||||
<item>IPADOS</item>
|
<item>IPADOS</item>
|
||||||
</string-array>
|
</string-array>
|
||||||
</patch>
|
</patch>
|
||||||
</app>
|
|
||||||
<app id="youtube">
|
|
||||||
<patch id="interaction.swipecontrols.swipeControlsResourcePatch">
|
<patch id="interaction.swipecontrols.swipeControlsResourcePatch">
|
||||||
<string-array name="revanced_swipe_overlay_style_entries">
|
<string-array name="revanced_swipe_overlay_style_entries">
|
||||||
<item>@string/revanced_swipe_overlay_style_entry_1</item>
|
<item>@string/revanced_swipe_overlay_style_entry_1</item>
|
||||||
|
|||||||
@@ -684,6 +684,10 @@ Adjust volume by swiping vertically on the right side of the screen"</string>
|
|||||||
<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>
|
||||||
<string name="revanced_hide_clip_button_summary_off">Clip button is shown</string>
|
<string name="revanced_hide_clip_button_summary_off">Clip button is shown</string>
|
||||||
|
<!-- 'Shop' should be translated with the same localized wording that YouTube displays. -->
|
||||||
|
<string name="revanced_hide_shop_button_title">Hide Shop</string>
|
||||||
|
<string name="revanced_hide_shop_button_summary_on">Shop button is hidden</string>
|
||||||
|
<string name="revanced_hide_shop_button_summary_off">Shop button is shown</string>
|
||||||
<!-- 'Save' should be translated with the same localized wording that YouTube displays. -->
|
<!-- 'Save' should be translated with the same localized wording that YouTube displays. -->
|
||||||
<string name="revanced_hide_save_button_title">Hide Save</string>
|
<string name="revanced_hide_save_button_title">Hide Save</string>
|
||||||
<string name="revanced_hide_save_button_summary_on">Save button is hidden</string>
|
<string name="revanced_hide_save_button_summary_on">Save button is hidden</string>
|
||||||
|
|||||||
Reference in New Issue
Block a user