mirror of
https://github.com/ReVanced/revanced-patches.git
synced 2026-01-21 10:03:55 +00:00
Compare commits
3 Commits
v5.26.1-de
...
v5.26.1-de
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2257dd90aa | ||
|
|
4b8499ff2c | ||
|
|
bde3fda972 |
@@ -1,3 +1,10 @@
|
|||||||
|
## [5.26.1-dev.2](https://github.com/ReVanced/revanced-patches/compare/v5.26.1-dev.1...v5.26.1-dev.2) (2025-06-05)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* **YouTube - Hide layout components:** Remove broken option 'Hide comments emoji picker' ([#5121](https://github.com/ReVanced/revanced-patches/issues/5121)) ([9a6a639](https://github.com/ReVanced/revanced-patches/commit/9a6a639c4905b00d6dffb0923c839c8e3ae54d0c))
|
||||||
|
|
||||||
## [5.26.1-dev.1](https://github.com/ReVanced/revanced-patches/compare/v5.26.0...v5.26.1-dev.1) (2025-06-05)
|
## [5.26.1-dev.1](https://github.com/ReVanced/revanced-patches/compare/v5.26.0...v5.26.1-dev.1) (2025-06-05)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ dependencies {
|
|||||||
|
|
||||||
android {
|
android {
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
minSdk = 24
|
minSdk = 21
|
||||||
}
|
}
|
||||||
|
|
||||||
compileOptions {
|
compileOptions {
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ package app.revanced.extension.spotify.layout.hide.createbutton;
|
|||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
import app.revanced.extension.shared.Logger;
|
||||||
import app.revanced.extension.shared.Utils;
|
import app.revanced.extension.shared.Utils;
|
||||||
|
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
@@ -31,10 +32,21 @@ public final class HideCreateButtonPatch {
|
|||||||
}
|
}
|
||||||
|
|
||||||
String stringifiedNavigationBarItem = navigationBarItem.toString();
|
String stringifiedNavigationBarItem = navigationBarItem.toString();
|
||||||
boolean isCreateButton = CREATE_BUTTON_TITLE_RES_ID_LIST.stream()
|
|
||||||
.anyMatch(stringifiedNavigationBarItem::contains);
|
boolean isCreateButton = false;
|
||||||
|
String matchedTitleResId = null;
|
||||||
|
|
||||||
|
for (String titleResId : CREATE_BUTTON_TITLE_RES_ID_LIST) {
|
||||||
|
if (stringifiedNavigationBarItem.contains(titleResId)) {
|
||||||
|
isCreateButton = true;
|
||||||
|
matchedTitleResId = titleResId;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (isCreateButton) {
|
if (isCreateButton) {
|
||||||
|
String finalMatchedTitleResId = matchedTitleResId;
|
||||||
|
Logger.printInfo(() -> "Hiding Create button because the navigation bar item " + navigationBarItem +
|
||||||
|
" matched the title resource id " + finalMatchedTitleResId);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -46,6 +58,14 @@ public final class HideCreateButtonPatch {
|
|||||||
* Create button.
|
* Create button.
|
||||||
*/
|
*/
|
||||||
public static boolean isOldCreateButton(int oldNavigationBarItemTitleResId) {
|
public static boolean isOldCreateButton(int oldNavigationBarItemTitleResId) {
|
||||||
return oldNavigationBarItemTitleResId == OLD_CREATE_BUTTON_TITLE_RES_ID;
|
boolean isCreateButton = oldNavigationBarItemTitleResId == OLD_CREATE_BUTTON_TITLE_RES_ID;
|
||||||
|
|
||||||
|
if (isCreateButton) {
|
||||||
|
Logger.printInfo(() -> "Hiding old Create button because the navigation bar item title resource id" +
|
||||||
|
" matched " + OLD_CREATE_BUTTON_TITLE_RES_ID);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -33,10 +33,11 @@ public final class SanitizeSharingLinksPatch {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return builder.build().toString();
|
String sanitizedUrl = builder.build().toString();
|
||||||
|
Logger.printInfo(() -> "Sanitized url " + url + " to " + sanitizedUrl);
|
||||||
|
return sanitizedUrl;
|
||||||
} catch (Exception ex) {
|
} catch (Exception ex) {
|
||||||
Logger.printException(() -> "sanitizeUrl failure", ex);
|
Logger.printException(() -> "sanitizeUrl failure with " + url, ex);
|
||||||
|
|
||||||
return url;
|
return url;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ android {
|
|||||||
compileSdk = 34
|
compileSdk = 34
|
||||||
|
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
minSdk = 24
|
minSdk = 21
|
||||||
}
|
}
|
||||||
|
|
||||||
compileOptions {
|
compileOptions {
|
||||||
|
|||||||
@@ -7,11 +7,6 @@ import app.revanced.extension.youtube.settings.Settings;
|
|||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
final class CommentsFilter extends Filter {
|
final class CommentsFilter extends Filter {
|
||||||
|
|
||||||
private static final String TIMESTAMP_OR_EMOJI_BUTTONS_ENDS_WITH_PATH
|
|
||||||
= "|CellType|ContainerType|ContainerType|ContainerType|ContainerType|ContainerType|";
|
|
||||||
|
|
||||||
private final StringFilterGroup commentComposer;
|
|
||||||
private final ByteArrayFilterGroup emojiPickerBufferGroup;
|
|
||||||
private final StringFilterGroup filterChipBar;
|
private final StringFilterGroup filterChipBar;
|
||||||
private final ByteArrayFilterGroup aiCommentsSummary;
|
private final ByteArrayFilterGroup aiCommentsSummary;
|
||||||
|
|
||||||
@@ -50,14 +45,9 @@ final class CommentsFilter extends Filter {
|
|||||||
"super_thanks_button.eml"
|
"super_thanks_button.eml"
|
||||||
);
|
);
|
||||||
|
|
||||||
commentComposer = new StringFilterGroup(
|
StringFilterGroup timestampButton = new StringFilterGroup(
|
||||||
Settings.HIDE_COMMENTS_TIMESTAMP_AND_EMOJI_BUTTONS,
|
Settings.HIDE_COMMENTS_TIMESTAMP_BUTTON,
|
||||||
"comment_composer.eml"
|
"composer_timestamp_button.eml"
|
||||||
);
|
|
||||||
|
|
||||||
emojiPickerBufferGroup = new ByteArrayFilterGroup(
|
|
||||||
null,
|
|
||||||
"id.comment.quick_emoji.button"
|
|
||||||
);
|
);
|
||||||
|
|
||||||
filterChipBar = new StringFilterGroup(
|
filterChipBar = new StringFilterGroup(
|
||||||
@@ -77,7 +67,7 @@ final class CommentsFilter extends Filter {
|
|||||||
createAShort,
|
createAShort,
|
||||||
previewComment,
|
previewComment,
|
||||||
thanksButton,
|
thanksButton,
|
||||||
commentComposer,
|
timestampButton,
|
||||||
filterChipBar
|
filterChipBar
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@@ -85,14 +75,6 @@ final class CommentsFilter extends Filter {
|
|||||||
@Override
|
@Override
|
||||||
boolean isFiltered(@Nullable String identifier, String path, byte[] protobufBufferArray,
|
boolean isFiltered(@Nullable String identifier, String path, byte[] protobufBufferArray,
|
||||||
StringFilterGroup matchedGroup, FilterContentType contentType, int contentIndex) {
|
StringFilterGroup matchedGroup, FilterContentType contentType, int contentIndex) {
|
||||||
if (matchedGroup == commentComposer) {
|
|
||||||
// To completely hide the emoji buttons (and leave no empty space), the timestamp button is
|
|
||||||
// also hidden because the buffer is exactly the same and there's no way selectively hide.
|
|
||||||
return contentIndex == 0
|
|
||||||
&& path.endsWith(TIMESTAMP_OR_EMOJI_BUTTONS_ENDS_WITH_PATH)
|
|
||||||
&& emojiPickerBufferGroup.check(protobufBufferArray).isFiltered();
|
|
||||||
}
|
|
||||||
|
|
||||||
if (matchedGroup == filterChipBar) {
|
if (matchedGroup == filterChipBar) {
|
||||||
return aiCommentsSummary.check(protobufBufferArray).isFiltered();
|
return aiCommentsSummary.check(protobufBufferArray).isFiltered();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -179,7 +179,7 @@ public class Settings extends BaseSettings {
|
|||||||
public static final BooleanSetting HIDE_COMMENTS_AI_SUMMARY = new BooleanSetting("revanced_hide_comments_ai_summary", FALSE);
|
public static final BooleanSetting HIDE_COMMENTS_AI_SUMMARY = new BooleanSetting("revanced_hide_comments_ai_summary", FALSE);
|
||||||
public static final BooleanSetting HIDE_COMMENTS_BY_MEMBERS_HEADER = new BooleanSetting("revanced_hide_comments_by_members_header", FALSE);
|
public static final BooleanSetting HIDE_COMMENTS_BY_MEMBERS_HEADER = new BooleanSetting("revanced_hide_comments_by_members_header", FALSE);
|
||||||
public static final BooleanSetting HIDE_COMMENTS_CREATE_A_SHORT_BUTTON = new BooleanSetting("revanced_hide_comments_create_a_short_button", TRUE);
|
public static final BooleanSetting HIDE_COMMENTS_CREATE_A_SHORT_BUTTON = new BooleanSetting("revanced_hide_comments_create_a_short_button", TRUE);
|
||||||
public static final BooleanSetting HIDE_COMMENTS_TIMESTAMP_AND_EMOJI_BUTTONS = new BooleanSetting("revanced_hide_comments_timestamp_and_emoji_buttons", TRUE);
|
public static final BooleanSetting HIDE_COMMENTS_TIMESTAMP_BUTTON = new BooleanSetting("revanced_hide_comments_timestamp_button", FALSE);
|
||||||
public static final BooleanSetting HIDE_COMMENTS_PREVIEW_COMMENT = new BooleanSetting("revanced_hide_comments_preview_comment", FALSE);
|
public static final BooleanSetting HIDE_COMMENTS_PREVIEW_COMMENT = new BooleanSetting("revanced_hide_comments_preview_comment", FALSE);
|
||||||
public static final BooleanSetting HIDE_COMMENTS_SECTION = new BooleanSetting("revanced_hide_comments_section", FALSE);
|
public static final BooleanSetting HIDE_COMMENTS_SECTION = new BooleanSetting("revanced_hide_comments_section", FALSE);
|
||||||
public static final BooleanSetting HIDE_COMMENTS_THANKS_BUTTON = new BooleanSetting("revanced_hide_comments_thanks_button", TRUE);
|
public static final BooleanSetting HIDE_COMMENTS_THANKS_BUTTON = new BooleanSetting("revanced_hide_comments_thanks_button", TRUE);
|
||||||
|
|||||||
@@ -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.26.1-dev.1
|
version = 5.26.1-dev.2
|
||||||
|
|||||||
@@ -72,7 +72,7 @@ val hideCreateButtonPatch = bytecodePatch(
|
|||||||
|
|
||||||
if (oldNavigationBarAddItemMethod != null) {
|
if (oldNavigationBarAddItemMethod != null) {
|
||||||
// In case an older version of the app is being patched, hook the old method which adds navigation bar items.
|
// In case an older version of the app is being patched, hook the old method which adds navigation bar items.
|
||||||
// Return null early if the navigation bar item title resource id is old Create button title resource id.
|
// Return null early if the navigation bar item title resource id is the old Create button title resource id.
|
||||||
oldNavigationBarAddItemFingerprint.methodOrNull?.apply {
|
oldNavigationBarAddItemFingerprint.methodOrNull?.apply {
|
||||||
val getNavigationBarItemTitleStringIndex = indexOfFirstInstructionOrThrow {
|
val getNavigationBarItemTitleStringIndex = indexOfFirstInstructionOrThrow {
|
||||||
val reference = getReference<MethodReference>()
|
val reference = getReference<MethodReference>()
|
||||||
|
|||||||
@@ -129,7 +129,7 @@ val customThemePatch = resourcePatch(
|
|||||||
val accentColorPressed by stringOption(
|
val accentColorPressed by stringOption(
|
||||||
key = "accentColorPressed",
|
key = "accentColorPressed",
|
||||||
default = "#FF1ABC54",
|
default = "#FF1ABC54",
|
||||||
title = "Pressed dark theme accent color",
|
title = "Pressed accent color",
|
||||||
description = "The color when accented buttons are pressed, by default slightly darker than accent. " +
|
description = "The color when accented buttons are pressed, by default slightly darker than accent. " +
|
||||||
"Can be a hex color or a resource reference.",
|
"Can be a hex color or a resource reference.",
|
||||||
required = true,
|
required = true,
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ val fixFacebookLoginPatch = bytecodePatch(
|
|||||||
// The Facebook SDK tries to handle the login using the Facebook app in case it is installed.
|
// The Facebook SDK tries to handle the login using the Facebook app in case it is installed.
|
||||||
// However, the Facebook app does signature checks with the app that is requesting the authentication,
|
// However, the Facebook app does signature checks with the app that is requesting the authentication,
|
||||||
// which ends up making the Facebook server reject with an invalid key hash for the app signature.
|
// which ends up making the Facebook server reject with an invalid key hash for the app signature.
|
||||||
// Override the Faceboook SDK to always handle the login using the web browser, which does not perform
|
// Override the Facebook SDK to always handle the login using the web browser, which does not perform
|
||||||
// signature checks.
|
// signature checks.
|
||||||
|
|
||||||
val katanaProxyLoginMethodHandlerClass = katanaProxyLoginMethodHandlerClassFingerprint.originalClassDef
|
val katanaProxyLoginMethodHandlerClass = katanaProxyLoginMethodHandlerClassFingerprint.originalClassDef
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
package app.revanced.patches.spotify.misc.widgets
|
package app.revanced.patches.spotify.misc.widgets
|
||||||
|
|
||||||
import app.revanced.patcher.fingerprint
|
import app.revanced.patcher.fingerprint
|
||||||
import app.revanced.util.indexOfFirstInstruction
|
|
||||||
import com.android.tools.smali.dexlib2.Opcode
|
import com.android.tools.smali.dexlib2.Opcode
|
||||||
|
|
||||||
internal val canBindAppWidgetPermissionFingerprint = fingerprint {
|
internal val canBindAppWidgetPermissionFingerprint = fingerprint {
|
||||||
|
|||||||
@@ -161,7 +161,7 @@ val hideLayoutComponentsPatch = bytecodePatch(
|
|||||||
SwitchPreference("revanced_hide_comments_by_members_header"),
|
SwitchPreference("revanced_hide_comments_by_members_header"),
|
||||||
SwitchPreference("revanced_hide_comments_section"),
|
SwitchPreference("revanced_hide_comments_section"),
|
||||||
SwitchPreference("revanced_hide_comments_create_a_short_button"),
|
SwitchPreference("revanced_hide_comments_create_a_short_button"),
|
||||||
SwitchPreference("revanced_hide_comments_timestamp_and_emoji_buttons"),
|
SwitchPreference("revanced_hide_comments_timestamp_button"),
|
||||||
SwitchPreference("revanced_hide_comments_preview_comment"),
|
SwitchPreference("revanced_hide_comments_preview_comment"),
|
||||||
SwitchPreference("revanced_hide_comments_thanks_button"),
|
SwitchPreference("revanced_hide_comments_thanks_button"),
|
||||||
),
|
),
|
||||||
|
|||||||
@@ -371,9 +371,9 @@ You will not be notified of any unexpected events."</string>
|
|||||||
<string name="revanced_hide_comments_create_a_short_button_title">Hide \'Create a Short\' button</string>
|
<string name="revanced_hide_comments_create_a_short_button_title">Hide \'Create a Short\' button</string>
|
||||||
<string name="revanced_hide_comments_create_a_short_button_summary_on">Create a Short button is hidden</string>
|
<string name="revanced_hide_comments_create_a_short_button_summary_on">Create a Short button is hidden</string>
|
||||||
<string name="revanced_hide_comments_create_a_short_button_summary_off">Create a Short button is shown</string>
|
<string name="revanced_hide_comments_create_a_short_button_summary_off">Create a Short button is shown</string>
|
||||||
<string name="revanced_hide_comments_timestamp_and_emoji_buttons_title">Hide emoji and timestamp buttons</string>
|
<string name="revanced_hide_comments_timestamp_button_title">Hide timestamp button</string>
|
||||||
<string name="revanced_hide_comments_timestamp_and_emoji_buttons_summary_on">Emoji and timestamp buttons are hidden</string>
|
<string name="revanced_hide_comments_timestamp_button_summary_on">Timestamp button is hidden</string>
|
||||||
<string name="revanced_hide_comments_timestamp_and_emoji_buttons_summary_off">Emoji and timestamp buttons are shown</string>
|
<string name="revanced_hide_comments_timestamp_button_summary_off">Timestamp button is shown</string>
|
||||||
<string name="revanced_hide_comments_preview_comment_title">Hide preview comment</string>
|
<string name="revanced_hide_comments_preview_comment_title">Hide preview comment</string>
|
||||||
<string name="revanced_hide_comments_preview_comment_summary_on">Preview comment is hidden</string>
|
<string name="revanced_hide_comments_preview_comment_summary_on">Preview comment is hidden</string>
|
||||||
<string name="revanced_hide_comments_preview_comment_summary_off">Preview comment is shown</string>
|
<string name="revanced_hide_comments_preview_comment_summary_off">Preview comment is shown</string>
|
||||||
|
|||||||
Reference in New Issue
Block a user