Skip to content

chore: Merge branch dev to main #5227

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 35 commits into from
Jun 26, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
e6876d5
fix: Add scrollable content to modern style settings dialogs (#5211)
MarcaDian Jun 22, 2025
a580764
chore: Release v5.28.1-dev.1 [skip ci]
semantic-release-bot Jun 22, 2025
1e2efad
fix(YouTube - Hide ads): Hide new type of product ad in video descrip…
ILoveOpenSourceApplications Jun 23, 2025
c5e5d25
chore: Release v5.28.1-dev.2 [skip ci]
semantic-release-bot Jun 23, 2025
1f539b1
fix(YouTube): Always use single threaded layout to resolve layout bug…
LisoUseInAIKyrios Jun 23, 2025
c68cde3
feat(YouTube): Add an option to disable toasts when changing default …
MarcaDian Jun 23, 2025
25ff2ad
chore: Release v5.29.0-dev.1 [skip ci]
semantic-release-bot Jun 23, 2025
91842dc
chore: Sync translations (#5236)
github-actions[bot] Jun 23, 2025
46b4398
feat(Crunchyroll): Add `Hide ads` patch (#5201)
hoo-dles Jun 23, 2025
6580c28
chore: Release v5.29.0-dev.2 [skip ci]
semantic-release-bot Jun 23, 2025
1b00c90
fix(YouTube): Fix refactoring app startup exception
LisoUseInAIKyrios Jun 23, 2025
9b96576
chore: Release v5.29.0-dev.3 [skip ci]
semantic-release-bot Jun 23, 2025
5d6ec9e
fix(YouTube - Hide Shorts components): Fix "Hide Use this sound butto…
ILoveOpenSourceApplications Jun 23, 2025
25b4894
chore: Release v5.29.0-dev.4 [skip ci]
semantic-release-bot Jun 23, 2025
0294533
fix(Google Photos): Resolve startup crash for Android 5.0 devices
LisoUseInAIKyrios Jun 23, 2025
446de1c
chore: Release v5.29.0-dev.5 [skip ci]
semantic-release-bot Jun 23, 2025
274dcc6
feat(YouTube - Hide video action buttons): Add `Hide Stop ads` (#5245)
ILoveOpenSourceApplications Jun 24, 2025
857d3e6
chore: Release v5.29.0-dev.6 [skip ci]
semantic-release-bot Jun 24, 2025
99b832a
chore: Fix compile warning
LisoUseInAIKyrios Jun 24, 2025
fd2ae7b
chore: Sync translations (#5251)
github-actions[bot] Jun 24, 2025
b399ecb
fix(YouTube - Hide Shorts components): Fix "Hide Use this template bu…
ILoveOpenSourceApplications Jun 24, 2025
2f22d45
fix(YouTube - Hide layout components): Fix "Hide video description at…
ILoveOpenSourceApplications Jun 24, 2025
e4eef67
chore: Release v5.29.0-dev.7 [skip ci]
semantic-release-bot Jun 24, 2025
d284c3d
feat(YouTube): Support version `20.13.41` (#5253)
LisoUseInAIKyrios Jun 25, 2025
745ff89
chore: Release v5.29.0-dev.8 [skip ci]
semantic-release-bot Jun 25, 2025
78b25aa
feat: Add `Spoof app signature` patch (#5158)
MarkusTieger Jun 25, 2025
796d229
chore: Release v5.29.0-dev.9 [skip ci]
semantic-release-bot Jun 25, 2025
240897a
feat(YouTube - Hide Shorts components): Add `Hide Effects button` (#5…
LisoUseInAIKyrios Jun 25, 2025
89f06fe
chore: Fix typo
LisoUseInAIKyrios Jun 25, 2025
8bed421
chore: Release v5.29.0-dev.10 [skip ci]
semantic-release-bot Jun 25, 2025
83ccfa8
feat(Cricbuzz): Add `Hide ads` patch (#4998)
agrawalsourav98 Jun 26, 2025
38d5815
chore: Sync translations (#5257)
github-actions[bot] Jun 26, 2025
3f63f30
chore: Release v5.29.0-dev.11 [skip ci]
semantic-release-bot Jun 26, 2025
4d42c56
chore: Sync translations (#5258)
github-actions[bot] Jun 26, 2025
9c4b1a6
chore: Fix api dump
LisoUseInAIKyrios Jun 26, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
97 changes: 97 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,100 @@
# [5.29.0-dev.11](https://github.com/ReVanced/revanced-patches/compare/v5.29.0-dev.10...v5.29.0-dev.11) (2025-06-26)


### Features

* **Cricbuzz:** Add `Hide ads` patch ([#4998](https://github.com/ReVanced/revanced-patches/issues/4998)) ([83ccfa8](https://github.com/ReVanced/revanced-patches/commit/83ccfa8e1b5d5a44c55ef659484acf3cc08d3346))

# [5.29.0-dev.10](https://github.com/ReVanced/revanced-patches/compare/v5.29.0-dev.9...v5.29.0-dev.10) (2025-06-25)


### Features

* **YouTube - Hide Shorts components:** Add `Hide Effects button` ([#5255](https://github.com/ReVanced/revanced-patches/issues/5255)) ([240897a](https://github.com/ReVanced/revanced-patches/commit/240897a94008ce9a148c87bb41b978d553d5a6f5))

# [5.29.0-dev.9](https://github.com/ReVanced/revanced-patches/compare/v5.29.0-dev.8...v5.29.0-dev.9) (2025-06-25)


### Features

* Add `Spoof app signature` patch ([#5158](https://github.com/ReVanced/revanced-patches/issues/5158)) ([78b25aa](https://github.com/ReVanced/revanced-patches/commit/78b25aa4e87ec3f9df1d57831b48a39029969416))

# [5.29.0-dev.8](https://github.com/ReVanced/revanced-patches/compare/v5.29.0-dev.7...v5.29.0-dev.8) (2025-06-25)


### Features

* **YouTube:** Support version `20.13.41` ([#5253](https://github.com/ReVanced/revanced-patches/issues/5253)) ([d284c3d](https://github.com/ReVanced/revanced-patches/commit/d284c3dd3277430b6885e7c27ee02d062dcefc85))

# [5.29.0-dev.7](https://github.com/ReVanced/revanced-patches/compare/v5.29.0-dev.6...v5.29.0-dev.7) (2025-06-24)


### Bug Fixes

* **YouTube - Hide layout components:** Fix "Hide video description attributes" ([#5250](https://github.com/ReVanced/revanced-patches/issues/5250)) ([2f22d45](https://github.com/ReVanced/revanced-patches/commit/2f22d45eb80745ac64fbea44c8055ebe7925a586))
* **YouTube - Hide Shorts components:** Fix "Hide Use this template button" ([#5249](https://github.com/ReVanced/revanced-patches/issues/5249)) ([b399ecb](https://github.com/ReVanced/revanced-patches/commit/b399ecbb6a222d82dd5e4b3417c9f7eff4324adb))

# [5.29.0-dev.6](https://github.com/ReVanced/revanced-patches/compare/v5.29.0-dev.5...v5.29.0-dev.6) (2025-06-24)


### Features

* **YouTube - Hide video action buttons:** Add `Hide Stop ads` ([#5245](https://github.com/ReVanced/revanced-patches/issues/5245)) ([274dcc6](https://github.com/ReVanced/revanced-patches/commit/274dcc676e009be63eb6970de33abacd34dc6560))

# [5.29.0-dev.5](https://github.com/ReVanced/revanced-patches/compare/v5.29.0-dev.4...v5.29.0-dev.5) (2025-06-23)


### Bug Fixes

* **Google Photos:** Resolve startup crash for Android 5.0 devices ([0294533](https://github.com/ReVanced/revanced-patches/commit/0294533c4d9a321aea086eedb4e46385ae9a026e))

# [5.29.0-dev.4](https://github.com/ReVanced/revanced-patches/compare/v5.29.0-dev.3...v5.29.0-dev.4) (2025-06-23)


### Bug Fixes

* **YouTube - Hide Shorts components:** Fix "Hide Use this sound button" ([#5233](https://github.com/ReVanced/revanced-patches/issues/5233)) ([5d6ec9e](https://github.com/ReVanced/revanced-patches/commit/5d6ec9e94a6221a0f32762d5bede893e9e7457fc))

# [5.29.0-dev.3](https://github.com/ReVanced/revanced-patches/compare/v5.29.0-dev.2...v5.29.0-dev.3) (2025-06-23)


### Bug Fixes

* **YouTube:** Fix refactoring app startup exception ([1b00c90](https://github.com/ReVanced/revanced-patches/commit/1b00c907f4b90f4659afb4a54ba61ac2835b460d))

# [5.29.0-dev.2](https://github.com/ReVanced/revanced-patches/compare/v5.29.0-dev.1...v5.29.0-dev.2) (2025-06-23)


### Features

* **Crunchyroll:** Add `Hide ads` patch ([#5201](https://github.com/ReVanced/revanced-patches/issues/5201)) ([46b4398](https://github.com/ReVanced/revanced-patches/commit/46b4398fd6ca223391ed8f497a8347c2313421b7))

# [5.29.0-dev.1](https://github.com/ReVanced/revanced-patches/compare/v5.28.1-dev.2...v5.29.0-dev.1) (2025-06-23)


### Bug Fixes

* **YouTube:** Always use single threaded layout to resolve layout bugs in unpatched YouTube ([#5226](https://github.com/ReVanced/revanced-patches/issues/5226)) ([1f539b1](https://github.com/ReVanced/revanced-patches/commit/1f539b1396526b2c767d77a804bd0308ee4a42ec))


### Features

* **YouTube:** Add an option to disable toasts when changing default playback speed or quality ([#5230](https://github.com/ReVanced/revanced-patches/issues/5230)) ([c68cde3](https://github.com/ReVanced/revanced-patches/commit/c68cde3a896450874cc571be5c4723387db96032))

## [5.28.1-dev.2](https://github.com/ReVanced/revanced-patches/compare/v5.28.1-dev.1...v5.28.1-dev.2) (2025-06-23)


### Bug Fixes

* **YouTube - Hide ads:** Hide new type of product ad in video description ([#5225](https://github.com/ReVanced/revanced-patches/issues/5225)) ([1e2efad](https://github.com/ReVanced/revanced-patches/commit/1e2efad7b2714c395ed6b0a77cbbf8a2265df520))

## [5.28.1-dev.1](https://github.com/ReVanced/revanced-patches/compare/v5.28.0...v5.28.1-dev.1) (2025-06-22)


### Bug Fixes

* Add scrollable content to modern style settings dialogs ([#5211](https://github.com/ReVanced/revanced-patches/issues/5211)) ([e6876d5](https://github.com/ReVanced/revanced-patches/commit/e6876d510d28f6a3a41ec1722a033b3e30a22c65))

# [5.28.0](https://github.com/ReVanced/revanced-patches/compare/v5.27.0...v5.28.0) (2025-06-20)


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
import android.widget.LinearLayout;

import androidx.annotation.Nullable;
import androidx.annotation.RequiresApi;

import java.net.HttpURLConnection;
import java.net.MalformedURLException;
Expand All @@ -28,7 +27,6 @@

import app.revanced.extension.shared.requests.Requester;
import app.revanced.extension.shared.requests.Route;
import app.revanced.extension.shared.Utils;

@SuppressWarnings("unused")
public class GmsCoreSupport {
Expand Down Expand Up @@ -109,7 +107,6 @@ private static void showBatteryOptimizationDialog(Activity context,
/**
* Injection point.
*/
@RequiresApi(api = Build.VERSION_CODES.N)
public static void checkGmsCore(Activity context) {
try {
// Verify the user has not included GmsCore for a root installation.
Expand Down Expand Up @@ -157,7 +154,9 @@ public static void checkGmsCore(Activity context) {
}

// Check if GmsCore is currently running in the background.
try (var client = context.getContentResolver().acquireContentProviderClient(GMS_CORE_PROVIDER)) {
var client = context.getContentResolver().acquireContentProviderClient(GMS_CORE_PROVIDER);
//noinspection TryFinallyCanBeTryWithResources
try {
if (client == null) {
Logger.printInfo(() -> "GmsCore is not running in the background");
checkIfDontKillMyAppSupportsManufacturer();
Expand All @@ -167,6 +166,8 @@ public static void checkGmsCore(Activity context) {
"gms_core_dialog_open_website_text",
(dialog, id) -> openDontKillMyApp());
}
} finally {
if (client != null) client.close();
}
} catch (Exception ex) {
Logger.printException(() -> "checkGmsCore failure", ex);
Expand Down Expand Up @@ -226,6 +227,11 @@ private static void openDontKillMyApp() {
* @return If GmsCore is not whitelisted from battery optimizations.
*/
private static boolean batteryOptimizationsEnabled(Context context) {
//noinspection ObsoleteSdkInt
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.M) {
// Android 5.0 does not have battery optimization settings.
return false;
}
var powerManager = (PowerManager) context.getSystemService(Context.POWER_SERVICE);
return !powerManager.isIgnoringBatteryOptimizations(GMS_CORE_PACKAGE_NAME);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
import android.widget.FrameLayout;
import android.widget.LinearLayout;
import android.widget.RelativeLayout;
import android.widget.ScrollView;
import android.widget.TextView;
import android.widget.Toast;
import android.widget.Toolbar;
Expand Down Expand Up @@ -773,16 +774,15 @@ public static Pair<Dialog, LinearLayout> createCustomDialog(
Dialog dialog = new Dialog(context);
dialog.requestWindowFeature(Window.FEATURE_NO_TITLE); // Remove default title bar.

// Create main layout.
LinearLayout mainLayout = new LinearLayout(context);
mainLayout.setOrientation(LinearLayout.VERTICAL);

// Preset size constants.
final int dip4 = dipToPixels(4);
final int dip8 = dipToPixels(8);
final int dip16 = dipToPixels(16);
final int dip24 = dipToPixels(24);

// Create main layout.
LinearLayout mainLayout = new LinearLayout(context);
mainLayout.setOrientation(LinearLayout.VERTICAL);
mainLayout.setPadding(dip24, dip16, dip24, dip24);
// Set rounded rectangle background.
ShapeDrawable mainBackground = new ShapeDrawable(new RoundRectShape(
Expand All @@ -802,55 +802,71 @@ public static Pair<Dialog, LinearLayout> createCustomDialog(
ViewGroup.LayoutParams.MATCH_PARENT,
ViewGroup.LayoutParams.WRAP_CONTENT
);
layoutParams.setMargins(0, 0, 0, dip8);
layoutParams.setMargins(0, 0, 0, dip16);
titleView.setLayoutParams(layoutParams);
mainLayout.addView(titleView);
}

// Message (if not replaced by EditText).
if (editText == null && message != null) {
TextView messageView = new TextView(context);
messageView.setText(message); // Supports Spanned (HTML).
messageView.setTextSize(16);
messageView.setTextColor(getAppForegroundColor());
// Enable HTML link clicking if the message contains links.
if (message instanceof Spanned) {
messageView.setMovementMethod(LinkMovementMethod.getInstance());
// Create content container (message/EditText) inside a ScrollView only if message or editText is provided.
ScrollView contentScrollView = null;
LinearLayout contentContainer = null;
if (message != null || editText != null) {
contentScrollView = new ScrollView(context);
contentScrollView.setVerticalScrollBarEnabled(false); // Disable the vertical scrollbar.
contentScrollView.setOverScrollMode(View.OVER_SCROLL_NEVER);
if (editText != null) {
ShapeDrawable scrollViewBackground = new ShapeDrawable(new RoundRectShape(
createCornerRadii(10), null, null));
scrollViewBackground.getPaint().setColor(getEditTextBackground());
contentScrollView.setPadding(dip8, dip8, dip8, dip8);
contentScrollView.setBackground(scrollViewBackground);
contentScrollView.setClipToOutline(true);
}
LinearLayout.LayoutParams messageParams = new LinearLayout.LayoutParams(
LinearLayout.LayoutParams contentParams = new LinearLayout.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT,
ViewGroup.LayoutParams.WRAP_CONTENT
0,
1.0f // Weight to take available space.
);
messageParams.setMargins(0, dip8, 0, dip16);
messageView.setLayoutParams(messageParams);
mainLayout.addView(messageView);
}
contentScrollView.setLayoutParams(contentParams);
contentContainer = new LinearLayout(context);
contentContainer.setOrientation(LinearLayout.VERTICAL);
contentScrollView.addView(contentContainer);

// Message (if not replaced by EditText).
if (editText == null && message != null) {
TextView messageView = new TextView(context);
messageView.setText(message); // Supports Spanned (HTML).
messageView.setTextSize(16);
messageView.setTextColor(getAppForegroundColor());
// Enable HTML link clicking if the message contains links.
if (message instanceof Spanned) {
messageView.setMovementMethod(LinkMovementMethod.getInstance());
}
LinearLayout.LayoutParams messageParams = new LinearLayout.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT,
ViewGroup.LayoutParams.WRAP_CONTENT
);
messageView.setLayoutParams(messageParams);
contentContainer.addView(messageView);
}

// EditText (if provided).
if (editText != null) {
// Remove EditText from its current parent, if any.
ViewGroup parent = (ViewGroup) editText.getParent();
if (parent != null) {
parent.removeView(editText);
// EditText (if provided).
if (editText != null) {
// Remove EditText from its current parent, if any.
ViewGroup parent = (ViewGroup) editText.getParent();
if (parent != null) {
parent.removeView(editText);
}
// Style the EditText to match the dialog theme.
editText.setTextColor(getAppForegroundColor());
editText.setBackgroundColor(Color.TRANSPARENT);
editText.setPadding(0, 0, 0, 0);
LinearLayout.LayoutParams editTextParams = new LinearLayout.LayoutParams(
LinearLayout.LayoutParams.MATCH_PARENT,
LinearLayout.LayoutParams.WRAP_CONTENT
);
contentContainer.addView(editText, editTextParams);
}
// Style the EditText to match the dialog theme.
editText.setTextColor(getAppForegroundColor());
editText.setBackgroundColor(isDarkModeEnabled() ? Color.BLACK : Color.WHITE);
editText.setPadding(dip8, dip8, dip8, dip8);
ShapeDrawable editTextBackground = new ShapeDrawable(new RoundRectShape(
createCornerRadii(10), null, null));
editTextBackground.getPaint().setColor(getEditTextBackground()); // Background color for EditText.
editText.setBackground(editTextBackground);

LinearLayout.LayoutParams editTextParams = new LinearLayout.LayoutParams(
LinearLayout.LayoutParams.MATCH_PARENT,
LinearLayout.LayoutParams.WRAP_CONTENT
);
editTextParams.setMargins(0, dip8, 0, dip16);
// Prevent buttons from moving off the screen by fixing the height of the EditText.
final int maxHeight = (int) (context.getResources().getDisplayMetrics().heightPixels * 0.6);
editText.setMaxHeight(maxHeight);
mainLayout.addView(editText, 1, editTextParams);
}

// Button container.
Expand All @@ -861,7 +877,7 @@ public static Pair<Dialog, LinearLayout> createCustomDialog(
LinearLayout.LayoutParams.MATCH_PARENT,
LinearLayout.LayoutParams.WRAP_CONTENT
);
buttonContainerParams.setMargins(0, dip8, 0, 0);
buttonContainerParams.setMargins(0, dip16, 0, 0);
buttonContainer.setLayoutParams(buttonContainerParams);

// Lists to track buttons.
Expand Down Expand Up @@ -1036,25 +1052,29 @@ public static Pair<Dialog, LinearLayout> createCustomDialog(
}
}

// Add ScrollView to main layout only if content exist.
if (contentScrollView != null) {
mainLayout.addView(contentScrollView);
}
mainLayout.addView(buttonContainer);
dialog.setContentView(mainLayout);

// Set dialog window attributes.
Window window = dialog.getWindow();
if (window != null) {
setDialogWindowParameters(context, window);
setDialogWindowParameters(window);
}

return new Pair<>(dialog, mainLayout);
}

public static void setDialogWindowParameters(Context context, Window window) {
public static void setDialogWindowParameters(Window window) {
WindowManager.LayoutParams params = window.getAttributes();

Resources resources = context.getResources();
DisplayMetrics displayMetrics = resources.getDisplayMetrics();
DisplayMetrics displayMetrics = Resources.getSystem().getDisplayMetrics();
int portraitWidth = (int) (displayMetrics.widthPixels * 0.9);
if (resources.getConfiguration().orientation == Configuration.ORIENTATION_LANDSCAPE) {

if (Resources.getSystem().getConfiguration().orientation == Configuration.ORIENTATION_LANDSCAPE) {
portraitWidth = (int) Math.min(portraitWidth, displayMetrics.heightPixels * 0.9);
}
params.width = portraitWidth;
Expand Down Expand Up @@ -1199,7 +1219,7 @@ public static int getDialogBackgroundColor() {
return darkColor == Color.BLACK
// Lighten the background a little if using AMOLED dark theme
// as the dialogs are almost invisible.
? 0xFF0D0D0D
? 0xFF080808 // 3%
: darkColor;
}
return getThemeLightColor();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -129,8 +129,7 @@ static void issueWarning(Activity activity, Collection<Check> failedChecks) {
ImageView iconView = new ImageView(activity);
iconView.setImageResource(Utils.getResourceIdentifier("revanced_ic_dialog_alert", "drawable"));
iconView.setColorFilter(Utils.getAppForegroundColor(), PorterDuff.Mode.SRC_IN);
final int dip8 = dipToPixels(8);
iconView.setPadding(0, dip8, 0, dip8);
iconView.setPadding(0, 0, 0, 0);
LinearLayout.LayoutParams iconParams = new LinearLayout.LayoutParams(
LinearLayout.LayoutParams.WRAP_CONTENT,
LinearLayout.LayoutParams.WRAP_CONTENT
Expand Down
Loading