mirror of
https://github.com/ReVanced/revanced-patches.git
synced 2026-01-15 15:33:13 +00:00
Compare commits
45 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
14f7d514d2 | ||
|
|
78d901338f | ||
|
|
9ae3d0546c | ||
|
|
3076a16d14 | ||
|
|
f8e1f2fe18 | ||
|
|
a9611f304e | ||
|
|
7c0e183df5 | ||
|
|
15e1ced2c9 | ||
|
|
bde7f99b5b | ||
|
|
60866af97d | ||
|
|
6580f71392 | ||
|
|
9c57961680 | ||
|
|
1d7a9ac437 | ||
|
|
51e08fb0b6 | ||
|
|
91feea1c50 | ||
|
|
fc8bfff427 | ||
|
|
9a3307c1b1 | ||
|
|
eff806c5e3 | ||
|
|
b45a44ff3f | ||
|
|
391e8fa8f6 | ||
|
|
dbf0668f28 | ||
|
|
b228640e4f | ||
|
|
0ddb2df640 | ||
|
|
c9525d0c26 | ||
|
|
3c5832eda2 | ||
|
|
eef7e87bbf | ||
|
|
535f621f20 | ||
|
|
695a0d14ad | ||
|
|
f70e54545b | ||
|
|
353f036a72 | ||
|
|
4d305775a0 | ||
|
|
d726443ca0 | ||
|
|
c5046edf8d | ||
|
|
e15d6afed1 | ||
|
|
f5055997c7 | ||
|
|
e6f41988dc | ||
|
|
c8567d35ef | ||
|
|
cea92cacfd | ||
|
|
8f83fc1edf | ||
|
|
b9e33d0d08 | ||
|
|
7df8f6b42a | ||
|
|
ac117f04df | ||
|
|
d3bb96d8b3 | ||
|
|
a31e4b4df3 | ||
|
|
90144fc55a |
61
.github/ISSUE_TEMPLATE/bug-issue.yml
vendored
Normal file
61
.github/ISSUE_TEMPLATE/bug-issue.yml
vendored
Normal file
@@ -0,0 +1,61 @@
|
||||
name: 🐞 Bug report
|
||||
description: Report a very clearly broken issue.
|
||||
title: 'bug: <title>'
|
||||
labels: [bug]
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
# ReVanced bug report
|
||||
|
||||
Important to note that your issue may have already been reported before. Please check for existing issues [here](https://github.com/revanced/revanced-patches/labels/bug).
|
||||
|
||||
- type: dropdown
|
||||
attributes:
|
||||
label: Type
|
||||
options:
|
||||
- Error while patching
|
||||
- Error at runtime
|
||||
- Cosmetic
|
||||
- Other
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Bug description
|
||||
description: How did you find the bug? Any additional details that might help?
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Steps to reproduce
|
||||
description: Add the steps to reproduce this bug including your environment.
|
||||
placeholder: Step 1. Download some files. Step 2. ...
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Relevant log output
|
||||
description: Please copy and paste any relevant log output. This will be automatically formatted into code, so no need for backticks.
|
||||
render: shell
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Screenshots or videos
|
||||
description: Add screenshots or videos that show the bug here.
|
||||
placeholder: Drag and drop the screenshots/videos into this box.
|
||||
validations:
|
||||
required: false
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Solution
|
||||
description: If applicable, add a possible solution.
|
||||
validations:
|
||||
required: false
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Additional context
|
||||
description: Add additional context here.
|
||||
validations:
|
||||
required: false
|
||||
24
.github/ISSUE_TEMPLATE/bug-report.md
vendored
24
.github/ISSUE_TEMPLATE/bug-report.md
vendored
@@ -1,24 +0,0 @@
|
||||
---
|
||||
name: Bug report
|
||||
about: Create a bug report on patches
|
||||
title: 'problem: `some-patch`'
|
||||
labels: bug
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
## 🐞 Issue
|
||||
|
||||
<!-- Describe your issue in detail here -->
|
||||
|
||||
## ⚙ Reproduce
|
||||
|
||||
<!-- Include your environment and steps to reproduce the issue as detailed as possible -->
|
||||
|
||||
## 🛠 Solution
|
||||
|
||||
<!-- If applicable, add a possible solution -->
|
||||
|
||||
## ⚠ Additional context
|
||||
|
||||
<!-- Add any other context about the problem here -->
|
||||
8
.github/ISSUE_TEMPLATE/config.yml
vendored
Normal file
8
.github/ISSUE_TEMPLATE/config.yml
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
blank_issues_enabled: false
|
||||
contact_links:
|
||||
- name: 📃 Documentation
|
||||
url: https://github.com/revanced/revanced-documentation/
|
||||
about: Don't know how or where to start? Check out our documentation!
|
||||
- name: 🗨 Discussions
|
||||
url: https://github.com/revanced/revanced-suggestions/discussions
|
||||
about: Got something you think should change or be added? Search for or start a new discussion!
|
||||
46
.github/ISSUE_TEMPLATE/feature-issue.yml
vendored
Normal file
46
.github/ISSUE_TEMPLATE/feature-issue.yml
vendored
Normal file
@@ -0,0 +1,46 @@
|
||||
name: ⭐ Feature request
|
||||
description: Create a detailed feature request.
|
||||
title: 'feat: <title>'
|
||||
labels: [feature-request]
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
# ReVanced feature request
|
||||
|
||||
Do not submit requests for patches here. Please submit them [here](https://github.com/orgs/revanced/discussions/categories/patches) instead.
|
||||
Important to note that your feature request may have already been made before. Please check for existing feature requests [here](https://github.com/revanced/revanced-patches/labels/feature-request).
|
||||
|
||||
- type: dropdown
|
||||
attributes:
|
||||
label: Type
|
||||
options:
|
||||
- Functionality
|
||||
- Cosmetic
|
||||
- Other
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Issue
|
||||
description: What is the current problem. Why does it require a feature request?
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Feature
|
||||
description: Describe your feature in detail. How does it solve the issue?
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Motivation
|
||||
description: Why should your feature should be considered?
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Additional context
|
||||
description: Add additional context here.
|
||||
validations:
|
||||
required: false
|
||||
24
.github/ISSUE_TEMPLATE/feature_request.md
vendored
24
.github/ISSUE_TEMPLATE/feature_request.md
vendored
@@ -1,24 +0,0 @@
|
||||
---
|
||||
name: Feature request
|
||||
about: Suggest a change to some patch. Do not submit suggestions for patches here.
|
||||
title: 'feat: some feature'
|
||||
labels: feature-request
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
## 🐞 Issue
|
||||
|
||||
<!-- Explain here, what the current problem is and why it leads you to request a feature change -->
|
||||
|
||||
## ❗ Solution
|
||||
|
||||
<!-- Explain how your current issue can be solved -->
|
||||
|
||||
## ❓ Motivation
|
||||
|
||||
<!-- Explain why your feature should be considered -->
|
||||
|
||||
## ⚠ Additional context
|
||||
|
||||
<!-- Add any other context or screenshots about the feature request here -->
|
||||
182
CHANGELOG.md
182
CHANGELOG.md
@@ -1,3 +1,185 @@
|
||||
## [2.28.2](https://github.com/revanced/revanced-patches/compare/v2.28.1...v2.28.2) (2022-08-02)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* remove requirement for solution [skip ci] ([#271](https://github.com/revanced/revanced-patches/issues/271)) ([553fad3](https://github.com/revanced/revanced-patches/commit/553fad3fe1bb79bdf34e9f91c0e1cbfda78e1054))
|
||||
|
||||
## [2.28.1](https://github.com/revanced/revanced-patches/compare/v2.28.0...v2.28.1) (2022-07-31)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* add missing permission to reboot app ([#260](https://github.com/revanced/revanced-patches/issues/260)) ([6ced6df](https://github.com/revanced/revanced-patches/commit/6ced6df8ed7642dea51e1acd1c12f4de4874b972))
|
||||
|
||||
# [2.28.0](https://github.com/revanced/revanced-patches/compare/v2.27.0...v2.28.0) (2022-07-31)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* add `custom-video-buffer` patch ([9f117c7](https://github.com/revanced/revanced-patches/commit/9f117c74cdbdcf98eae97cf4c37f0baca451d695))
|
||||
|
||||
# [2.27.0](https://github.com/revanced/revanced-patches/compare/v2.26.0...v2.27.0) (2022-07-31)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* `settings` patch ([0e229a4](https://github.com/revanced/revanced-patches/commit/0e229a46cb5b8b74183c47a6eae08d667f941406))
|
||||
|
||||
# [2.26.0](https://github.com/revanced/revanced-patches/compare/v2.25.3...v2.26.0) (2022-07-31)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* `ResourceUtils` helper class ([e0e1144](https://github.com/revanced/revanced-patches/commit/e0e11447a7ac184d43c75955854c52c6992ff667))
|
||||
|
||||
## [2.25.3](https://github.com/revanced/revanced-patches/compare/v2.25.2...v2.25.3) (2022-07-29)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* actually call `VideoInformation.setCurrentVideoId` first ([5c62d0a](https://github.com/revanced/revanced-patches/commit/5c62d0a2e0217de1b9563a41b4e94ed63230440f))
|
||||
|
||||
## [2.25.2](https://github.com/revanced/revanced-patches/compare/v2.25.1...v2.25.2) (2022-07-26)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* rename `default-video-quality` to `remember-video-quality` ([7f6cdfd](https://github.com/revanced/revanced-patches/commit/7f6cdfd7c2b5e72742bbb92e4d584f722cb82cae))
|
||||
|
||||
## [2.25.1](https://github.com/revanced/revanced-patches/compare/v2.25.0...v2.25.1) (2022-07-26)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* `default-video-quality` patch crashing ([#227](https://github.com/revanced/revanced-patches/issues/227)) ([379327a](https://github.com/revanced/revanced-patches/commit/379327a6b2325ef93c7107472343dd9fd85a0f56))
|
||||
|
||||
# [2.25.0](https://github.com/revanced/revanced-patches/compare/v2.24.0...v2.25.0) (2022-07-26)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* `general-reddit-ads` patch ([#235](https://github.com/revanced/revanced-patches/issues/235)) ([d63c016](https://github.com/revanced/revanced-patches/commit/d63c016d38d2a5b1d152abccdb582990987a1911))
|
||||
|
||||
# [2.24.0](https://github.com/revanced/revanced-patches/compare/v2.23.0...v2.24.0) (2022-07-26)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* `music-microg-support` patch ([#208](https://github.com/revanced/revanced-patches/issues/208)) ([50863e9](https://github.com/revanced/revanced-patches/commit/50863e97cc8eba7e1ad6d11b4821baa45fdd29c4))
|
||||
|
||||
# [2.23.0](https://github.com/revanced/revanced-patches/compare/v2.22.2...v2.23.0) (2022-07-26)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* bump compatibility of YouTube Music patches to v5.16.51 ([#238](https://github.com/revanced/revanced-patches/issues/238)) ([4fa2a12](https://github.com/revanced/revanced-patches/commit/4fa2a127d715f953a1e4efacaecbc218209a01f3))
|
||||
|
||||
## [2.22.2](https://github.com/revanced/revanced-patches/compare/v2.22.1...v2.22.2) (2022-07-26)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* bump youtube version to 17.29.34 ([#236](https://github.com/revanced/revanced-patches/issues/236)) ([be6494a](https://github.com/revanced/revanced-patches/commit/be6494a80989044cba961dc22fc58ffb2e8591f0))
|
||||
|
||||
## [2.22.1](https://github.com/revanced/revanced-patches/compare/v2.22.0...v2.22.1) (2022-07-24)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* remove broken video-quality patch ([e8d516a](https://github.com/revanced/revanced-patches/commit/e8d516af896971a09bb9aca8b00e7b7bb57c3dd9))
|
||||
|
||||
# [2.22.0](https://github.com/revanced/revanced-patches/compare/v2.21.3...v2.22.0) (2022-07-24)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* `default-video-quality` patch ([#141](https://github.com/revanced/revanced-patches/issues/141)) ([609ad7d](https://github.com/revanced/revanced-patches/commit/609ad7dee7e29b2ecc4e95a93e9dab1646b4b050))
|
||||
|
||||
# [2.12.0](https://github.com/Canny1913/revanced-patches/compare/v2.11.0...v2.12.0) (2022-07-24)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* `autorepeat-by-default` patch ([#148](https://github.com/Canny1913/revanced-patches/issues/148)) ([fe628ba](https://github.com/Canny1913/revanced-patches/commit/fe628ba909d89ea0bf3d95fe94ca78ef819677da))
|
||||
* `codecs-unlock` patch and update Music patches to `5.14.53` ([2437d30](https://github.com/Canny1913/revanced-patches/commit/2437d3070f6a630d353619f642cefebd47abee20))
|
||||
* `exclusive-audio-playback` patch ([#153](https://github.com/Canny1913/revanced-patches/issues/153)) ([9beff95](https://github.com/Canny1913/revanced-patches/commit/9beff9567f1586e5c58690c1f1d2f7f204025ab7))
|
||||
* `hrd-auto-brightness` ([#152](https://github.com/Canny1913/revanced-patches/issues/152)) ([5f2e9ba](https://github.com/Canny1913/revanced-patches/commit/5f2e9ba30b7432be04bdc9f9f7ec7ac75fdc4b34))
|
||||
* `minimized-playback` patch for YouTube Kids videos ([#201](https://github.com/Canny1913/revanced-patches/issues/201)) ([31e3b42](https://github.com/Canny1913/revanced-patches/commit/31e3b42c6bbce0d00f049b8a69bafc94900bb3b4))
|
||||
* `old-quality-layout` patch ([2497425](https://github.com/Canny1913/revanced-patches/commit/2497425c9f11b8b14c861c2f0f34ff47bdbfac53))
|
||||
* `swipe-controls` with active engagement panel ([#177](https://github.com/Canny1913/revanced-patches/issues/177)) ([000ec6d](https://github.com/Canny1913/revanced-patches/commit/000ec6d8f6ecbb910a06ec852564ee9e5f03dcf8))
|
||||
* add v17.28.34 compatiblity for the `hide-shorts-button` patch ([#224](https://github.com/Canny1913/revanced-patches/issues/224)) ([76166bb](https://github.com/Canny1913/revanced-patches/commit/76166bb35f940ef661e2802f5bf93ed91f2e2913))
|
||||
* autoplay not working. ([586eed5](https://github.com/Canny1913/revanced-patches/commit/586eed515fc7ff8e3b1b150b0d34610b39480bb5))
|
||||
* autoplay still enabled when using patch ([4f96129](https://github.com/Canny1913/revanced-patches/commit/4f961298f6cb6417ee3f3d6f8ac7ce96594ed03b))
|
||||
* bump youtube version for swipe-controls patch ([ff207a5](https://github.com/Canny1913/revanced-patches/commit/ff207a57af7d3c15a8127f4465e97da23878b0d6))
|
||||
* bump youtube version to 17.27.39 ([b93401a](https://github.com/Canny1913/revanced-patches/commit/b93401a391c0ed4887dd1376ac253f74f98a8d7e))
|
||||
* bump youtube version to 17.28.34 ([#225](https://github.com/Canny1913/revanced-patches/issues/225)) ([738cb6a](https://github.com/Canny1913/revanced-patches/commit/738cb6af177e92bbff8c02d6808fe416c0ad2582))
|
||||
* check if node has attributes before accessing them ([2d2ed87](https://github.com/Canny1913/revanced-patches/commit/2d2ed870dacfe092eb6acbcaae5e51775c611322))
|
||||
* compatibility of `force-vp9-codec-parent-fingerprint` fingerprint with version `17.27.39` ([523fd86](https://github.com/Canny1913/revanced-patches/commit/523fd8627bc965a724267f725c28fba5e7a25a04))
|
||||
* constrain `old-quality-layout` to older version ([add7232](https://github.com/Canny1913/revanced-patches/commit/add72326199e90f677b450b553b9d88c0bb4c490))
|
||||
* crash when using force-vp9-codec patch ([7a35e5c](https://github.com/Canny1913/revanced-patches/commit/7a35e5c985b412d5a84083d1416d3207a40b3e97))
|
||||
* disable-fullscreen-panels patch not working ([#213](https://github.com/Canny1913/revanced-patches/issues/213)) ([5372105](https://github.com/Canny1913/revanced-patches/commit/5372105e72607f289b779e4c2a3c13f3458842ce))
|
||||
* display codename for patch names ([10c53f7](https://github.com/Canny1913/revanced-patches/commit/10c53f720df3e70b9d59e8bc3219d56b996f03db))
|
||||
* exclude `swipe-controls` by default due to instability ([bdeb8e0](https://github.com/Canny1913/revanced-patches/commit/bdeb8e04609a0ca94d9e2921bf7d486b9e229cec))
|
||||
* incorrect package name in gradle task ([152b2c9](https://github.com/Canny1913/revanced-patches/commit/152b2c90cf102170648fcc168da10f46743bdc63))
|
||||
* invalid regex ([26bf1d8](https://github.com/Canny1913/revanced-patches/commit/26bf1d818f953abc061126d8b91f17cd9008ba1d))
|
||||
* listing of wrong fingerprint class ([#147](https://github.com/Canny1913/revanced-patches/issues/147)) ([95c2bbd](https://github.com/Canny1913/revanced-patches/commit/95c2bbdd1deb1d76f1177b48286fa6a3bc9f7663))
|
||||
* make all patches toggleable with settings ([#202](https://github.com/Canny1913/revanced-patches/issues/202)) ([7e1d82f](https://github.com/Canny1913/revanced-patches/commit/7e1d82f1161237632c3a57f109db6b8903006b33))
|
||||
* make the patch work w/o settings ([7f0be5c](https://github.com/Canny1913/revanced-patches/commit/7f0be5c08b738d7baeef7ad3e167aab623c2d08e))
|
||||
* references to integrations in `return-youtube-dislike` patch ([5824c2c](https://github.com/Canny1913/revanced-patches/commit/5824c2cdfb1a2d7b8d68044388e5e0746ef2ca09))
|
||||
* remove "dependency" ([b93cb9b](https://github.com/Canny1913/revanced-patches/commit/b93cb9b8dd4b78c53bbf0298db0f532a42d46f7d))
|
||||
* rename autorepeat-by-default patch to always-autorepeat ([3606015](https://github.com/Canny1913/revanced-patches/commit/3606015d715f150cc51fbb29adf3be252b96faab))
|
||||
* stop using manually entered index ([ed0520d](https://github.com/Canny1913/revanced-patches/commit/ed0520d85c74729d7daabbfbd6cb77ad8cd62f15))
|
||||
* update patches to `17.26.35` ([#142](https://github.com/Canny1913/revanced-patches/issues/142)) ([b04112c](https://github.com/Canny1913/revanced-patches/commit/b04112c8562a7b95e7555e894b665913094b33eb))
|
||||
* use dependency in correct patch ([a2a1ee8](https://github.com/Canny1913/revanced-patches/commit/a2a1ee8eb5e059b30fe58c918a80976ef4d7b637))
|
||||
* wording [skip ci] ([ba64d9e](https://github.com/Canny1913/revanced-patches/commit/ba64d9efc3ee606e9bda30ad7f8017af34b1dc3f))
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* `compact-header` patch ([83753ba](https://github.com/Canny1913/revanced-patches/commit/83753bacf8f56ad16f8abafc02034f1595c12532))
|
||||
* `default-video-quality` patch ([9d30d37](https://github.com/Canny1913/revanced-patches/commit/9d30d372dd13663564286820f3e7685c0a0cee8a))
|
||||
* `force-vp9-codec` patch ([#157](https://github.com/Canny1913/revanced-patches/issues/157)) ([07806a1](https://github.com/Canny1913/revanced-patches/commit/07806a16e5368118949e0e476e901987433ad403))
|
||||
* `hide-get-premium` patch ([#195](https://github.com/Canny1913/revanced-patches/issues/195)) ([639aab4](https://github.com/Canny1913/revanced-patches/commit/639aab411ee514b50840c15c8e9a1a889854403f))
|
||||
* `minimize-playback-music` patch ([#200](https://github.com/Canny1913/revanced-patches/issues/200)) ([d4fd18b](https://github.com/Canny1913/revanced-patches/commit/d4fd18bc74c92e17cdfb21b627b2f6a8919ff2dc))
|
||||
* `music-video-ads` patch ([#172](https://github.com/Canny1913/revanced-patches/issues/172)) ([cbb71b5](https://github.com/Canny1913/revanced-patches/commit/cbb71b5faf1386ed31dd9e0387f6cf0509d92d31))
|
||||
* `return-youtube-dislikes` patch ([#175](https://github.com/Canny1913/revanced-patches/issues/175)) ([18a66d8](https://github.com/Canny1913/revanced-patches/commit/18a66d8454cf6e7cfdd4183631a6870c80d16b90))
|
||||
* `sponsorblock` patch ([#101](https://github.com/Canny1913/revanced-patches/issues/101)) ([36af4cc](https://github.com/Canny1913/revanced-patches/commit/36af4cc14ff8057c10b99019cb23acc6e5aec3f2)), closes [#89](https://github.com/Canny1913/revanced-patches/issues/89) [#90](https://github.com/Canny1913/revanced-patches/issues/90)
|
||||
* `swipe-controls` rewrite ([#131](https://github.com/Canny1913/revanced-patches/issues/131)) ([b7dba09](https://github.com/Canny1913/revanced-patches/commit/b7dba09927ba15a9eacb06dcb4bf1f268560c96e))
|
||||
* 1 line of code ([e2d28bd](https://github.com/Canny1913/revanced-patches/commit/e2d28bd576f74f1792dc959b8ed3064ec6a4cb68))
|
||||
* add version 17.26.35 ([25cd66c](https://github.com/Canny1913/revanced-patches/commit/25cd66cc6d2cd56a4170c5c69a708011fe7eab1d))
|
||||
* complete `default-video-quality` patch ([f7e153b](https://github.com/Canny1913/revanced-patches/commit/f7e153bd08b6dfe07591678195bfa6b06606f6a2))
|
||||
* issue templates ([b82b0aa](https://github.com/Canny1913/revanced-patches/commit/b82b0aad88b7ab9d86f1bcc8e007f6a76a9aa1a5))
|
||||
* twitter `timeline-ads` patch ([#222](https://github.com/Canny1913/revanced-patches/issues/222)) ([f16e67f](https://github.com/Canny1913/revanced-patches/commit/f16e67fc75c9c3505ff875a216ce7e868022075e))
|
||||
|
||||
## [2.21.3](https://github.com/revanced/revanced-patches/compare/v2.21.2...v2.21.3) (2022-07-24)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* rename autorepeat-by-default patch to always-autorepeat ([3606015](https://github.com/revanced/revanced-patches/commit/3606015d715f150cc51fbb29adf3be252b96faab))
|
||||
|
||||
## [2.21.2](https://github.com/revanced/revanced-patches/compare/v2.21.1...v2.21.2) (2022-07-23)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* bump youtube version to 17.28.34 ([#225](https://github.com/revanced/revanced-patches/issues/225)) ([738cb6a](https://github.com/revanced/revanced-patches/commit/738cb6af177e92bbff8c02d6808fe416c0ad2582))
|
||||
|
||||
## [2.21.1](https://github.com/revanced/revanced-patches/compare/v2.21.0...v2.21.1) (2022-07-23)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* add v17.28.34 compatiblity for the `hide-shorts-button` patch ([#224](https://github.com/revanced/revanced-patches/issues/224)) ([76166bb](https://github.com/revanced/revanced-patches/commit/76166bb35f940ef661e2802f5bf93ed91f2e2913))
|
||||
|
||||
# [2.21.0](https://github.com/revanced/revanced-patches/compare/v2.20.5...v2.21.0) (2022-07-23)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* twitter `timeline-ads` patch ([#222](https://github.com/revanced/revanced-patches/issues/222)) ([f16e67f](https://github.com/revanced/revanced-patches/commit/f16e67fc75c9c3505ff875a216ce7e868022075e))
|
||||
|
||||
## [2.20.5](https://github.com/revanced/revanced-patches/compare/v2.20.4...v2.20.5) (2022-07-22)
|
||||
|
||||
|
||||
|
||||
@@ -1,9 +1,7 @@
|
||||
# ReVanced Patches
|
||||
# 🧩 ReVanced Patches
|
||||
|
||||
🧩 Official patches by ReVanced
|
||||
Official patches by ReVanced
|
||||
|
||||
# List of available patches
|
||||
## 📜 List of available patches
|
||||
|
||||
| 💊 Patch | 📜 Description | 🎯 Target Package | 🏹 Target Version |
|
||||
|:--------:|:--------------:|:-----------------:|:-----------------:|
|
||||
{{ table }}
|
||||
|
||||
110
README.md
110
README.md
@@ -1,43 +1,75 @@
|
||||
# ReVanced Patches
|
||||
# 🧩 ReVanced Patches
|
||||
|
||||
🧩 Official patches by ReVanced
|
||||
Official patches by ReVanced
|
||||
|
||||
# List of available patches
|
||||
## 📜 List of available patches
|
||||
|
||||
### 📦 `com.twitter.android`
|
||||
<details>
|
||||
|
||||
| 💊 Patch | 📜 Description | 🏹 Target Version |
|
||||
|:--------:|:--------------:|:-----------------:|
|
||||
| `timeline-ads` | Removes ads from the Twitter timeline. | all |
|
||||
</details>
|
||||
|
||||
### 📦 `com.reddit.frontpage`
|
||||
<details>
|
||||
|
||||
| 💊 Patch | 📜 Description | 🏹 Target Version |
|
||||
|:--------:|:--------------:|:-----------------:|
|
||||
| `general-reddit-ads` | Removes general ads from the Reddit frontpage and subreddits. | all |
|
||||
</details>
|
||||
|
||||
### 📦 `com.google.android.apps.youtube.music`
|
||||
<details>
|
||||
|
||||
| 💊 Patch | 📜 Description | 🏹 Target Version |
|
||||
|:--------:|:--------------:|:-----------------:|
|
||||
| `minimized-playback-music` | Enables minimized playback on Kids music. | 5.16.51 |
|
||||
| `tasteBuilder-remover` | Removes the "Tell us which artists you like" card from the home screen. | 5.16.51 |
|
||||
| `hide-get-premium` | Removes all "Get Premium" evidences from the avatar menu. | 5.16.51 |
|
||||
| `compact-header` | Hides the music category bar at the top of the homepage. | 5.16.51 |
|
||||
| `upgrade-button-remover` | Removes the upgrade tab from the pivot bar. | 5.16.51 |
|
||||
| `background-play` | Enables playing music in the background. | 5.16.51 |
|
||||
| `music-microg-support` | Allows YouTube Music ReVanced to run without root and under a different package name. | 5.16.51 |
|
||||
| `music-video-ads` | Removes ads in the music player. | 5.16.51 |
|
||||
| `codecs-unlock` | Adds more audio codec options. The new audio codecs usually result in better audio quality. | 5.16.51 |
|
||||
| `exclusive-audio-playback` | Enables the option to play music without video. | 5.16.51 |
|
||||
</details>
|
||||
|
||||
### 📦 `com.google.android.youtube`
|
||||
<details>
|
||||
|
||||
| 💊 Patch | 📜 Description | 🏹 Target Version |
|
||||
|:--------:|:--------------:|:-----------------:|
|
||||
| `swipe-controls` | Adds volume and brightness swipe controls. | 17.29.34 |
|
||||
| `seekbar-tapping` | Enables tap-to-seek on the seekbar of the video player. | 17.29.34 |
|
||||
| `minimized-playback` | Enables minimized and background playback. | 17.29.34 |
|
||||
| `amoled` | Enables pure black theme. | 17.29.34 |
|
||||
| `disable-create-button` | Hides the create button in the navigation bar. | 17.29.34 |
|
||||
| `hide-cast-button` | Hides the cast button in the video player. | all |
|
||||
| `return-youtube-dislike` | Shows the dislike count of videos using the Return YouTube Dislike API. | 17.29.34 |
|
||||
| `hide-autoplay-button` | Hides the autoplay button in the video player. | 17.29.34 |
|
||||
| `premium-heading` | Shows premium branding on the home screen. | all |
|
||||
| `custom-branding` | Changes the YouTube launcher icon to be ReVanced's. | all |
|
||||
| `disable-fullscreen-panels` | Disables video description and comments panel in fullscreen view. | 17.29.34 |
|
||||
| `old-quality-layout` | Enables the original quality flyout menu. | 17.29.34 |
|
||||
| `hide-shorts-button` | Hides the shorts button on the navigation bar. | 17.29.34 |
|
||||
| `hide-watermark` | Hides creator's watermarks on videos. | 17.29.34 |
|
||||
| `sponsorblock` | Integrate SponsorBlock. | 17.29.34 |
|
||||
| `enable-wide-searchbar` | Replaces the search icon with a wide search bar. This will hide the YouTube logo when active. | 17.29.34 |
|
||||
| `force-vp9-codec` | Forces the VP9 codec for videos. | 17.29.34 |
|
||||
| `custom-video-buffer` | Lets you change the buffers of videos. Has no use without settings yet. | 17.29.34 |
|
||||
| `always-autorepeat` | Always repeats the playing video again. | 17.29.34 |
|
||||
| `microg-support` | Allows YouTube ReVanced to run without root and under a different package name with Vanced MicroG | 17.29.34 |
|
||||
| `settings` | Adds settings for ReVanced to YouTube. | all |
|
||||
| `enable-debugging` | Enables app debugging by patching the manifest file. | all |
|
||||
| `custom-playback-speed` | Adds more video playback speed options. | 17.29.34 |
|
||||
| `hdr-auto-brightness` | Makes the brightness of HDR videos follow the system default. | 17.29.34 |
|
||||
| `remember-video-quality` | Adds the ability to remember the video quality you chose in the video quality flyout. | 17.29.34 |
|
||||
| `video-ads` | Removes ads in the video player. | 17.29.34 |
|
||||
| `general-ads` | Removes general ads. | 17.29.34 |
|
||||
| `hide-infocard-suggestions` | Hides infocards in videos. | 17.29.34 |
|
||||
</details>
|
||||
|
||||
| 💊 Patch | 📜 Description | 🎯 Target Package | 🏹 Target Version |
|
||||
|:--------:|:--------------:|:-----------------:|:-----------------:|
|
||||
| `minimized-playback-music` | Enables minimized playback on Kids music. | `com.google.android.apps.youtube.music` | 5.14.53 |
|
||||
| `tasteBuilder-remover` | Removes the "Tell us which artists you like" card from the home screen. | `com.google.android.apps.youtube.music` | 5.14.53 |
|
||||
| `hide-get-premium` | Removes all "Get Premium" evidences from the avatar menu. | `com.google.android.apps.youtube.music` | 5.14.53 |
|
||||
| `compact-header` | Hides the music category bar at the top of the homepage. | `com.google.android.apps.youtube.music` | 5.14.53 |
|
||||
| `upgrade-button-remover` | Removes the upgrade tab from the pivot bar. | `com.google.android.apps.youtube.music` | 5.14.53 |
|
||||
| `background-play` | Enables playing music in the background. | `com.google.android.apps.youtube.music` | 5.14.53 |
|
||||
| `music-video-ads` | Removes ads in the music player. | `com.google.android.apps.youtube.music` | 5.14.53 |
|
||||
| `codecs-unlock` | Adds more audio codec options. The new audio codecs usually result in better audio quality. | `com.google.android.apps.youtube.music` | 5.14.53 |
|
||||
| `exclusive-audio-playback` | Enables the option to play music without video. | `com.google.android.apps.youtube.music` | 5.14.53 |
|
||||
| `swipe-controls` | Adds volume and brightness swipe controls. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `seekbar-tapping` | Enables tap-to-seek on the seekbar of the video player. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `minimized-playback` | Enables minimized and background playback. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `amoled` | Enables pure black theme. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `disable-create-button` | Hides the create button in the navigation bar. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `hide-cast-button` | Hides the cast button in the video player. | `com.google.android.youtube` | all |
|
||||
| `return-youtube-dislike` | Shows the dislike count of videos using the Return YouTube Dislike API. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `hide-autoplay-button` | Hides the autoplay button in the video player. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `premium-heading` | Shows premium branding on the home screen. | `com.google.android.youtube` | all |
|
||||
| `custom-branding` | Changes the YouTube launcher icon to be ReVanced's. | `com.google.android.youtube` | all |
|
||||
| `disable-fullscreen-panels` | Disables video description and comments panel in fullscreen view. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `old-quality-layout` | Enables the original quality flyout menu. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `hide-shorts-button` | Hides the shorts button on the navigation bar. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `hide-watermark` | Hides creator's watermarks on videos. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `sponsorblock` | Integrate SponsorBlock. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `enable-wide-searchbar` | Replaces the search icon with a wide search bar. This will hide the YouTube logo when active. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `force-vp9-codec` | Forces the VP9 codec for videos. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `autorepeat-by-default` | Enables auto repeating of videos by default. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `microg-support` | Allows YouTube ReVanced to run without root and under a different package name with Vanced MicroG | `com.google.android.youtube` | 17.27.39 |
|
||||
| `enable-debugging` | Enables app debugging by patching the manifest file. | `com.google.android.youtube` | all |
|
||||
| `custom-playback-speed` | Adds more video playback speed options. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `hdr-auto-brightness` | Makes the brightness of HDR videos follow the system default. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `video-ads` | Removes ads in the video player. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `general-ads` | Removes general ads. | `com.google.android.youtube` | 17.27.39 |
|
||||
| `hide-infocard-suggestions` | Hides infocards in videos. | `com.google.android.youtube` | 17.27.39 |
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@ repositories {
|
||||
dependencies {
|
||||
implementation(kotlin("stdlib"))
|
||||
|
||||
implementation("app.revanced:revanced-patcher:2.4.0")
|
||||
implementation("app.revanced:revanced-patcher:2.9.0")
|
||||
implementation("app.revanced:multidexlib2:2.5.2.r2")
|
||||
}
|
||||
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
kotlin.code.style = official
|
||||
version = 2.20.5
|
||||
version = 2.28.2
|
||||
|
||||
@@ -14,7 +14,6 @@ import org.jf.dexlib2.builder.instruction.BuilderInstruction21t
|
||||
import org.jf.dexlib2.builder.instruction.BuilderInstruction35c
|
||||
import org.jf.dexlib2.immutable.reference.ImmutableMethodReference
|
||||
import org.w3c.dom.Node
|
||||
import java.io.OutputStream
|
||||
import java.nio.file.Files
|
||||
|
||||
// TODO: this method does not make sense here
|
||||
@@ -146,7 +145,7 @@ fun ResourceData.injectStrings(
|
||||
// open source strings.xml
|
||||
val sourceInputStream = classLoader.getResourceAsStream("$patchDirectoryPath/$relativePath")
|
||||
?: throw PatchResultError("failed to open '$patchDirectoryPath/$relativePath'")
|
||||
xmlEditor[sourceInputStream, OutputStream.nullOutputStream()].use { sourceStringsXml ->
|
||||
xmlEditor[sourceInputStream].use { sourceStringsXml ->
|
||||
val strings = sourceStringsXml.file.getElementsByTagName("resources").item(0).childNodes
|
||||
|
||||
// open target strings.xml
|
||||
|
||||
11
src/main/kotlin/app/revanced/meta/readme/Extensions.kt
Normal file
11
src/main/kotlin/app/revanced/meta/readme/Extensions.kt
Normal file
@@ -0,0 +1,11 @@
|
||||
package app.revanced.meta.readme
|
||||
|
||||
import app.revanced.patcher.data.Data
|
||||
import app.revanced.patcher.extensions.PatchExtensions.compatiblePackages
|
||||
import app.revanced.patcher.patch.Patch
|
||||
|
||||
internal fun Class<out Patch<Data>>.getLatestVersion(): SemanticVersion? =
|
||||
this.compatiblePackages?.first()?.versions?.map { SemanticVersion.fromString(it) }
|
||||
?.maxWithOrNull(
|
||||
SemanticVersionComparator
|
||||
)
|
||||
@@ -1,41 +1,55 @@
|
||||
package app.revanced.meta.readme
|
||||
|
||||
import app.revanced.patcher.data.Data
|
||||
import app.revanced.patcher.extensions.PatchExtensions.compatiblePackages
|
||||
import app.revanced.patcher.extensions.PatchExtensions.description
|
||||
import app.revanced.patcher.extensions.PatchExtensions.patchName
|
||||
import app.revanced.patcher.patch.Patch
|
||||
import app.revanced.patcher.util.patch.implementation.JarPatchBundle
|
||||
import java.io.File
|
||||
|
||||
class Generator {
|
||||
companion object {
|
||||
@JvmStatic
|
||||
fun main(args: Array<String>) {
|
||||
val buildDir = File("build/libs/")
|
||||
val buildJar =
|
||||
buildDir.listFiles()?.first { it.name.startsWith("revanced-patches-") && it.name.endsWith(".jar") }!!
|
||||
object Generator {
|
||||
private const val TABLE_HEADER =
|
||||
"| \uD83D\uDC8A Patch | \uD83D\uDCDC Description | \uD83C\uDFF9 Target Version |\n" +
|
||||
"|:--------:|:--------------:|:-----------------:|"
|
||||
|
||||
val bundle = JarPatchBundle(buildJar.absolutePath).loadPatches()
|
||||
@JvmStatic
|
||||
fun main(args: Array<String>) {
|
||||
val buildDir = File("build/libs/")
|
||||
val buildJar =
|
||||
buildDir.listFiles()?.first { it.name.startsWith("revanced-patches-") && it.name.endsWith(".jar") }!!
|
||||
|
||||
val patches = StringBuilder()
|
||||
val bundle = JarPatchBundle(buildJar.absolutePath).loadPatches()
|
||||
|
||||
for (patch in bundle) {
|
||||
val patchName = patch.patchName
|
||||
val compatiblePackage = patch.compatiblePackages?.first()
|
||||
val latestVersion =
|
||||
compatiblePackage?.versions?.map { SemanticVersion.fromString(it) }?.maxWithOrNull(
|
||||
SemanticVersionComparator
|
||||
) ?: "all"
|
||||
val output = StringBuilder()
|
||||
|
||||
patches.appendLine("| `$patchName` | ${patch.description} | `${compatiblePackage?.name}` | $latestVersion |")
|
||||
val packages = mutableMapOf<String, MutableList<Class<out Patch<Data>>>>()
|
||||
|
||||
bundle.map {
|
||||
val packageName = it.compatiblePackages?.first()?.name!!
|
||||
if (!packages.contains(packageName)) {
|
||||
packages[packageName] = mutableListOf()
|
||||
}
|
||||
|
||||
val readMeTemplateFile = File("README-template.md")
|
||||
val readmeTemplate = Template(readMeTemplateFile.readText())
|
||||
|
||||
readmeTemplate.replaceVariable("table", patches.toString())
|
||||
|
||||
val readme = File("README.md")
|
||||
readme.writeText(readmeTemplate.toString())
|
||||
packages[packageName]?.add(it)
|
||||
}
|
||||
|
||||
for (pkg in packages) {
|
||||
output.appendLine("### \uD83D\uDCE6 `${pkg.key}`")
|
||||
output.appendLine("<details>\n")
|
||||
|
||||
output.appendLine(TABLE_HEADER)
|
||||
pkg.value.forEach { output.appendLine("| `${it.patchName}` | ${it.description} | ${it.getLatestVersion() ?: "all"} |") }
|
||||
|
||||
output.appendLine("</details>\n")
|
||||
}
|
||||
|
||||
val readMeTemplateFile = File("README-template.md")
|
||||
val readmeTemplate = Template(readMeTemplateFile.readText())
|
||||
|
||||
readmeTemplate.replaceVariable("table", output.toString())
|
||||
|
||||
val readme = File("README.md")
|
||||
readme.writeText(readmeTemplate.toString())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53")
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53", "5.16.51")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53")
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53", "5.16.51")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53")
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53", "5.16.51")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53")
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53", "5.16.51")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53")
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53", "5.16.51")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53")
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53", "5.16.51")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53")
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53", "5.16.51")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53")
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53", "5.16.51")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
package app.revanced.patches.music.misc.microg.annotations
|
||||
|
||||
import app.revanced.patcher.annotation.Compatibility
|
||||
import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53", "5.16.51")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
@Retention(AnnotationRetention.RUNTIME)
|
||||
internal annotation class MusicMicroGPatchCompatibility
|
||||
@@ -0,0 +1,21 @@
|
||||
package app.revanced.patches.music.misc.microg.fingerprints
|
||||
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patcher.fingerprint.method.annotation.DirectPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patches.music.misc.microg.annotations.MusicMicroGPatchCompatibility
|
||||
import org.jf.dexlib2.AccessFlags
|
||||
|
||||
@Name("google-play-utility-fingerprint")
|
||||
@MatchingMethod(
|
||||
"Lnuv;", "b"
|
||||
)
|
||||
@DirectPatternScanMethod
|
||||
@MusicMicroGPatchCompatibility
|
||||
@Version("0.0.1")
|
||||
object GooglePlayUtilityFingerprint : MethodFingerprint(
|
||||
"I", AccessFlags.PUBLIC or AccessFlags.STATIC, listOf("L", "I"), null, listOf("This should never happen.", "MetadataValueReader", "GooglePlayServicesUtil", "com.android.vending", "android.hardware.type.embedded")
|
||||
)
|
||||
@@ -0,0 +1,19 @@
|
||||
package app.revanced.patches.music.misc.microg.fingerprints
|
||||
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patcher.fingerprint.method.annotation.DirectPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patches.music.misc.microg.annotations.MusicMicroGPatchCompatibility
|
||||
|
||||
@Name("google-play-prime-fingerprint")
|
||||
@MatchingMethod(
|
||||
"Lrwi;", "a"
|
||||
)
|
||||
@DirectPatternScanMethod
|
||||
@MusicMicroGPatchCompatibility
|
||||
@Version("0.0.1")
|
||||
object PrimeFingerprint : MethodFingerprint(
|
||||
null, null, null, null, listOf("com.google.android.GoogleCamera", "com.android.vending")
|
||||
)
|
||||
@@ -0,0 +1,21 @@
|
||||
package app.revanced.patches.music.misc.microg.fingerprints
|
||||
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patcher.fingerprint.method.annotation.FuzzyPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patches.music.misc.microg.annotations.MusicMicroGPatchCompatibility
|
||||
import org.jf.dexlib2.AccessFlags
|
||||
|
||||
@Name("google-play-service-checker-fingerprint")
|
||||
@MatchingMethod(
|
||||
"Lnuv;", "d"
|
||||
)
|
||||
@FuzzyPatternScanMethod(2) // FIXME: Test this threshold and find the best value.
|
||||
@MusicMicroGPatchCompatibility
|
||||
@Version("0.0.1")
|
||||
object ServiceCheckFingerprint : MethodFingerprint(
|
||||
"V", AccessFlags.PUBLIC or AccessFlags.STATIC, listOf("L", "I"), null, listOf("Google Play Services not available")
|
||||
)
|
||||
@@ -0,0 +1,160 @@
|
||||
package app.revanced.patches.music.misc.microg.patch.bytecode
|
||||
|
||||
import app.revanced.extensions.equalsAny
|
||||
import app.revanced.patcher.annotation.Description
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.data.impl.BytecodeData
|
||||
import app.revanced.patcher.extensions.addInstructions
|
||||
import app.revanced.patcher.extensions.replaceInstruction
|
||||
import app.revanced.patcher.patch.annotations.Dependencies
|
||||
import app.revanced.patcher.patch.annotations.Patch
|
||||
import app.revanced.patcher.patch.impl.BytecodePatch
|
||||
import app.revanced.patcher.patch.PatchResult
|
||||
import app.revanced.patcher.patch.PatchResultSuccess
|
||||
import app.revanced.patcher.util.proxy.mutableTypes.MutableClass
|
||||
import app.revanced.patches.music.misc.microg.annotations.MusicMicroGPatchCompatibility
|
||||
import app.revanced.patches.music.misc.microg.patch.resource.MusicMicroGResourcePatch
|
||||
import app.revanced.patches.youtube.misc.microg.patch.resource.enum.StringReplaceMode
|
||||
import app.revanced.patches.music.misc.microg.shared.Constants.BASE_MICROG_PACKAGE_NAME
|
||||
import app.revanced.patches.music.misc.microg.shared.Constants.REVANCED_MUSIC_PACKAGE_NAME
|
||||
import app.revanced.patches.music.misc.microg.fingerprints.*
|
||||
import org.jf.dexlib2.Opcode
|
||||
import org.jf.dexlib2.builder.MutableMethodImplementation
|
||||
import org.jf.dexlib2.builder.instruction.BuilderInstruction21c
|
||||
import org.jf.dexlib2.iface.instruction.formats.Instruction21c
|
||||
import org.jf.dexlib2.iface.reference.StringReference
|
||||
import org.jf.dexlib2.immutable.reference.ImmutableStringReference
|
||||
|
||||
@Patch
|
||||
@Dependencies([MusicMicroGResourcePatch::class])
|
||||
@Name("music-microg-support")
|
||||
@Description("Allows YouTube Music ReVanced to run without root and under a different package name.")
|
||||
@MusicMicroGPatchCompatibility
|
||||
@Version("0.0.1")
|
||||
class MusicMicroGBytecodePatch : BytecodePatch(
|
||||
listOf(
|
||||
ServiceCheckFingerprint,
|
||||
GooglePlayUtilityFingerprint,
|
||||
PrimeFingerprint,
|
||||
)
|
||||
) {
|
||||
override fun execute(data: BytecodeData): PatchResult {
|
||||
disablePlayServiceChecks()
|
||||
data.classes.forEach { classDef ->
|
||||
var proxiedClass: MutableClass? = null
|
||||
|
||||
classDef.methods.forEach methodLoop@{ method ->
|
||||
val implementation = method.implementation ?: return@methodLoop
|
||||
|
||||
var proxiedImplementation: MutableMethodImplementation? = null
|
||||
|
||||
implementation.instructions.forEachIndexed { i, instruction ->
|
||||
if (instruction.opcode != Opcode.CONST_STRING) return@forEachIndexed
|
||||
|
||||
val stringValue = ((instruction as Instruction21c).reference as StringReference).string
|
||||
|
||||
val replaceMode = if (stringValue.equalsAny(
|
||||
"com.google.android.gms",
|
||||
"com.google.android.gms.chimera",
|
||||
"com.google.android.c2dm.intent.REGISTER",
|
||||
"com.google.android.c2dm.permission.SEND",
|
||||
"com.google.iid.TOKEN_REQUEST",
|
||||
"com.google",
|
||||
"com.google.android.gms.chimera.GmsIntentOperationService",
|
||||
"com.google.android.gms.phenotype.internal.IPhenotypeCallbacks",
|
||||
"com.google.android.gms.phenotype.internal.IPhenotypeService",
|
||||
"com.google.android.gms.phenotype.service.START",
|
||||
"com.google.android.gms.phenotype.PACKAGE_NAME",
|
||||
"com.google.android.gms.phenotype.UPDATE",
|
||||
"com.google.android.gms.phenotype",
|
||||
"com.google.android.gms.auth.accounts",
|
||||
"com.google.android.c2dm.intent.REGISTRATION",
|
||||
"com.google.android.gsf.action.GET_GLS",
|
||||
"com.google.android.gsf.login",
|
||||
"content://com.google.settings/partner",
|
||||
"content://com.google.android.gms.phenotype/",
|
||||
"content://com.google.android.gsf.gservices",
|
||||
"content://com.google.android.gsf.gservices/prefix",
|
||||
"com.google.android.c2dm.intent.RECEIVE"
|
||||
)
|
||||
) {
|
||||
StringReplaceMode.REPLACE_WITH_MICROG
|
||||
} else if (stringValue.equalsAny(
|
||||
"com.google.android.apps.youtube.music.SuggestionsProvider", "com.google.android.apps.youtube.music.fileprovider"
|
||||
)
|
||||
) {
|
||||
StringReplaceMode.REPLACE_WITH_REVANCED
|
||||
} else {
|
||||
StringReplaceMode.DO_NOT_REPLACE
|
||||
}
|
||||
|
||||
if (replaceMode != StringReplaceMode.DO_NOT_REPLACE) {
|
||||
if (proxiedClass == null) {
|
||||
proxiedClass = data.proxy(classDef).resolve()
|
||||
}
|
||||
|
||||
if (proxiedImplementation == null) {
|
||||
proxiedImplementation = proxiedClass!!.methods.first {
|
||||
it.name == method.name && it.parameterTypes.containsAll(method.parameterTypes)
|
||||
}.implementation!!
|
||||
}
|
||||
|
||||
val newString = if (replaceMode == StringReplaceMode.REPLACE_WITH_REVANCED) stringValue.replace(
|
||||
"com.google.android.apps.youtube.music", REVANCED_MUSIC_PACKAGE_NAME
|
||||
)
|
||||
else stringValue.replace("com.google", BASE_MICROG_PACKAGE_NAME)
|
||||
|
||||
proxiedImplementation!!.replaceInstruction(
|
||||
i, BuilderInstruction21c(
|
||||
Opcode.CONST_STRING, instruction.registerA, ImmutableStringReference(newString)
|
||||
)
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return PatchResultSuccess()
|
||||
}
|
||||
|
||||
private fun disablePlayServiceChecks() {
|
||||
listOf(
|
||||
ServiceCheckFingerprint,
|
||||
GooglePlayUtilityFingerprint,
|
||||
).forEach { fingerprint ->
|
||||
val result = fingerprint.result!!
|
||||
val stringInstructions = when (result.method.returnType.first()) {
|
||||
'V' -> "return-void"
|
||||
'I' -> """
|
||||
const/4 v0, 0x0
|
||||
return v0
|
||||
"""
|
||||
|
||||
else -> throw Exception("This case should never happen.")
|
||||
}
|
||||
result.mutableMethod.addInstructions(
|
||||
0, stringInstructions
|
||||
)
|
||||
}
|
||||
|
||||
val primeMethod = PrimeFingerprint.result!!.mutableMethod
|
||||
val implementation = primeMethod.implementation!!
|
||||
|
||||
var register = 2
|
||||
val index = implementation.instructions.indexOfFirst {
|
||||
if (it.opcode != Opcode.CONST_STRING) return@indexOfFirst false
|
||||
|
||||
val instructionString = ((it as Instruction21c).reference as StringReference).string
|
||||
if (instructionString != "com.google.android.apps.youtube.music") return@indexOfFirst false
|
||||
|
||||
register = it.registerA
|
||||
return@indexOfFirst true
|
||||
}
|
||||
|
||||
primeMethod.replaceInstruction(
|
||||
index, "const-string v$register, \"$REVANCED_MUSIC_PACKAGE_NAME\""
|
||||
)
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
package app.revanced.patches.music.misc.microg.patch.resource
|
||||
|
||||
import app.revanced.patcher.annotation.Description
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.data.impl.ResourceData
|
||||
import app.revanced.patcher.patch.PatchResult
|
||||
import app.revanced.patcher.patch.PatchResultSuccess
|
||||
import app.revanced.patcher.patch.impl.ResourcePatch
|
||||
import app.revanced.patches.music.misc.microg.annotations.MusicMicroGPatchCompatibility
|
||||
import app.revanced.patches.music.misc.microg.shared.Constants.BASE_MICROG_PACKAGE_NAME
|
||||
import app.revanced.patches.music.misc.microg.shared.Constants.REVANCED_MUSIC_APP_NAME
|
||||
import app.revanced.patches.music.misc.microg.shared.Constants.REVANCED_MUSIC_PACKAGE_NAME
|
||||
|
||||
@Name("music-microg-resource-patch")
|
||||
@Description("Resource patch to allow YouTube Music ReVanced to run without root and under a different package name.")
|
||||
@MusicMicroGPatchCompatibility
|
||||
@Version("0.0.1")
|
||||
class MusicMicroGResourcePatch : ResourcePatch() {
|
||||
override fun execute(data: ResourceData): PatchResult {
|
||||
|
||||
val manifest = data["AndroidManifest.xml"].readText()
|
||||
|
||||
data["AndroidManifest.xml"].writeText(
|
||||
manifest.replace(
|
||||
"package=\"com.google.android.apps.youtube.music", "package=\"$REVANCED_MUSIC_PACKAGE_NAME"
|
||||
).replace(
|
||||
"android:label=\"@string/app_name", "android:label=\"$REVANCED_MUSIC_APP_NAME"
|
||||
).replace(
|
||||
"android:label=\"@string/app_launcher_name", "android:label=\"$REVANCED_MUSIC_APP_NAME"
|
||||
).replace(
|
||||
"android:authorities=\"com.google.android.apps.youtube.music", "android:authorities=\"$REVANCED_MUSIC_PACKAGE_NAME"
|
||||
).replace(
|
||||
"com.google.android.apps.youtube.music.permission.C2D_MESSAGE", "$REVANCED_MUSIC_PACKAGE_NAME.permission.C2D_MESSAGE"
|
||||
).replace(
|
||||
"com.google.android.c2dm", "$BASE_MICROG_PACKAGE_NAME.android.c2dm"
|
||||
).replace(
|
||||
"</queries>", "<package android:name=\"$BASE_MICROG_PACKAGE_NAME.android.gms\"/></queries>"
|
||||
)
|
||||
)
|
||||
|
||||
return PatchResultSuccess()
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
package app.revanced.patches.music.misc.microg.shared
|
||||
|
||||
object Constants {
|
||||
internal const val BASE_MICROG_PACKAGE_NAME = "com.mgoogle"
|
||||
internal const val REVANCED_MUSIC_APP_NAME = "YouTube Music ReVanced"
|
||||
internal const val REVANCED_MUSIC_PACKAGE_NAME = "app.revanced.android.apps.youtube.music"
|
||||
}
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53")
|
||||
"com.google.android.apps.youtube.music", arrayOf("5.14.53", "5.16.51")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
package app.revanced.patches.reddit.ad.general.annotations
|
||||
|
||||
import app.revanced.patcher.annotation.Compatibility
|
||||
import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.reddit.frontpage", arrayOf()
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
@Retention(AnnotationRetention.RUNTIME)
|
||||
internal annotation class GeneralAdsCompatibility
|
||||
@@ -0,0 +1,55 @@
|
||||
package app.revanced.patches.reddit.ad.general.patch
|
||||
|
||||
import app.revanced.patcher.annotation.Description
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.data.impl.BytecodeData
|
||||
import app.revanced.patcher.extensions.replaceInstruction
|
||||
import app.revanced.patcher.patch.annotations.Patch
|
||||
import app.revanced.patcher.patch.impl.BytecodePatch
|
||||
import app.revanced.patcher.patch.PatchResult
|
||||
import app.revanced.patcher.patch.PatchResultSuccess
|
||||
import app.revanced.patches.reddit.ad.general.annotations.GeneralAdsCompatibility
|
||||
import org.jf.dexlib2.Opcode
|
||||
import org.jf.dexlib2.builder.instruction.BuilderInstruction21c
|
||||
import org.jf.dexlib2.iface.instruction.ReferenceInstruction
|
||||
import org.jf.dexlib2.iface.reference.StringReference
|
||||
import org.jf.dexlib2.immutable.reference.ImmutableStringReference
|
||||
|
||||
@Patch
|
||||
@Name("general-reddit-ads")
|
||||
@Description("Removes general ads from the Reddit frontpage and subreddits.")
|
||||
@GeneralAdsCompatibility
|
||||
@Version("0.0.1")
|
||||
class GeneralAdsPatch : BytecodePatch() {
|
||||
override fun execute(data: BytecodeData): PatchResult {
|
||||
data.classes.forEach { classDef ->
|
||||
classDef.methods.forEach methodLoop@{ method ->
|
||||
val implementation = method.implementation ?: return@methodLoop
|
||||
|
||||
implementation.instructions.forEachIndexed { i, instruction ->
|
||||
if (instruction.opcode != Opcode.CONST_STRING) return@forEachIndexed
|
||||
if (((instruction as ReferenceInstruction).reference as StringReference).string != "AdPost") return@forEachIndexed
|
||||
|
||||
val proxiedClass = data.proxy(classDef).resolve()
|
||||
|
||||
val proxiedImplementation = proxiedClass.methods.first {
|
||||
it.name == method.name && it.parameterTypes.containsAll(method.parameterTypes)
|
||||
}.implementation!!
|
||||
|
||||
var newString = "AdPost1"
|
||||
if (proxiedImplementation.instructions[i - 1].opcode == Opcode.CONST_STRING) {
|
||||
newString = "SubredditPost"
|
||||
}
|
||||
proxiedImplementation.replaceInstruction(
|
||||
i, BuilderInstruction21c(
|
||||
Opcode.CONST_STRING, (proxiedImplementation.instructions[i] as BuilderInstruction21c).registerA, ImmutableStringReference(newString)
|
||||
)
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return PatchResultSuccess()
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
package app.revanced.patches.twitter.ad.timeline.annotations
|
||||
|
||||
import app.revanced.patcher.annotation.Compatibility
|
||||
import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.twitter.android", arrayOf()
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
@Retention(AnnotationRetention.RUNTIME)
|
||||
internal annotation class TimelineAdsCompatibility
|
||||
@@ -0,0 +1,26 @@
|
||||
package app.revanced.patches.twitter.ad.timeline.fingerprints
|
||||
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patches.twitter.ad.timeline.annotations.TimelineAdsCompatibility
|
||||
import org.jf.dexlib2.Opcode
|
||||
|
||||
@Name("timeline-tweet-json-parser-fingerprint")
|
||||
@MatchingMethod("LJsonTimelineTweet\$\$JsonObjectMapper;", "parseField")
|
||||
@TimelineAdsCompatibility
|
||||
@Version("0.0.1")
|
||||
object TimelineTweetJsonParserFingerprint : MethodFingerprint(
|
||||
null, null, null, listOf(
|
||||
Opcode.IPUT_OBJECT,
|
||||
Opcode.GOTO,
|
||||
Opcode.SGET_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CHECK_CAST,
|
||||
Opcode.IPUT_OBJECT,
|
||||
Opcode.RETURN_VOID,
|
||||
), listOf("tweetPromotedMetadata", "promotedMetadata", "hasModeratedReplies", "conversationAnnotation"),
|
||||
{ methodDef -> methodDef.name == "parseField" }
|
||||
)
|
||||
@@ -0,0 +1,77 @@
|
||||
package app.revanced.patches.twitter.ad.timeline.patch
|
||||
|
||||
import app.revanced.patcher.annotation.Description
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.data.impl.BytecodeData
|
||||
import app.revanced.patcher.extensions.addInstructions
|
||||
import app.revanced.patcher.extensions.instruction
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprintResult
|
||||
import app.revanced.patcher.patch.PatchResult
|
||||
import app.revanced.patcher.patch.PatchResultError
|
||||
import app.revanced.patcher.patch.PatchResultSuccess
|
||||
import app.revanced.patcher.patch.annotations.Patch
|
||||
import app.revanced.patcher.patch.impl.BytecodePatch
|
||||
import app.revanced.patcher.util.proxy.mutableTypes.MutableMethod
|
||||
import app.revanced.patches.twitter.ad.timeline.annotations.TimelineAdsCompatibility
|
||||
import app.revanced.patches.twitter.ad.timeline.fingerprints.TimelineTweetJsonParserFingerprint
|
||||
import org.jf.dexlib2.Opcode
|
||||
import org.jf.dexlib2.builder.BuilderInstruction
|
||||
import org.jf.dexlib2.builder.instruction.BuilderInstruction22c
|
||||
import org.jf.dexlib2.iface.instruction.ReferenceInstruction
|
||||
import org.jf.dexlib2.iface.reference.FieldReference
|
||||
import org.jf.dexlib2.iface.reference.StringReference
|
||||
|
||||
@Patch
|
||||
@Name("timeline-ads")
|
||||
@Description("Removes ads from the Twitter timeline.")
|
||||
@TimelineAdsCompatibility
|
||||
@Version("0.0.1")
|
||||
class TimelineAdsPatch : BytecodePatch(
|
||||
listOf(TimelineTweetJsonParserFingerprint)
|
||||
) {
|
||||
override fun execute(data: BytecodeData): PatchResult {
|
||||
if (removePromotedAds())
|
||||
return PatchResultError("The instruction for the tweet id field could not be found")
|
||||
|
||||
return PatchResultSuccess()
|
||||
}
|
||||
|
||||
private fun removePromotedAds(): Boolean {
|
||||
val (parserFingerprintResult, parserMethod, instructions) = TimelineTweetJsonParserFingerprint.unwrap()
|
||||
|
||||
// Anchor index
|
||||
val tweetIdFieldInstructionIndex = instructions.indexOfFirst { instruction ->
|
||||
if (instruction.opcode.ordinal != Opcode.CONST_STRING.ordinal) return@indexOfFirst false
|
||||
if (((instruction as? ReferenceInstruction)?.reference as StringReference).string != "tweetSocialProof") return@indexOfFirst false
|
||||
|
||||
// Use the above conditions as an anchor to find the index for the instruction with the field we need
|
||||
return@indexOfFirst true
|
||||
} - 2 // This is where the instruction with the field is located
|
||||
|
||||
// Reference to the tweetId field for of the timeline tweet
|
||||
val tweetIdFieldReference =
|
||||
(parserMethod.instruction(tweetIdFieldInstructionIndex) as? BuilderInstruction22c)?.reference as? FieldReference
|
||||
?: return true
|
||||
|
||||
// Set the tweetId field to null
|
||||
// This will cause twitter to not show the promoted ads, because we set it to null, when the tweet is promoted
|
||||
parserFingerprintResult.mutableMethod.addInstructions(
|
||||
parserFingerprintResult.patternScanResult!!.startIndex + 1,
|
||||
"""
|
||||
const/4 v2, 0x0
|
||||
iput-object v2, p0, Lcom/twitter/model/json/timeline/urt/JsonTimelineTweet;->${tweetIdFieldReference.name}:Ljava/lang/String;
|
||||
"""
|
||||
)
|
||||
return false
|
||||
}
|
||||
|
||||
private fun MethodFingerprint.unwrap(): Triple<MethodFingerprintResult, MutableMethod, MutableList<BuilderInstruction>> {
|
||||
val parserFingerprintResult = this.result!!
|
||||
val parserMethod = parserFingerprintResult.mutableMethod
|
||||
val instructions = parserMethod.implementation!!.instructions
|
||||
|
||||
return Triple(parserFingerprintResult, parserMethod, instructions)
|
||||
}
|
||||
}
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.24.34", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.24.34", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -17,7 +17,7 @@ import app.revanced.patches.youtube.misc.integrations.patch.IntegrationsPatch
|
||||
import app.revanced.patches.youtube.misc.playeroverlay.patch.PlayerOverlaysHookPatch
|
||||
import app.revanced.patches.youtube.misc.playertype.patch.PlayerTypeHookPatch
|
||||
|
||||
@Patch(include = false)
|
||||
@Patch
|
||||
@Name("swipe-controls")
|
||||
@Description("Adds volume and brightness swipe controls.")
|
||||
@SwipeControlsCompatibility
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -3,7 +3,6 @@ package app.revanced.patches.youtube.layout.shorts.button.fingerprints
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.method.annotation.FuzzyPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patches.youtube.layout.shorts.button.annotations.ShortsButtonCompatibility
|
||||
@@ -14,7 +13,6 @@ import org.jf.dexlib2.Opcode
|
||||
@MatchingMethod(
|
||||
"Lknw;", "z"
|
||||
)
|
||||
@FuzzyPatternScanMethod(2) // FIXME: Test this threshold and find the best value.
|
||||
@ShortsButtonCompatibility
|
||||
@Version("0.0.1")
|
||||
object PivotBarButtonsViewFingerprint : MethodFingerprint(
|
||||
@@ -22,28 +20,19 @@ object PivotBarButtonsViewFingerprint : MethodFingerprint(
|
||||
AccessFlags.PUBLIC or AccessFlags.FINAL,
|
||||
listOf("Z"),
|
||||
listOf(
|
||||
Opcode.NEW_INSTANCE, // new StateListDrawable()
|
||||
Opcode.INVOKE_DIRECT,
|
||||
Opcode.NEW_ARRAY,
|
||||
Opcode.CONST,
|
||||
Opcode.CONST_16,
|
||||
Opcode.APUT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.INVOKE_VIRTUAL_RANGE,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.GOTO,
|
||||
Opcode.IGET_OBJECT,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.SGET_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.IGET,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_OBJECT,
|
||||
Opcode.MOVE_OBJECT,
|
||||
Opcode.MOVE,
|
||||
Opcode.MOVE_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL_RANGE, // pivotBar.getView(drawable, tabName, z, i, map, akebVar, optional)
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.SGET_OBJECT,
|
||||
Opcode.INVOKE_INTERFACE,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.IGET
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -35,7 +35,7 @@ class ShortsButtonRemoverPatch : BytecodePatch(
|
||||
|
||||
val buttonsViewResult = PivotBarButtonsViewFingerprint.result!!
|
||||
val buttonsViewImplementation = buttonsViewResult.mutableMethod.implementation!!
|
||||
val moveViewInstruction = buttonsViewImplementation.instructions[buttonsViewResult.patternScanResult!!.endIndex]
|
||||
val moveViewInstruction = buttonsViewImplementation.instructions[buttonsViewResult.patternScanResult!!.startIndex + 1]
|
||||
val viewRegister = (moveViewInstruction as OneRegisterInstruction).registerA
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@ class ShortsButtonRemoverPatch : BytecodePatch(
|
||||
// Hide the button view via proxy by passing it to the hideShortsButton method
|
||||
// It only hides it if the last tab name is "TAB_SHORTS"
|
||||
buttonsViewResult.mutableMethod.addInstruction(
|
||||
buttonsViewResult.patternScanResult!!.endIndex + 2,
|
||||
buttonsViewResult.patternScanResult!!.startIndex + 3,
|
||||
"invoke-static { v$viewRegister }, Lapp/revanced/integrations/patches/HideShortsButtonPatch;->hideShortsButton(Landroid/view/View;)V"
|
||||
)
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.22.36", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.22.36", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -2,7 +2,6 @@ package app.revanced.patches.youtube.layout.sponsorblock.resource.patch
|
||||
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.data.impl.DomFileEditor
|
||||
import app.revanced.patcher.data.impl.ResourceData
|
||||
import app.revanced.patcher.patch.PatchResult
|
||||
import app.revanced.patcher.patch.PatchResultSuccess
|
||||
@@ -10,7 +9,7 @@ import app.revanced.patcher.patch.annotations.Dependencies
|
||||
import app.revanced.patcher.patch.impl.ResourcePatch
|
||||
import app.revanced.patches.youtube.layout.sponsorblock.annotations.SponsorBlockCompatibility
|
||||
import app.revanced.patches.youtube.misc.manifest.patch.FixLocaleConfigErrorPatch
|
||||
import java.io.OutputStream
|
||||
import app.revanced.util.resources.ResourceUtils.copyXmlNode
|
||||
import java.nio.file.Files
|
||||
|
||||
@Name("sponsorblock-resource-patch")
|
||||
@@ -29,7 +28,7 @@ class SponsorBlockResourcePatch : ResourcePatch() {
|
||||
|
||||
// copy nodes from the resources node to the real resource node
|
||||
"resources".copyXmlNode(
|
||||
data.xmlEditor[stringsResourceInputStream, OutputStream.nullOutputStream()],
|
||||
data.xmlEditor[stringsResourceInputStream],
|
||||
data.xmlEditor["res/$stringsResourcePath"]
|
||||
).close() // close afterwards
|
||||
|
||||
@@ -78,7 +77,7 @@ class SponsorBlockResourcePatch : ResourcePatch() {
|
||||
|
||||
val targetXmlEditor = data.xmlEditor["res/$path/$resource.xml"]
|
||||
"RelativeLayout".copyXmlNode(
|
||||
data.xmlEditor[hostingResourceStream, OutputStream.nullOutputStream()],
|
||||
data.xmlEditor[hostingResourceStream],
|
||||
targetXmlEditor
|
||||
).also {
|
||||
val children = targetXmlEditor.file.getElementsByTagName("RelativeLayout").item(0).childNodes
|
||||
@@ -102,27 +101,4 @@ class SponsorBlockResourcePatch : ResourcePatch() {
|
||||
}
|
||||
return PatchResultSuccess()
|
||||
}
|
||||
|
||||
/**
|
||||
* Copies the specified node of the source [DomFileEditor] to the target [DomFileEditor].
|
||||
* @param source the source [DomFileEditor].
|
||||
* @param target the target [DomFileEditor]-
|
||||
*/
|
||||
private fun String.copyXmlNode(source: DomFileEditor, target: DomFileEditor): AutoCloseable {
|
||||
val hostNodes = source.file.getElementsByTagName(this).item(0).childNodes
|
||||
|
||||
val destinationResourceFile = target.file
|
||||
val destinationNode = destinationResourceFile.getElementsByTagName(this).item(0)
|
||||
|
||||
for (index in 0 until hostNodes.length) {
|
||||
val node = hostNodes.item(index).cloneNode(true)
|
||||
destinationResourceFile.adoptNode(node)
|
||||
destinationNode.appendChild(node)
|
||||
}
|
||||
|
||||
return AutoCloseable {
|
||||
source.close()
|
||||
target.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -20,7 +20,7 @@ import app.revanced.patches.youtube.layout.widesearchbar.fingerprints.WideSearch
|
||||
import app.revanced.patches.youtube.layout.widesearchbar.fingerprints.WideSearchbarTwoParentFingerprint
|
||||
import app.revanced.patches.youtube.misc.integrations.patch.IntegrationsPatch
|
||||
|
||||
@Patch(include = false)
|
||||
@Patch
|
||||
@Dependencies([IntegrationsPatch::class])
|
||||
@Name("enable-wide-searchbar")
|
||||
@Description("Replaces the search icon with a wide search bar. This will hide the YouTube logo when active.")
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -18,10 +18,10 @@ import app.revanced.patches.youtube.misc.autorepeat.fingerprints.AutoRepeatFinge
|
||||
import app.revanced.patches.youtube.misc.autorepeat.fingerprints.AutoRepeatParentFingerprint
|
||||
import app.revanced.patches.youtube.misc.integrations.patch.IntegrationsPatch
|
||||
|
||||
@Patch(include = false)
|
||||
@Patch
|
||||
@Dependencies([IntegrationsPatch::class])
|
||||
@Name("autorepeat-by-default")
|
||||
@Description("Enables auto repeating of videos by default.")
|
||||
@Name("always-autorepeat")
|
||||
@Description("Always repeats the playing video again.")
|
||||
@AutoRepeatCompatibility
|
||||
@Version("0.0.1")
|
||||
class AutoRepeatPatch : BytecodePatch(
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.24.34", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.24.34", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -1,14 +1,13 @@
|
||||
package app.revanced.patches.youtube.misc.forcevp9.annotations;
|
||||
package app.revanced.patches.youtube.misc.forcevp9.annotations
|
||||
|
||||
import app.revanced.patcher.annotation.Compatibility
|
||||
import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
@Retention(AnnotationRetention.RUNTIME)
|
||||
internal annotation class ForceVP9Compatibility {
|
||||
}
|
||||
internal annotation class ForceVP9Compatibility
|
||||
|
||||
@@ -22,7 +22,7 @@ import org.jf.dexlib2.iface.instruction.OneRegisterInstruction
|
||||
import org.jf.dexlib2.iface.instruction.ReferenceInstruction
|
||||
import org.jf.dexlib2.iface.reference.FieldReference
|
||||
|
||||
@Patch(include = false)
|
||||
@Patch
|
||||
@Dependencies([IntegrationsPatch::class])
|
||||
@Name("force-vp9-codec")
|
||||
@Description("Forces the VP9 codec for videos.")
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -18,7 +18,7 @@ import org.jf.dexlib2.iface.instruction.ReferenceInstruction
|
||||
import org.jf.dexlib2.iface.instruction.TwoRegisterInstruction
|
||||
import org.jf.dexlib2.iface.reference.FieldReference
|
||||
|
||||
@Patch(false)
|
||||
@Patch
|
||||
@Name("hdr-auto-brightness")
|
||||
@Description("Makes the brightness of HDR videos follow the system default.")
|
||||
@HDRBrightnessCompatibility
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.03.38", "17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.03.38", "17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -3,237 +3,19 @@ package app.revanced.patches.youtube.misc.microg.fingerprints
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patcher.fingerprint.method.annotation.FuzzyPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patches.youtube.misc.microg.annotations.MicroGPatchCompatibility
|
||||
import org.jf.dexlib2.AccessFlags
|
||||
import org.jf.dexlib2.Opcode
|
||||
|
||||
@Name("google-play-utility-fingerprint")
|
||||
@MatchingMethod(
|
||||
"Llss;", "b"
|
||||
"Lmco;", "b"
|
||||
)
|
||||
@FuzzyPatternScanMethod(2) // FIXME: Test this threshold and find the best value.
|
||||
@MicroGPatchCompatibility
|
||||
@Version("0.0.1")
|
||||
object GooglePlayUtilityFingerprint : MethodFingerprint(
|
||||
"I", AccessFlags.PUBLIC or AccessFlags.STATIC, listOf("L", "L"), listOf(
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CONST,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.GOTO,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.CONST_4,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.SGET_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.IF_EQZ,
|
||||
Opcode.GOTO,
|
||||
Opcode.SGET_OBJECT,
|
||||
Opcode.MONITOR_ENTER,
|
||||
Opcode.SGET_BOOLEAN,
|
||||
Opcode.IF_EQZ,
|
||||
Opcode.MONITOR_EXIT,
|
||||
Opcode.GOTO,
|
||||
Opcode.SPUT_BOOLEAN,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CONST_16,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.IGET_OBJECT,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.MONITOR_EXIT,
|
||||
Opcode.GOTO,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.SPUT,
|
||||
Opcode.GOTO,
|
||||
Opcode.MOVE_EXCEPTION,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MONITOR_EXIT,
|
||||
Opcode.SGET,
|
||||
Opcode.IF_EQZ,
|
||||
Opcode.CONST,
|
||||
Opcode.IF_NE,
|
||||
Opcode.GOTO,
|
||||
Opcode.NEW_INSTANCE,
|
||||
Opcode.INVOKE_DIRECT,
|
||||
Opcode.THROW,
|
||||
Opcode.NEW_INSTANCE,
|
||||
Opcode.INVOKE_DIRECT,
|
||||
Opcode.THROW,
|
||||
Opcode.MOVE_EXCEPTION,
|
||||
Opcode.MONITOR_EXIT,
|
||||
Opcode.THROW,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.CONST_4,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.SGET_OBJECT,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.IF_EQZ,
|
||||
Opcode.GOTO,
|
||||
Opcode.CONST_4,
|
||||
Opcode.GOTO,
|
||||
Opcode.CONST_4,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.SPUT_OBJECT,
|
||||
Opcode.SGET_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.CONST_4,
|
||||
Opcode.GOTO,
|
||||
Opcode.CONST_4,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CONST_16,
|
||||
Opcode.IF_EQZ,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.CONST_16,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.GOTO,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.CONST_16,
|
||||
Opcode.GOTO_16,
|
||||
Opcode.CONST_4,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.CONST_16,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.GOTO,
|
||||
Opcode.IF_EQZ,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.GOTO,
|
||||
Opcode.IF_EQZ,
|
||||
Opcode.IF_EQZ,
|
||||
Opcode.IGET_OBJECT,
|
||||
Opcode.AGET_OBJECT,
|
||||
Opcode.IGET_OBJECT,
|
||||
Opcode.AGET_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.GOTO,
|
||||
Opcode.IGET,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.IF_GE,
|
||||
Opcode.IGET,
|
||||
Opcode.NEW_INSTANCE,
|
||||
Opcode.INVOKE_DIRECT,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.CONST_4,
|
||||
Opcode.GOTO,
|
||||
Opcode.IGET_OBJECT,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.GOTO,
|
||||
Opcode.MOVE_EXCEPTION,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.GOTO,
|
||||
Opcode.IGET_BOOLEAN,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.CONST_4,
|
||||
Opcode.GOTO,
|
||||
Opcode.RETURN,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.RETURN
|
||||
), listOf("This should never happen.", "MetadataValueReader", "com.google.android.gms")
|
||||
"I", AccessFlags.PUBLIC or AccessFlags.STATIC, listOf("L", "L"), null, listOf("This should never happen.", "MetadataValueReader", "com.google.android.gms")
|
||||
)
|
||||
@@ -3,80 +3,19 @@ package app.revanced.patches.youtube.misc.microg.fingerprints
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patcher.fingerprint.method.annotation.FuzzyPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patches.youtube.misc.microg.annotations.MicroGPatchCompatibility
|
||||
import org.jf.dexlib2.AccessFlags
|
||||
import org.jf.dexlib2.Opcode
|
||||
|
||||
@Name("google-play-sig-check-fingerprint")
|
||||
@MatchingMethod(
|
||||
"Ldwn;", "d"
|
||||
"Leae;", "d"
|
||||
)
|
||||
@FuzzyPatternScanMethod(2) // FIXME: Test this threshold and find the best value.
|
||||
@MicroGPatchCompatibility
|
||||
@Version("0.0.1")
|
||||
object IntegrityCheckFingerprint : MethodFingerprint(
|
||||
"L", AccessFlags.PUBLIC or AccessFlags.STATIC, listOf("L", "L"), listOf(
|
||||
Opcode.MOVE_OBJECT_FROM16,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.NEW_INSTANCE,
|
||||
Opcode.MOVE_OBJECT_FROM16,
|
||||
Opcode.INVOKE_DIRECT,
|
||||
Opcode.CONST_4,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.IF_EQ,
|
||||
Opcode.IGET_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.SGET,
|
||||
Opcode.IGET_OBJECT,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT_WIDE,
|
||||
Opcode.CONST_WIDE,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.CONST_4,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.CONST_4,
|
||||
Opcode.CMP_LONG,
|
||||
Opcode.IF_GEZ,
|
||||
Opcode.CONST_16,
|
||||
Opcode.GOTO_16,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.IGET_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CONST_16,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.GOTO,
|
||||
Opcode.MOVE_EXCEPTION,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.CONST_4,
|
||||
Opcode.IGET_OBJECT,
|
||||
Opcode.IF_EQZ,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.CONST,
|
||||
Opcode.IF_NE,
|
||||
Opcode.CONST_16,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.SGET_OBJECT,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.GOTO,
|
||||
Opcode.NEW_ARRAY
|
||||
), listOf("This should never happen.", "GooglePlayServicesUtil", "Google Play Store signature invalid.")
|
||||
"L", AccessFlags.PUBLIC or AccessFlags.STATIC, listOf("L", "L"), null, listOf("This should never happen.", "GooglePlayServicesUtil", "Google Play Store signature invalid.")
|
||||
)
|
||||
@@ -3,47 +3,20 @@ package app.revanced.patches.youtube.misc.microg.fingerprints
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patcher.fingerprint.method.annotation.FuzzyPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patches.youtube.misc.microg.annotations.MicroGPatchCompatibility
|
||||
import org.jf.dexlib2.AccessFlags
|
||||
import org.jf.dexlib2.Opcode
|
||||
|
||||
@Name("google-play-service-checker-fingerprint")
|
||||
@MatchingMethod(
|
||||
"Llss;", "d"
|
||||
"Lmco;", "d"
|
||||
)
|
||||
@FuzzyPatternScanMethod(2) // FIXME: Test this threshold and find the best value.
|
||||
@MicroGPatchCompatibility
|
||||
@Version("0.0.1")
|
||||
object ServiceCheckFingerprint : MethodFingerprint(
|
||||
"V", AccessFlags.PUBLIC or AccessFlags.STATIC, listOf("L", "I"), listOf(
|
||||
Opcode.SGET_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT,
|
||||
Opcode.IF_EQZ,
|
||||
Opcode.SGET_OBJECT,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.NEW_INSTANCE,
|
||||
Opcode.INVOKE_DIRECT,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_STATIC,
|
||||
Opcode.IF_NEZ,
|
||||
Opcode.NEW_INSTANCE,
|
||||
Opcode.INVOKE_DIRECT,
|
||||
Opcode.THROW,
|
||||
Opcode.NEW_INSTANCE,
|
||||
Opcode.CONST_STRING,
|
||||
Opcode.INVOKE_DIRECT,
|
||||
Opcode.THROW,
|
||||
Opcode.RETURN_VOID
|
||||
), listOf("Google Play Services not available")
|
||||
"V", AccessFlags.PUBLIC or AccessFlags.STATIC, listOf("L", "I"), null
|
||||
, listOf("Google Play Services not available", "GooglePlayServices not available due to error ")
|
||||
)
|
||||
@@ -13,9 +13,10 @@ import app.revanced.patches.youtube.misc.microg.annotations.MicroGPatchCompatibi
|
||||
import app.revanced.patches.youtube.misc.microg.shared.Constants.BASE_MICROG_PACKAGE_NAME
|
||||
import app.revanced.patches.youtube.misc.microg.shared.Constants.REVANCED_APP_NAME
|
||||
import app.revanced.patches.youtube.misc.microg.shared.Constants.REVANCED_PACKAGE_NAME
|
||||
import app.revanced.patches.youtube.misc.settings.resource.patch.SettingsResourcePatch
|
||||
|
||||
@Name("microg-resource-patch")
|
||||
@Dependencies([FixLocaleConfigErrorPatch::class])
|
||||
@Dependencies([FixLocaleConfigErrorPatch::class, SettingsResourcePatch::class])
|
||||
@Description("Resource patch to allow YouTube ReVanced to run without root and under a different package name.")
|
||||
@MicroGPatchCompatibility
|
||||
@Version("0.0.1")
|
||||
@@ -27,12 +28,18 @@ class MicroGResourcePatch : ResourcePatch() {
|
||||
settingsElementIntent.setAttribute("android:targetClass", "org.microg.gms.ui.SettingsActivity")
|
||||
|
||||
val settingsElement = it.file.createElement("Preference")
|
||||
settingsElement.setAttribute("android:title", "MicroG")
|
||||
settingsElement.setAttribute("android:title", "@string/microg_settings")
|
||||
settingsElement.appendChild(settingsElementIntent)
|
||||
|
||||
it.file.firstChild.appendChild(settingsElement)
|
||||
}
|
||||
|
||||
val settings_fragment = data.get("res/xml/settings_fragment.xml")
|
||||
val text = settings_fragment.readText()
|
||||
settings_fragment.writeText(
|
||||
text.replace("android:targetPackage=\"com.google.android.youtube", "android:targetPackage=\"$REVANCED_PACKAGE_NAME")
|
||||
)
|
||||
|
||||
val manifest = data.get("AndroidManifest.xml").readText()
|
||||
|
||||
data.get("AndroidManifest.xml").writeText(
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.24.34", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.24.34", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.24.34", "17.25.34", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.24.34", "17.25.34", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
package app.revanced.patches.youtube.misc.quality.annotations
|
||||
|
||||
import app.revanced.patcher.annotation.Compatibility
|
||||
import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.22.36", "17.24.35", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
@Retention(AnnotationRetention.RUNTIME)
|
||||
internal annotation class DefaultVideoQualityCompatibility
|
||||
@@ -0,0 +1,21 @@
|
||||
package app.revanced.patches.youtube.misc.quality.fingerprints
|
||||
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patcher.fingerprint.method.annotation.DirectPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patches.youtube.misc.quality.annotations.DefaultVideoQualityCompatibility
|
||||
import org.jf.dexlib2.Opcode
|
||||
import org.jf.dexlib2.AccessFlags
|
||||
@Name("video-quality-reference-fingerprint")
|
||||
@MatchingMethod("Lkec;", "b")
|
||||
@DirectPatternScanMethod
|
||||
@DefaultVideoQualityCompatibility
|
||||
@Version("0.0.1")
|
||||
object VideoQualityReferenceFingerprint : MethodFingerprint(
|
||||
"V", AccessFlags.PUBLIC or AccessFlags.FINAL, listOf("L"), listOf(
|
||||
Opcode.IPUT_OBJECT, Opcode.RETURN_VOID
|
||||
)
|
||||
)
|
||||
@@ -0,0 +1,32 @@
|
||||
|
||||
package app.revanced.patches.youtube.misc.quality.fingerprints
|
||||
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.method.annotation.DirectPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patches.youtube.misc.quality.annotations.DefaultVideoQualityCompatibility
|
||||
import org.jf.dexlib2.AccessFlags
|
||||
import org.jf.dexlib2.Opcode
|
||||
|
||||
@Name("video-quality-setter-fingerprint")
|
||||
@MatchingMethod(
|
||||
"Lkec;", "a"
|
||||
)
|
||||
@DirectPatternScanMethod
|
||||
@DefaultVideoQualityCompatibility
|
||||
@Version("0.0.1")
|
||||
object VideoQualitySetterFingerprint : MethodFingerprint(
|
||||
"V",
|
||||
AccessFlags.PUBLIC or AccessFlags.FINAL,
|
||||
listOf("[L", "I", "I", "Z", "I"),
|
||||
listOf(
|
||||
Opcode.IF_EQZ,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.MOVE_RESULT_OBJECT,
|
||||
Opcode.INVOKE_VIRTUAL,
|
||||
Opcode.IPUT_BOOLEAN,
|
||||
)
|
||||
)
|
||||
@@ -0,0 +1,29 @@
|
||||
|
||||
package app.revanced.patches.youtube.misc.quality.fingerprints
|
||||
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patcher.fingerprint.method.annotation.DirectPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patches.youtube.misc.quality.annotations.DefaultVideoQualityCompatibility
|
||||
import org.jf.dexlib2.AccessFlags
|
||||
import org.jf.dexlib2.Opcode
|
||||
|
||||
@Name("video-user-quality-change-fingerprint")
|
||||
@MatchingMethod("Lkec;", "onItemClick")
|
||||
@DirectPatternScanMethod
|
||||
@DefaultVideoQualityCompatibility
|
||||
@Version("0.0.1")
|
||||
object VideoUserQualityChangeFingerprint : MethodFingerprint(
|
||||
"V",
|
||||
AccessFlags.PUBLIC or AccessFlags.FINAL,
|
||||
listOf("L","L","I","J"),
|
||||
listOf(
|
||||
Opcode.MOVE,
|
||||
Opcode.MOVE_WIDE,
|
||||
Opcode.INVOKE_INTERFACE_RANGE,
|
||||
Opcode.RETURN_VOID
|
||||
)
|
||||
)
|
||||
@@ -0,0 +1,69 @@
|
||||
package app.revanced.patches.youtube.misc.quality.patch
|
||||
|
||||
import app.revanced.patcher.annotation.Description
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.data.impl.BytecodeData
|
||||
import app.revanced.patcher.extensions.addInstruction
|
||||
import app.revanced.patcher.extensions.addInstructions
|
||||
import app.revanced.patcher.fingerprint.method.utils.MethodFingerprintUtils.resolve
|
||||
import app.revanced.patcher.patch.PatchResult
|
||||
import app.revanced.patcher.patch.PatchResultSuccess
|
||||
import app.revanced.patcher.patch.annotations.Dependencies
|
||||
import app.revanced.patcher.patch.annotations.Patch
|
||||
import app.revanced.patcher.patch.impl.BytecodePatch
|
||||
import app.revanced.patches.youtube.misc.integrations.patch.IntegrationsPatch
|
||||
import app.revanced.patches.youtube.misc.quality.annotations.DefaultVideoQualityCompatibility
|
||||
import app.revanced.patches.youtube.misc.quality.fingerprints.VideoQualityReferenceFingerprint
|
||||
import app.revanced.patches.youtube.misc.quality.fingerprints.VideoQualitySetterFingerprint
|
||||
import app.revanced.patches.youtube.misc.quality.fingerprints.VideoUserQualityChangeFingerprint
|
||||
import app.revanced.patches.youtube.misc.videoid.patch.VideoIdPatch
|
||||
import org.jf.dexlib2.iface.instruction.ReferenceInstruction
|
||||
import org.jf.dexlib2.iface.reference.FieldReference
|
||||
|
||||
@Patch
|
||||
@Dependencies([IntegrationsPatch::class, VideoIdPatch::class])
|
||||
@Name("remember-video-quality")
|
||||
@Description("Adds the ability to remember the video quality you chose in the video quality flyout.")
|
||||
@DefaultVideoQualityCompatibility
|
||||
@Version("0.0.1")
|
||||
class RememberVideoQualityPatch : BytecodePatch(
|
||||
listOf(
|
||||
VideoQualitySetterFingerprint
|
||||
)
|
||||
) {
|
||||
override fun execute(data: BytecodeData): PatchResult {
|
||||
val setterMethod = VideoQualitySetterFingerprint.result!!
|
||||
|
||||
VideoUserQualityChangeFingerprint.resolve(data, setterMethod.classDef)
|
||||
val userQualityMethod = VideoUserQualityChangeFingerprint.result!!
|
||||
|
||||
VideoQualityReferenceFingerprint.resolve(data, setterMethod.classDef)
|
||||
val qualityFieldReference =
|
||||
VideoQualityReferenceFingerprint.result!!.method.let { method ->
|
||||
(method.implementation!!.instructions.elementAt(0) as ReferenceInstruction).reference as FieldReference
|
||||
}
|
||||
|
||||
VideoIdPatch.injectCall("Lapp/revanced/integrations/patches/VideoQualityPatch;->newVideoStarted(Ljava/lang/String;)V")
|
||||
|
||||
val qIndexMethodName =
|
||||
data.classes.single { it.type == qualityFieldReference.type }.methods.single { it.parameterTypes.first() == "I" }.name
|
||||
|
||||
setterMethod.mutableMethod.addInstructions(
|
||||
0,
|
||||
"""
|
||||
iget-object v0, p0, ${setterMethod.classDef.type}->${qualityFieldReference.name}:${qualityFieldReference.type}
|
||||
const-string v1, "$qIndexMethodName"
|
||||
invoke-static {p1, p2, v0, v1}, Lapp/revanced/integrations/patches/VideoQualityPatch;->setVideoQuality([Ljava/lang/Object;ILjava/lang/Object;Ljava/lang/String;)I
|
||||
move-result p2
|
||||
""",
|
||||
)
|
||||
|
||||
userQualityMethod.mutableMethod.addInstruction(
|
||||
0,
|
||||
"invoke-static {p3}, Lapp/revanced/integrations/patches/VideoQualityPatch;->userChangedQuality(I)V"
|
||||
)
|
||||
|
||||
return PatchResultSuccess()
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
package app.revanced.patches.youtube.misc.settings.annotations
|
||||
|
||||
import app.revanced.patcher.annotation.Compatibility
|
||||
import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf()
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
@Retention(AnnotationRetention.RUNTIME)
|
||||
internal annotation class SettingsCompatibility
|
||||
@@ -0,0 +1,28 @@
|
||||
package app.revanced.patches.youtube.misc.settings.bytecode.fingerprints
|
||||
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.fingerprint.method.annotation.FuzzyPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patches.youtube.layout.returnyoutubedislike.annotations.ReturnYouTubeDislikeCompatibility
|
||||
|
||||
// TODO: This is more of a class fingerprint than a method fingerprint.
|
||||
// Convert to a class fingerprint whenever possible.
|
||||
@Name("license-activity-fingerprint")
|
||||
@MatchingMethod(
|
||||
"Lcom/google/android/libraries/social/licenses/LicenseActivity;", "onCreate"
|
||||
)
|
||||
@FuzzyPatternScanMethod(2)
|
||||
@ReturnYouTubeDislikeCompatibility
|
||||
@Version("0.0.2")
|
||||
object LicenseActivityFingerprint : MethodFingerprint(
|
||||
null,
|
||||
null,
|
||||
null,
|
||||
null,
|
||||
null,
|
||||
{ methodDef ->
|
||||
methodDef.definingClass.endsWith("LicenseActivity;") && methodDef.name == "onCreate"
|
||||
}
|
||||
)
|
||||
@@ -0,0 +1,28 @@
|
||||
package app.revanced.patches.youtube.misc.settings.bytecode.fingerprints
|
||||
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.fingerprint.method.annotation.FuzzyPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patches.youtube.layout.returnyoutubedislike.annotations.ReturnYouTubeDislikeCompatibility
|
||||
|
||||
// TODO: This is more of a class fingerprint than a method fingerprint.
|
||||
// Convert to a class fingerprint whenever possible.
|
||||
@Name("revanced-settings-activity-fingerprint")
|
||||
@MatchingMethod(
|
||||
"Lapp/revanced/integrations/settingsmenu/ReVancedSettingActivity;", "initializeSettings"
|
||||
)
|
||||
@FuzzyPatternScanMethod(2)
|
||||
@ReturnYouTubeDislikeCompatibility
|
||||
@Version("0.0.2")
|
||||
object ReVancedSettingsActivityFingerprint : MethodFingerprint(
|
||||
null,
|
||||
null,
|
||||
null,
|
||||
null,
|
||||
null,
|
||||
{ methodDef ->
|
||||
methodDef.definingClass.endsWith("ReVancedSettingActivity;") && methodDef.name == "initializeSettings"
|
||||
}
|
||||
)
|
||||
@@ -0,0 +1,56 @@
|
||||
package app.revanced.patches.youtube.misc.settings.bytecode.patch
|
||||
|
||||
import app.revanced.patcher.annotation.Description
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.data.impl.BytecodeData
|
||||
import app.revanced.patcher.extensions.addInstruction
|
||||
import app.revanced.patcher.extensions.addInstructions
|
||||
import app.revanced.patcher.patch.PatchResult
|
||||
import app.revanced.patcher.patch.PatchResultSuccess
|
||||
import app.revanced.patcher.patch.annotations.Dependencies
|
||||
import app.revanced.patcher.patch.annotations.Patch
|
||||
import app.revanced.patcher.patch.impl.BytecodePatch
|
||||
import app.revanced.patches.youtube.misc.integrations.patch.IntegrationsPatch
|
||||
import app.revanced.patches.youtube.misc.settings.annotations.SettingsCompatibility
|
||||
import app.revanced.patches.youtube.misc.settings.bytecode.fingerprints.LicenseActivityFingerprint
|
||||
import app.revanced.patches.youtube.misc.settings.bytecode.fingerprints.ReVancedSettingsActivityFingerprint
|
||||
import app.revanced.patches.youtube.misc.settings.resource.patch.SettingsResourcePatch
|
||||
|
||||
@Patch
|
||||
@Dependencies([IntegrationsPatch::class, SettingsResourcePatch::class])
|
||||
@Name("settings")
|
||||
@Description("Adds settings for ReVanced to YouTube.")
|
||||
@SettingsCompatibility
|
||||
@Version("0.0.1")
|
||||
class SettingsPatch : BytecodePatch(
|
||||
listOf(LicenseActivityFingerprint, ReVancedSettingsActivityFingerprint)
|
||||
) {
|
||||
override fun execute(data: BytecodeData): PatchResult {
|
||||
val licenseActivityResult = LicenseActivityFingerprint.result!!
|
||||
val settingsResult = ReVancedSettingsActivityFingerprint.result!!
|
||||
|
||||
val licenseActivityClass = licenseActivityResult.mutableClass
|
||||
val settingsClass = settingsResult.mutableClass
|
||||
|
||||
val onCreate = licenseActivityResult.mutableMethod
|
||||
val setThemeMethodName = "setTheme"
|
||||
val initializeSettings = settingsResult.mutableMethod
|
||||
|
||||
// First add the setTheme call to the onCreate method to not affect the offsets.
|
||||
onCreate.addInstructions(
|
||||
1,
|
||||
"""
|
||||
invoke-static { p0 }, ${settingsClass.type}->${initializeSettings.name}(${licenseActivityClass.type})V
|
||||
return-void
|
||||
"""
|
||||
)
|
||||
|
||||
// Add the initializeSettings call to the onCreate method.
|
||||
onCreate.addInstruction(
|
||||
0,
|
||||
"invoke-static { p0 }, ${settingsClass.type}->$setThemeMethodName(${licenseActivityClass.type})V"
|
||||
)
|
||||
return PatchResultSuccess()
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,72 @@
|
||||
package app.revanced.patches.youtube.misc.settings.resource.patch
|
||||
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.data.impl.ResourceData
|
||||
import app.revanced.patcher.patch.PatchResult
|
||||
import app.revanced.patcher.patch.PatchResultSuccess
|
||||
import app.revanced.patcher.patch.annotations.Dependencies
|
||||
import app.revanced.patcher.patch.impl.ResourcePatch
|
||||
import app.revanced.patches.youtube.misc.manifest.patch.FixLocaleConfigErrorPatch
|
||||
import app.revanced.patches.youtube.misc.settings.annotations.SettingsCompatibility
|
||||
import app.revanced.util.resources.ResourceUtils
|
||||
import app.revanced.util.resources.ResourceUtils.copyResources
|
||||
import app.revanced.util.resources.ResourceUtils.copyXmlNode
|
||||
import org.w3c.dom.Element
|
||||
|
||||
@Name("settings-resource-patch")
|
||||
@SettingsCompatibility
|
||||
@Dependencies([FixLocaleConfigErrorPatch::class])
|
||||
@Version("0.0.1")
|
||||
class SettingsResourcePatch : ResourcePatch() {
|
||||
override fun execute(data: ResourceData): PatchResult {
|
||||
/*
|
||||
* Copy strings
|
||||
*/
|
||||
|
||||
data.copyXmlNode("settings/host", "values/strings.xml", "resources")
|
||||
|
||||
/*
|
||||
* Copy arrays
|
||||
*/
|
||||
|
||||
data.copyXmlNode("settings/host", "values/arrays.xml", "resources")
|
||||
|
||||
/*
|
||||
* Copy preference fragments
|
||||
*/
|
||||
|
||||
data.copyXmlNode("settings/host", "xml/settings_fragment.xml", "PreferenceScreen")
|
||||
|
||||
/*
|
||||
* Copy layout resources
|
||||
*/
|
||||
arrayOf(
|
||||
ResourceUtils.ResourceGroup(
|
||||
"layout",
|
||||
"xsettings_toolbar.xml",
|
||||
"xsettings_with_toolbar.xml",
|
||||
"xsettings_with_toolbar_layout.xml"
|
||||
),
|
||||
ResourceUtils.ResourceGroup(
|
||||
"xml",
|
||||
"revanced_prefs.xml"
|
||||
)
|
||||
).forEach { resourceGroup ->
|
||||
data.copyResources("settings", resourceGroup)
|
||||
}
|
||||
|
||||
data.xmlEditor["AndroidManifest.xml"].use {
|
||||
val manifestNode = it
|
||||
.file
|
||||
.getElementsByTagName("manifest")
|
||||
.item(0) as Element
|
||||
|
||||
val element = it.file.createElement("uses-permission")
|
||||
element.setAttribute("android:name", "android.permission.SCHEDULE_EXACT_ALARM")
|
||||
manifestNode.appendChild(element)
|
||||
}
|
||||
|
||||
return PatchResultSuccess()
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
package app.revanced.patches.youtube.misc.videobuffer.annotations
|
||||
|
||||
import app.revanced.patcher.annotation.Compatibility
|
||||
import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.25.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
@Retention(AnnotationRetention.RUNTIME)
|
||||
internal annotation class CustomVideoBufferCompatibility
|
||||
@@ -0,0 +1,32 @@
|
||||
package app.revanced.patches.youtube.misc.videobuffer.fingerprints
|
||||
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.method.annotation.DirectPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patches.youtube.misc.videobuffer.annotations.CustomVideoBufferCompatibility
|
||||
import org.jf.dexlib2.AccessFlags
|
||||
import org.jf.dexlib2.Opcode
|
||||
import org.jf.dexlib2.iface.instruction.NarrowLiteralInstruction
|
||||
|
||||
@Name("maxbuffer-fingerprint")
|
||||
@MatchingMethod(
|
||||
"Lcom/google/android/libraries/youtube/innertube/model/media/PlayerConfigModel;", "r"
|
||||
)
|
||||
@DirectPatternScanMethod
|
||||
@CustomVideoBufferCompatibility
|
||||
@Version("0.0.1")
|
||||
object MaxBufferFingerprint : MethodFingerprint(
|
||||
"I", AccessFlags.PUBLIC or AccessFlags.FINAL, listOf(),
|
||||
listOf(Opcode.SGET_OBJECT, Opcode.IGET, Opcode.IF_EQZ, Opcode.RETURN),
|
||||
null,
|
||||
customFingerprint = { methodDef ->
|
||||
methodDef.definingClass.equals("Lcom/google/android/libraries/youtube/innertube/model/media/PlayerConfigModel;")
|
||||
&& methodDef.implementation!!.instructions.any {
|
||||
((it as? NarrowLiteralInstruction)?.narrowLiteral == 120000)
|
||||
&& methodDef.name.equals("r")
|
||||
}
|
||||
}
|
||||
)
|
||||
@@ -0,0 +1,31 @@
|
||||
package app.revanced.patches.youtube.misc.videobuffer.fingerprints
|
||||
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.method.annotation.DirectPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patches.youtube.misc.videobuffer.annotations.CustomVideoBufferCompatibility
|
||||
import org.jf.dexlib2.AccessFlags
|
||||
import org.jf.dexlib2.Opcode
|
||||
import org.jf.dexlib2.iface.instruction.NarrowLiteralInstruction
|
||||
|
||||
@Name("playbackbuffer-fingerprint")
|
||||
@MatchingMethod(
|
||||
"Lcom/google/android/libraries/youtube/innertube/model/media/PlayerConfigModel;", "p"
|
||||
)
|
||||
@DirectPatternScanMethod
|
||||
@CustomVideoBufferCompatibility
|
||||
@Version("0.0.1")
|
||||
object PlaybackBufferFingerprint : MethodFingerprint(
|
||||
"I", AccessFlags.PUBLIC or AccessFlags.FINAL, listOf(),
|
||||
listOf(Opcode.IF_LEZ, Opcode.RETURN),
|
||||
null,
|
||||
customFingerprint = { methodDef ->
|
||||
methodDef.definingClass.equals("Lcom/google/android/libraries/youtube/innertube/model/media/PlayerConfigModel;")
|
||||
&& methodDef.implementation!!.instructions.any {
|
||||
((it as? NarrowLiteralInstruction)?.narrowLiteral == 1600)
|
||||
}
|
||||
}
|
||||
)
|
||||
@@ -0,0 +1,31 @@
|
||||
package app.revanced.patches.youtube.misc.videobuffer.fingerprints
|
||||
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.extensions.or
|
||||
import app.revanced.patcher.fingerprint.method.annotation.DirectPatternScanMethod
|
||||
import app.revanced.patcher.fingerprint.method.annotation.MatchingMethod
|
||||
import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
|
||||
import app.revanced.patches.youtube.misc.videobuffer.annotations.CustomVideoBufferCompatibility
|
||||
import org.jf.dexlib2.AccessFlags
|
||||
import org.jf.dexlib2.Opcode
|
||||
import org.jf.dexlib2.iface.instruction.NarrowLiteralInstruction
|
||||
|
||||
@Name("playbackbuffer-fingerprint")
|
||||
@MatchingMethod(
|
||||
"Lcom/google/android/libraries/youtube/innertube/model/media/PlayerConfigModel;", "t"
|
||||
)
|
||||
@DirectPatternScanMethod
|
||||
@CustomVideoBufferCompatibility
|
||||
@Version("0.0.1")
|
||||
object ReBufferFingerprint : MethodFingerprint(
|
||||
"I", AccessFlags.PUBLIC or AccessFlags.FINAL, listOf(),
|
||||
listOf(Opcode.IF_LEZ, Opcode.RETURN),
|
||||
null,
|
||||
customFingerprint = { methodDef ->
|
||||
methodDef.definingClass.equals("Lcom/google/android/libraries/youtube/innertube/model/media/PlayerConfigModel;")
|
||||
&& methodDef.implementation!!.instructions.any {
|
||||
((it as? NarrowLiteralInstruction)?.narrowLiteral == 5000)
|
||||
}
|
||||
}
|
||||
)
|
||||
@@ -0,0 +1,73 @@
|
||||
package app.revanced.patches.youtube.misc.videobuffer.patch
|
||||
|
||||
import app.revanced.patcher.annotation.Description
|
||||
import app.revanced.patcher.annotation.Name
|
||||
import app.revanced.patcher.annotation.Version
|
||||
import app.revanced.patcher.data.impl.BytecodeData
|
||||
import app.revanced.patcher.extensions.addInstructions
|
||||
import app.revanced.patcher.patch.PatchResult
|
||||
import app.revanced.patcher.patch.PatchResultSuccess
|
||||
import app.revanced.patcher.patch.annotations.Patch
|
||||
import app.revanced.patcher.patch.impl.BytecodePatch
|
||||
import app.revanced.patches.youtube.misc.videobuffer.annotations.CustomVideoBufferCompatibility
|
||||
import app.revanced.patches.youtube.misc.videobuffer.fingerprints.MaxBufferFingerprint
|
||||
import app.revanced.patches.youtube.misc.videobuffer.fingerprints.PlaybackBufferFingerprint
|
||||
import app.revanced.patches.youtube.misc.videobuffer.fingerprints.ReBufferFingerprint
|
||||
import org.jf.dexlib2.iface.instruction.OneRegisterInstruction
|
||||
|
||||
@Patch
|
||||
@Name("custom-video-buffer")
|
||||
@Description("Lets you change the buffers of videos. Has no use without settings yet.")
|
||||
@CustomVideoBufferCompatibility
|
||||
@Version("0.0.1")
|
||||
class CustomVideoBufferPatch : BytecodePatch(
|
||||
listOf(
|
||||
MaxBufferFingerprint, PlaybackBufferFingerprint, ReBufferFingerprint
|
||||
)
|
||||
) {
|
||||
override fun execute(data: BytecodeData): PatchResult {
|
||||
execMaxBuffer(data)
|
||||
execPlaybackBuffer(data)
|
||||
execReBuffer(data)
|
||||
return PatchResultSuccess()
|
||||
}
|
||||
|
||||
private fun execMaxBuffer(data: BytecodeData) {
|
||||
val result = MaxBufferFingerprint.result!!
|
||||
val method = result.mutableMethod
|
||||
val index = result.patternScanResult!!.endIndex - 1
|
||||
val register = (method.implementation!!.instructions.get(index) as OneRegisterInstruction).registerA
|
||||
method.addInstructions(
|
||||
index + 1, """
|
||||
invoke-static {}, Lapp/revanced/integrations/patches/VideoBufferPatch;->getMaxBuffer()I
|
||||
move-result v$register
|
||||
"""
|
||||
)
|
||||
}
|
||||
|
||||
private fun execPlaybackBuffer(data: BytecodeData) {
|
||||
val result = PlaybackBufferFingerprint.result!!
|
||||
val method = result.mutableMethod
|
||||
val index = result.patternScanResult!!.startIndex
|
||||
val register = (method.implementation!!.instructions.get(index) as OneRegisterInstruction).registerA
|
||||
method.addInstructions(
|
||||
index + 1, """
|
||||
invoke-static {}, Lapp/revanced/integrations/patches/VideoBufferPatch;->getPlaybackBuffer()I
|
||||
move-result v$register
|
||||
"""
|
||||
)
|
||||
}
|
||||
|
||||
private fun execReBuffer(data: BytecodeData) {
|
||||
val result = ReBufferFingerprint.result!!
|
||||
val method = result.mutableMethod
|
||||
val index = result.patternScanResult!!.startIndex
|
||||
val register = (method.implementation!!.instructions.get(index) as OneRegisterInstruction).registerA
|
||||
method.addInstructions(
|
||||
index + 1, """
|
||||
invoke-static {}, Lapp/revanced/integrations/patches/VideoBufferPatch;->getReBuffer()I
|
||||
move-result v$register
|
||||
"""
|
||||
)
|
||||
}
|
||||
}
|
||||
@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
|
||||
|
||||
@Compatibility(
|
||||
[Package(
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.22.36", "17.26.35", "17.27.39")
|
||||
"com.google.android.youtube", arrayOf("17.14.35", "17.22.36", "17.26.35", "17.27.39", "17.28.34", "17.29.34")
|
||||
)]
|
||||
)
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
|
||||
@@ -35,15 +35,18 @@ class VideoIdPatch : BytecodePatch(
|
||||
|
||||
injectCall("Lapp/revanced/integrations/videoplayer/VideoInformation;->setCurrentVideoId(Ljava/lang/String;)V")
|
||||
|
||||
offset++ // offset so setCurrentVideoId is called before any injected call
|
||||
|
||||
return PatchResultSuccess()
|
||||
}
|
||||
|
||||
companion object {
|
||||
private lateinit var result: MethodFingerprintResult
|
||||
private var videoIdRegister: Int = 0
|
||||
private lateinit var insertMethod: MutableMethod
|
||||
private var offset = 2
|
||||
|
||||
private var videoIdRegister: Int = 0
|
||||
private lateinit var result: MethodFingerprintResult
|
||||
private lateinit var insertMethod: MutableMethod
|
||||
|
||||
/**
|
||||
* Adds an invoke-static instruction, called with the new id when the video changes
|
||||
* @param methodDescriptor which method to call. Params have to be `Ljava/lang/String;`
|
||||
@@ -52,10 +55,9 @@ class VideoIdPatch : BytecodePatch(
|
||||
methodDescriptor: String
|
||||
) {
|
||||
insertMethod.addInstructions(
|
||||
result.patternScanResult!!.endIndex + offset, // after the move-result-object
|
||||
result.patternScanResult!!.endIndex + offset, // move-result-object offset
|
||||
"invoke-static {v$videoIdRegister}, $methodDescriptor"
|
||||
)
|
||||
offset++ // so additional instructions get added later
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
74
src/main/kotlin/app/revanced/util/resources/ResourceUtils.kt
Normal file
74
src/main/kotlin/app/revanced/util/resources/ResourceUtils.kt
Normal file
@@ -0,0 +1,74 @@
|
||||
package app.revanced.util.resources
|
||||
|
||||
import app.revanced.patcher.data.impl.DomFileEditor
|
||||
import app.revanced.patcher.data.impl.ResourceData
|
||||
import java.nio.file.Files
|
||||
|
||||
internal object ResourceUtils {
|
||||
/**
|
||||
* Copy resources from the current class loader to the resource directory.
|
||||
* @param sourceResourceDirectory The source resource directory name.
|
||||
* @param resources The resources to copy.
|
||||
*/
|
||||
internal fun ResourceData.copyResources(sourceResourceDirectory: String, vararg resources: ResourceGroup) {
|
||||
val classLoader = ResourceUtils.javaClass.classLoader
|
||||
val targetResourceDirectory = this["res"]
|
||||
|
||||
for (resourceGroup in resources) {
|
||||
resourceGroup.resources.forEach { resource ->
|
||||
val resourceFile = "${resourceGroup.resourceDirectoryName}/$resource"
|
||||
Files.copy(
|
||||
classLoader.getResourceAsStream("$sourceResourceDirectory/$resourceFile")!!,
|
||||
targetResourceDirectory.resolve(resourceFile).toPath()
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Resource names mapped to their corresponding resource data.
|
||||
* @param resourceDirectoryName The name of the directory of the resource.
|
||||
* @param resources A list of resource names.
|
||||
*/
|
||||
internal class ResourceGroup(val resourceDirectoryName: String, vararg val resources: String)
|
||||
|
||||
/**
|
||||
* Copy resources from the current class loader to the resource directory.
|
||||
* @param resourceDirectory The directory of the resource.
|
||||
* @param targetResource The target resource.
|
||||
* @param elementTag The element to copy.
|
||||
*/
|
||||
internal fun ResourceData.copyXmlNode(resourceDirectory: String, targetResource: String, elementTag: String) {
|
||||
val stringsResourceInputStream = ResourceUtils.javaClass.classLoader.getResourceAsStream("$resourceDirectory/$targetResource")!!
|
||||
|
||||
// Copy nodes from the resources node to the real resource node
|
||||
elementTag.copyXmlNode(
|
||||
this.xmlEditor[stringsResourceInputStream],
|
||||
this.xmlEditor["res/$targetResource"]
|
||||
).close()
|
||||
}
|
||||
|
||||
/**
|
||||
* Copies the specified node of the source [DomFileEditor] to the target [DomFileEditor].
|
||||
* @param source the source [DomFileEditor].
|
||||
* @param target the target [DomFileEditor]-
|
||||
* @return AutoCloseable that closes the target [DomFileEditor]s.
|
||||
*/
|
||||
internal fun String.copyXmlNode(source: DomFileEditor, target: DomFileEditor): AutoCloseable {
|
||||
val hostNodes = source.file.getElementsByTagName(this).item(0).childNodes
|
||||
|
||||
val destinationResourceFile = target.file
|
||||
val destinationNode = destinationResourceFile.getElementsByTagName(this).item(0)
|
||||
|
||||
for (index in 0 until hostNodes.length) {
|
||||
val node = hostNodes.item(index).cloneNode(true)
|
||||
destinationResourceFile.adoptNode(node)
|
||||
destinationNode.appendChild(node)
|
||||
}
|
||||
|
||||
return AutoCloseable {
|
||||
source.close()
|
||||
target.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
14
src/main/resources/settings/host/values/arrays.xml
Normal file
14
src/main/resources/settings/host/values/arrays.xml
Normal file
@@ -0,0 +1,14 @@
|
||||
<resources>
|
||||
<string-array name="revanced_button_location_entries">
|
||||
<item>@string/revanced_button_location_entry_none</item>
|
||||
<item>@string/revanced_button_location_entry_player</item>
|
||||
<item>@string/revanced_button_location_entry_buttoncontainer</item>
|
||||
<item>@string/revanced_button_location_entry_both</item>
|
||||
</string-array>
|
||||
<string-array name="revanced_button_location_entry_values">
|
||||
<item>NONE</item>
|
||||
<item>PLAYER</item>
|
||||
<item>BUTTON_CONTAINER</item>
|
||||
<item>BOTH</item>
|
||||
</string-array>
|
||||
</resources>
|
||||
227
src/main/resources/settings/host/values/strings.xml
Normal file
227
src/main/resources/settings/host/values/strings.xml
Normal file
@@ -0,0 +1,227 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<string name="revanced_auto_repeat_button_summary_off">"Doesn't show auto-repeat button in the player overlay. Use the toggle below to control auto-repeat"</string>
|
||||
<string name="revanced_auto_repeat_button_summary_on">Auto-repeat button is shown in the player overlay</string>
|
||||
<string name="revanced_auto_repeat_button_title">Auto-repeat button</string>
|
||||
<string name="revanced_auto_repeat_summary_off">Always Auto-repeat is off</string>
|
||||
<string name="revanced_auto_repeat_summary_on">Always Auto-repeat is on</string>
|
||||
<string name="revanced_auto_repeat_title">Always Auto-repeat</string>
|
||||
<string name="revanced_branding_watermark_summary_off">Video watermark is hidden</string>
|
||||
<string name="revanced_branding_watermark_summary_on">Video watermark is shown</string>
|
||||
<string name="revanced_branding_watermark_title">Video watermark</string>
|
||||
<string name="revanced_buffer_title">Buffer settings</string>
|
||||
<string name="revanced_cast_button_summary_off">Cast button is hidden</string>
|
||||
<string name="revanced_cast_button_summary_on">Cast button is shown</string>
|
||||
<string name="revanced_cast_button_title">Cast button</string>
|
||||
<string name="revanced_autoplay_button_summary_off">Autoplay button is hidden</string>
|
||||
<string name="revanced_autoplay_button_summary_on">Autoplay button is shown</string>
|
||||
<string name="revanced_autoplay_button_title">Autoplay button</string>
|
||||
<string name="revanced_codec_override_title">Codec override</string>
|
||||
<string name="revanced_debug_summary_off">Extra debug logging is disabled</string>
|
||||
<string name="revanced_debug_summary_on">Extra Debug logging is enabled</string>
|
||||
<string name="revanced_debug_title">Debug mode</string>
|
||||
<string name="revanced_discord_summary">Tap to join ReVanced on Discord</string>
|
||||
<string name="revanced_discord_title">Discord server</string>
|
||||
<string name="revanced_hdr_full_brightness_summary_on">Video brightness will follow your device\'s brightness on HDR landscape videos</string>
|
||||
<string name="revanced_hdr_full_brightness_summary_off">Video brightness is set to max on HDR landscape videos</string>
|
||||
<string name="revanced_hdr_full_brightness_title">Override HDR Video Brightness</string>
|
||||
<string name="revanced_info_cards_summary_off">Info cards are hidden</string>
|
||||
<string name="revanced_info_cards_summary_on">Info cards are shown</string>
|
||||
<string name="revanced_info_cards_title">Info cards</string>
|
||||
<string name="revanced_layout_settings_title">Layout settings</string>
|
||||
<string name="revanced_maximum_buffer_summary">"The maximum duration of media that the player will attempt to buffer (in milliseconds)
|
||||
|
||||
Default: 120000"</string>
|
||||
<string name="revanced_maximum_buffer_title">Maximum buffer</string>
|
||||
<string name="revanced_misc_title">Miscellaneous</string>
|
||||
<string name="revanced_playback_start_summary">"The duration of media that must be buffered for playback to start or resume following a user action such as seeking (in milliseconds)
|
||||
|
||||
Default: 2500"</string>
|
||||
<string name="revanced_playback_start_title">Playback start</string>
|
||||
<string name="revanced_preferred_video_speed_summary">Select preferred video speed</string>
|
||||
<string name="revanced_preferred_video_speed_title">Preferred video speed</string>
|
||||
<string name="revanced_rebuffer_summary">"The duration of media that must be buffered for playback to resume after a rebuffer (in milliseconds). A rebuffer is defined to be caused by buffer depletion rather than a user action
|
||||
|
||||
Default: 5000"</string>
|
||||
<string name="revanced_rebuffer_title">Rebuffer</string>
|
||||
<string name="revanced_suggestion_summary_off">End screens are hidden</string>
|
||||
<string name="revanced_suggestion_summary_on">End screens are shown</string>
|
||||
<string name="revanced_suggestion_title">End screens</string>
|
||||
<string name="revanced_support_summary">Support links</string>
|
||||
<string name="revanced_support_title">Support</string>
|
||||
<string name="revanced_video_settings_title">Video settings</string>
|
||||
<string name="revanced_vp9_summary">Tap to force usage of the VP9 codec</string>
|
||||
<string name="revanced_vp9_summary_off">VP9 codec not forced</string>
|
||||
<string name="revanced_vp9_summary_on">VP9 codec is enabled by default for supported devices, disable if you encounter stuttering/slowness in videos</string>
|
||||
<string name="revanced_vp9_title">VP9 codec</string>
|
||||
<string name="revanced_new_actionbar_title">Wide search bar</string>
|
||||
<string name="revanced_new_actionbar_summary_off">Search bar style is defined by the app</string>
|
||||
<string name="revanced_new_actionbar_summary_on">Forcing wide search bar</string>
|
||||
<string name="revanced_shorts_button_title">Show shorts button</string>
|
||||
<string name="revanced_shorts_button_summary_off">Shorts button is hidden</string>
|
||||
<string name="revanced_shorts_button_summary_on">Shorts button is shown</string>
|
||||
<string name="revanced_fullscreen_panels_title">Fullscreen panels</string>
|
||||
<string name="revanced_fullscreen_panels_summary_off">Fullscreen panels are hidden</string>
|
||||
<string name="revanced_fullscreen_panels_summary_on">Fullscreen panels are shown</string>
|
||||
<string name="revanced_zoom_to_fit_vertical_title">Dynamic player</string>
|
||||
<string name="revanced_zoom_to_fit_vertical_summary_off">Dynamic player is defined automatically</string>
|
||||
<string name="revanced_zoom_to_fit_vertical_summary_on">Dynamic player is forced on square and vertical videos</string>
|
||||
<string name="revanced_auto_captions_summary_off">Captions aren\'t enabled automatically at 0% volume </string>
|
||||
<string name="revanced_auto_captions_summary_on">Captions are enabled automatically at 0% volume</string>
|
||||
<string name="revanced_auto_captions_title">Auto captions</string>
|
||||
<string name="revanced_swipe_brightness_summary_off">Swipe controls for brightness are disabled</string>
|
||||
<string name="revanced_swipe_brightness_summary_on">Swipe controls for brightness are enabled</string>
|
||||
<string name="revanced_swipe_brightness_title">Swipe controls for Brightness</string>
|
||||
<string name="revanced_swipe_screen_summary">Swipe controls for Brightness and Volume</string>
|
||||
<string name="revanced_swipe_title">Swipe controls</string>
|
||||
<string name="revanced_swipe_volume_summary_off">Swipe controls for volume are disabled</string>
|
||||
<string name="revanced_swipe_volume_summary_on">Swipe controls for volume are enabled</string>
|
||||
<string name="revanced_swipe_volume_title">Swipe controls for Volume</string>
|
||||
<string name="revanced_swipe_pts_title">Press-to-Swipe</string>
|
||||
<string name="revanced_swipe_pts_summary_off">Swipe controls are always active</string>
|
||||
<string name="revanced_swipe_pts_summary_on">Swipe controls require a long-press before activating</string>
|
||||
<string name="revanced_swipe_pts_haptic_title">Vibrate on Press-to-Swipe</string>
|
||||
<string name="revanced_swipe_pts_haptic_summary_on">You\'ll get haptic feedback when activating Press-to-Swipe</string>
|
||||
<string name="revanced_swipe_pts_haptic_summary_off">You won\'t get haptic feedback when activating Press-to-Swipe</string>
|
||||
<string name="revanced_swipe_overlay_timeout_title">Overlay Timeout</string>
|
||||
<string name="revanced_swipe_overlay_timeout_summary">How long the overlay is shown after changes (ms)</string>
|
||||
<string name="revanced_swipe_overlay_text_size_title">Overlay Text Size</string>
|
||||
<string name="revanced_swipe_overlay_text_size_summary">Text size on the overlay</string>
|
||||
<string name="revanced_swipe_overlay_bg_alpha_title">Overlay Background Transparency</string>
|
||||
<string name="revanced_swipe_overlay_bg_alpha_summary">Transparency value of the overlay background (0–255)</string>
|
||||
<string name="revanced_swipe_magnitude_threshold_title">Swipe Magnitude Threshold</string>
|
||||
<string name="revanced_swipe_magnitude_threshold_summary">Minimum magnitude before a swipe is detected</string>
|
||||
<string name="revanced_swipe_tablet_title">Tablet style</string>
|
||||
<string name="revanced_swipe_tablet_summary_on">Tablet style is turned on. For example suggested videos are only partially working</string>
|
||||
<string name="revanced_swipe_tablet_summary_off">Tablet style is turned off</string>
|
||||
<string name="revanced_website_summary">Tap to open our website</string>
|
||||
<string name="revanced_website_title">ReVanced website</string>
|
||||
<string name="revanced_home_ads_summary_off">Home ADS are hidden</string>
|
||||
<string name="revanced_home_ads_summary_on">Home ADS are shown</string>
|
||||
<string name="revanced_home_ads_title">Home ADS</string>
|
||||
<string name="revanced_video_ads_title">Video ADS</string>
|
||||
<string name="revanced_video_ads_summary_off">Video ADS are hidden</string>
|
||||
<string name="revanced_video_ads_summary_on">Video ADS are shown</string>
|
||||
<string name="revanced_reel_summary_off">Stories are hidden</string>
|
||||
<string name="revanced_reel_summary_on">Stories are shown</string>
|
||||
<string name="revanced_reel_title">YouTube stories</string>
|
||||
<string name="revanced_ad_settings_title">AD settings</string>
|
||||
<string name="revanced_tablet_miniplayer_summary_off">Tablet miniplayer is not being used</string>
|
||||
<string name="revanced_tablet_miniplayer_summary_on">Tablet miniplayer is being used</string>
|
||||
<string name="revanced_tablet_miniplayer_title">Tablet miniplayer</string>
|
||||
|
||||
<string name="litho_comments">Comments removal</string>
|
||||
<string name="litho_comments_off">Comments removal is turned off (new comments / phones only)</string>
|
||||
<string name="litho_comments_on">Comments removal is turned on (new comments / phones only)</string>
|
||||
<string name="litho_community_posts">Community post removal</string>
|
||||
<string name="litho_community_posts_off">Community post removal is turned off</string>
|
||||
<string name="litho_community_posts_on">Community post removal is turned on</string>
|
||||
<string name="litho_compact_banner">Compact banner removal</string>
|
||||
<string name="litho_compact_banner_off">Compact banner removal is turned off</string>
|
||||
<string name="litho_compact_banner_on">Compact banner removal is turned on</string>
|
||||
<string name="litho_compact_movie">Compact movie removal</string>
|
||||
<string name="litho_compact_movie_off">Compact movie removal is turned off</string>
|
||||
<string name="litho_compact_movie_on">Compact movie removal is turned on</string>
|
||||
<string name="litho_general_ad_removal">General layout ad removal</string>
|
||||
<string name="litho_general_ad_removal_off">General layout ad removal is turned off</string>
|
||||
<string name="litho_general_ad_removal_on">General layout ad removal is turned on</string>
|
||||
<string name="litho_horizontal_movie_shelf">Movie shelf removal</string>
|
||||
<string name="litho_horizontal_movie_shelf_off">Movie shelf removal is turned off</string>
|
||||
<string name="litho_horizontal_movie_shelf_on">Movie shelf removal is turned on</string>
|
||||
<string name="litho_in_feed_survey">Survey removal</string>
|
||||
<string name="litho_in_feed_survey_off">Feed survey removal is turned off</string>
|
||||
<string name="litho_in_feed_survey_on">Feed survey removal is turned on</string>
|
||||
<string name="litho_merchandise">Merchandise removal</string>
|
||||
<string name="litho_merchandise_off">Merchandise removal is turned off</string>
|
||||
<string name="litho_merchandise_on">Merchandise removal is turned on</string>
|
||||
<string name="litho_movie_upsell">Movie upsell removal</string>
|
||||
<string name="litho_movie_upsell_off">Movie upsell removal is turned off</string>
|
||||
<string name="litho_movie_upsell_on">Movie upsell removal is turned on</string>
|
||||
<string name="litho_emergency_box">Emergency box removal</string>
|
||||
<string name="litho_emergency_box_on">Emergency box removal is turned on</string>
|
||||
<string name="litho_emergency_box_off">Emergency box removal is turned off</string>
|
||||
<string name="litho_info_panel">Info panel removal</string>
|
||||
<string name="litho_info_panel_on">Info panel removal is turned on</string>
|
||||
<string name="litho_info_panel_off">Info panel removal is turned off</string>
|
||||
<string name="litho_medical_panel">Medical panel removal</string>
|
||||
<string name="litho_medical_panel_on">Medical panel removal is turned on</string>
|
||||
<string name="litho_medical_panel_off">Medical panel removal is turned off</string>
|
||||
<string name="litho_paid_content">Paid content removal</string>
|
||||
<string name="litho_paid_content_on">Paid content removal is turned on</string>
|
||||
<string name="litho_paid_content_off">Paid content removal is turned off</string>
|
||||
<string name="litho_suggested">Suggested for you removal</string>
|
||||
<string name="litho_suggested_on">Suggested for you removal is turned on</string>
|
||||
<string name="litho_suggested_off">Suggested for you removal is turned off</string>
|
||||
<string name="litho_hide_suggestions">General Suggestions removal</string>
|
||||
<string name="litho_hide_suggestions_on">General Suggestions removal is turned on</string>
|
||||
<string name="litho_hide_suggestions_off">General Suggestions removal is turned off</string>
|
||||
<string name="litho_latest_posts">Latest posts removal</string>
|
||||
<string name="litho_latest_posts_on">Latest posts removal is turned on</string>
|
||||
<string name="litho_latest_posts_off">Latest posts removal is turned off</string>
|
||||
<string name="litho_channel_guidelines">Channel guidelines removal</string>
|
||||
<string name="litho_channel_guidelines_on">Channel guidelines removal is turned on</string>
|
||||
<string name="litho_channel_guidelines_off">Channel guidelines removal is turned off</string>
|
||||
|
||||
<string name="microg_notification_settings">Notification settings</string>
|
||||
<string name="microg_notification_settings_summary">"1. Google device registration and Cloud Messaging need to be enabled for notifications.
|
||||
2. ReVanced needs to be shown as registered under Cloud Messaging.
|
||||
3. Current State in Cloud Messaging must be Connected."</string>
|
||||
<string name="microg_settings">MicroG settings</string>
|
||||
<string name="revanced_settings">ReVanced settings</string>
|
||||
|
||||
<string name="revanced_seekbar_tapping">Seekbar Tapping</string>
|
||||
<string name="revanced_seekbar_tapping_off">Seekbar Tapping (video progress bar) is disabled</string>
|
||||
<string name="revanced_seekbar_tapping_on">Seekbar Tapping (video progress bar) is enabled</string>
|
||||
|
||||
<string name="revanced_minimized_playback">Background playback</string>
|
||||
<string name="revanced_minimized_playback_off">Background playback is disabled</string>
|
||||
<string name="revanced_minimized_playback_on">Background playback is enabled</string>
|
||||
|
||||
<string name="pref_subtitles_scale_normal">Normal</string>
|
||||
|
||||
<string name="litho_shorts_shelf">Shorts Shelf</string>
|
||||
<string name="litho_shorts_shelf_off">Shorts Shelf removal is turned off</string>
|
||||
<string name="litho_shorts_shelf_on">Shorts Shelf removal is turned on</string>
|
||||
|
||||
<string name="revanced_create_button_summary_off">Create Button is hidden</string>
|
||||
<string name="revanced_create_button_summary_on">Create Button is shown</string>
|
||||
<string name="revanced_create_button_title">Create Button</string>
|
||||
|
||||
<string name="litho_community_guidelines">Community Guidelines</string>
|
||||
<string name="litho_community_guidelines_off">Community Guidelines removal is turned off</string>
|
||||
<string name="litho_community_guidelines_on">Community Guidelines removal is turned on</string>
|
||||
|
||||
<string name="revanced_copy_video_url_summary_off">Copy Link Button is hidden from the player overlay</string>
|
||||
<string name="revanced_copy_video_url_summary_on">Copy Link Button is shown in the player overlay</string>
|
||||
<string name="revanced_copy_video_url_timestamp_summary_off">Copy Link Button With Timestamp is hidden from the player overlay</string>
|
||||
<string name="revanced_copy_video_url_timestamp_summary_on">Copy Link Button With Timestamp is shown in the player overlay</string>
|
||||
<string name="revanced_copy_video_url_timestamp_title">Copy Link Button With Timestamp</string>
|
||||
<string name="revanced_copy_video_url_title">Copy Link Button</string>
|
||||
|
||||
<string name="revanced_old_style_quality_settings_title">Quality Settings style</string>
|
||||
<string name="revanced_old_style_quality_settings_summary_off">Using default style video quality settings</string>
|
||||
<string name="revanced_old_style_quality_settings_summary_on">Using old style video quality settings</string>
|
||||
|
||||
<string name="revanced_videoadwhitelisting_title">Video ad whitelisting</string>
|
||||
<string name="revanced_videoadwhitelisting_summary_off">Video ad whitelisting is turned off</string>
|
||||
<string name="revanced_videoadwhitelisting_summary_on">Video ad whitelisting is turned on. Use the ADS button under the player to whitelist a channel</string>
|
||||
<string name="revanced_whitelisting_ads">ADS</string>
|
||||
<string name="revanced_whitelisting_sponsorblock">SponsorBlock</string>
|
||||
<string name="revanced_whitelisting_added" formatted="false">Channel %s was added to the %s whitelist</string>
|
||||
<string name="revanced_whitelisting_removed" formatted="false">Channel %s was removed from the %s whitelist</string>
|
||||
<string name="revanced_whitelisting_add_failed" formatted="false">Failed to add channel %s to the %s whitelist</string>
|
||||
<string name="revanced_whitelisting_remove_failed" formatted="false">Failed to remove channel %s from the %s whitelist</string>
|
||||
<string name="revanced_whitelisting_fetch_failed" formatted="false">Failed to retrieve channel details, received code %d</string>
|
||||
<string name="revanced_button_location_entry_none">Hidden</string>
|
||||
<string name="revanced_button_location_entry_player">In player</string>
|
||||
<string name="revanced_button_location_entry_buttoncontainer">Under player</string>
|
||||
<string name="revanced_button_location_entry_both">Both</string>
|
||||
<string name="revanced_ryd_settings_title">Return YouTube Dislike settings</string>
|
||||
<string name="revanced_ryd_settings_summary">Uses the RYD API</string>
|
||||
<string name="sb_settings">SponsorBlock settings</string>
|
||||
<string name="sb_summary">Uses the sponsor.ajay.app API</string>
|
||||
<string name="revanced_ryd_title">Enable RYD</string>
|
||||
<string name="revanced_ryd_summary">Switch this on to see the dislike counts again</string>
|
||||
<string name="revanced_ryd_attribution_title">Return YouTube Dislike Integration</string>
|
||||
<string name="revanced_ryd_attribution_summary">This integration uses the RYD API from https://returnyoutubedislike.com. Tap to learn more</string>
|
||||
</resources>
|
||||
12
src/main/resources/settings/host/xml/settings_fragment.xml
Normal file
12
src/main/resources/settings/host/xml/settings_fragment.xml
Normal file
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<Preference android:title="@string/revanced_ryd_settings_title" android:summary="@string/revanced_ryd_settings_summary">
|
||||
<intent android:targetPackage="com.google.android.youtube" android:data="ryd_settings" android:targetClass="com.google.android.libraries.social.licenses.LicenseActivity"/>
|
||||
</Preference>
|
||||
<Preference android:title="@string/sb_settings" android:summary="@string/sb_summary">
|
||||
<intent android:targetPackage="com.google.android.youtube" android:data="sponsorblock_settings" android:targetClass="com.google.android.libraries.social.licenses.LicenseActivity"/>
|
||||
</Preference>
|
||||
<Preference android:title="@string/revanced_settings">
|
||||
<intent android:targetPackage="com.google.android.youtube" android:data="revanced_settings" android:targetClass="com.google.android.libraries.social.licenses.LicenseActivity"/>
|
||||
</Preference>
|
||||
</PreferenceScreen>
|
||||
4
src/main/resources/settings/layout/xsettings_toolbar.xml
Normal file
4
src/main/resources/settings/layout/xsettings_toolbar.xml
Normal file
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" android:background="@color/yt_white1" android:layout_width="match_parent" android:layout_height="wrap_content" android:elevation="4dp">
|
||||
<android.support.v7.widget.Toolbar android:id="@+id/toolbar" android:background="?attr/ytBrandBackgroundSolid" android:layout_width="match_parent" android:layout_height="?attr/actionBarSize" app:navigationIcon="@drawable/quantum_ic_arrow_back_white_24" app:title="ReVanced settings"/>
|
||||
</FrameLayout>
|
||||
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<merge>
|
||||
<include layout="@layout/xsettings_with_toolbar_layout"/>
|
||||
</merge>
|
||||
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:fitsSystemWindows="true" android:layout_width="match_parent" android:layout_height="match_parent" android:transitionGroup="true">
|
||||
<include layout="@layout/xsettings_toolbar"/>
|
||||
<FrameLayout android:id="@+id/xsettings_fragments" android:layout_width="match_parent" android:layout_height="match_parent"/>
|
||||
</LinearLayout>
|
||||
180
src/main/resources/settings/xml/revanced_prefs.xml
Normal file
180
src/main/resources/settings/xml/revanced_prefs.xml
Normal file
@@ -0,0 +1,180 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<PreferenceScreen
|
||||
xmlns:android="http://schemas.android.com/apk/res/android" xmlns:yt="http://schemas.android.com/apk/res-auto">
|
||||
<PreferenceCategory
|
||||
android:layout_height="match_parent"
|
||||
android:title="@string/revanced_settings" />
|
||||
<PreferenceScreen android:title="@string/revanced_codec_override_title" android:key="revanced_override_codec">
|
||||
<SwitchPreference android:title="@string/revanced_vp9_title" android:key="revanced_override_codec_enabled" android:defaultValue="false" android:summaryOn="@string/revanced_vp9_summary_on" android:summaryOff="@string/revanced_vp9_summary_off" />
|
||||
</PreferenceScreen>
|
||||
<PreferenceScreen android:title="@string/revanced_video_settings_title" android:key="video_settings">
|
||||
<SwitchPreference android:title="@string/revanced_old_style_quality_settings_title" android:key="revanced_use_old_style_quality_settings" android:defaultValue="true" android:summaryOn="@string/revanced_old_style_quality_settings_summary_on" android:summaryOff="@string/revanced_old_style_quality_settings_summary_off" />
|
||||
<ListPreference android:title="@string/revanced_preferred_video_speed_title" android:key="revanced_pref_video_speed" android:summary="@string/revanced_preferred_video_speed_summary" />
|
||||
<!--<SwitchPreference android:title="Auto captions" android:key="revanced_pref_auto_captions" android:defaultValue="false" android:summaryOn="Auto captions are turned on" android:summaryOff="Auto captions are turned off" />-->
|
||||
</PreferenceScreen>
|
||||
<!--<PreferenceScreen android:title="@string/revanced_videoadwhitelisting_title" android:key="video_ad_settings">
|
||||
<SwitchPreference android:title="@string/revanced_videoadwhitelisting_title" android:key="revanced_whitelist_ads_enabled" android:defaultValue="false" android:summaryOn="@string/revanced_videoadwhitelisting_summary_on" android:summaryOff="@string/revanced_videoadwhitelisting_summary_off" />
|
||||
</PreferenceScreen>-->
|
||||
<PreferenceScreen
|
||||
android:key="ad_settings"
|
||||
android:title="@string/revanced_ad_settings_title">
|
||||
<SwitchPreference
|
||||
android:defaultValue="false"
|
||||
android:key="revanced_home_ads_enabled"
|
||||
android:summaryOff="@string/revanced_home_ads_summary_off"
|
||||
android:summaryOn="@string/revanced_home_ads_summary_on"
|
||||
android:title="@string/revanced_home_ads_title" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="false"
|
||||
android:key="revanced_video_ads_enabled"
|
||||
android:summaryOff="@string/revanced_video_ads_summary_off"
|
||||
android:summaryOn="@string/revanced_video_ads_summary_on"
|
||||
android:title="@string/revanced_video_ads_title" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_ad_removal"
|
||||
android:summaryOff="@string/litho_general_ad_removal_off"
|
||||
android:summaryOn="@string/litho_general_ad_removal_on"
|
||||
android:title="@string/litho_general_ad_removal" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_merchandise"
|
||||
android:summaryOff="@string/litho_merchandise_off"
|
||||
android:summaryOn="@string/litho_merchandise_on"
|
||||
android:title="@string/litho_merchandise" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_community_posts_removal"
|
||||
android:summaryOff="@string/litho_community_posts_off"
|
||||
android:summaryOn="@string/litho_community_posts_on"
|
||||
android:title="@string/litho_community_posts" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_compact_banner_removal"
|
||||
android:summaryOff="@string/litho_compact_banner_off"
|
||||
android:summaryOn="@string/litho_compact_banner_on"
|
||||
android:title="@string/litho_compact_banner" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="false"
|
||||
android:key="revanced_adremover_comments_removal"
|
||||
android:summaryOff="@string/litho_comments_off"
|
||||
android:summaryOn="@string/litho_comments_on"
|
||||
android:title="@string/litho_comments" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_movie"
|
||||
android:summaryOff="@string/litho_compact_movie_off"
|
||||
android:summaryOn="@string/litho_compact_movie_on"
|
||||
android:title="@string/litho_compact_movie" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_feed_survey"
|
||||
android:summaryOff="@string/litho_in_feed_survey_off"
|
||||
android:summaryOn="@string/litho_in_feed_survey_on"
|
||||
android:title="@string/litho_in_feed_survey" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_shorts_shelf"
|
||||
android:summaryOff="@string/litho_shorts_shelf_off"
|
||||
android:summaryOn="@string/litho_shorts_shelf_on"
|
||||
android:title="@string/litho_shorts_shelf" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_community_guideline"
|
||||
android:summaryOff="@string/litho_community_guidelines_off"
|
||||
android:summaryOn="@string/litho_community_guidelines_on"
|
||||
android:title="@string/litho_community_guidelines" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_emergency_box_removal"
|
||||
android:summaryOff="@string/litho_emergency_box_off"
|
||||
android:summaryOn="@string/litho_emergency_box_on"
|
||||
android:title="@string/litho_emergency_box" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_info_panel"
|
||||
android:summaryOff="@string/litho_info_panel_off"
|
||||
android:summaryOn="@string/litho_info_panel_on"
|
||||
android:title="@string/litho_info_panel" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_medical_panel"
|
||||
android:summaryOff="@string/litho_medical_panel_off"
|
||||
android:summaryOn="@string/litho_medical_panel_on"
|
||||
android:title="@string/litho_medical_panel" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_paid_content"
|
||||
android:summaryOff="@string/litho_paid_content_off"
|
||||
android:summaryOn="@string/litho_paid_content_on"
|
||||
android:title="@string/litho_paid_content" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_suggested"
|
||||
android:summaryOff="@string/litho_suggested_off"
|
||||
android:summaryOn="@string/litho_suggested_on"
|
||||
android:title="@string/litho_suggested" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_hide_suggestions"
|
||||
android:summaryOff="@string/litho_hide_suggestions_off"
|
||||
android:summaryOn="@string/litho_hide_suggestions_on"
|
||||
android:title="@string/litho_hide_suggestions" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_hide_latest_posts"
|
||||
android:summaryOff="@string/litho_latest_posts_off"
|
||||
android:summaryOn="@string/litho_latest_posts_on"
|
||||
android:title="@string/litho_latest_posts" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="revanced_adremover_hide_channel_guidelines"
|
||||
android:summaryOff="@string/litho_channel_guidelines_off"
|
||||
android:summaryOn="@string/litho_channel_guidelines_on"
|
||||
android:title="@string/litho_channel_guidelines" />
|
||||
</PreferenceScreen>
|
||||
<PreferenceScreen android:title="@string/revanced_layout_settings_title" android:key="layout_settings">
|
||||
<SwitchPreference android:title="@string/revanced_reel_title" android:key="revanced_reel_button_enabled" android:defaultValue="false" android:summaryOn="@string/revanced_reel_summary_on" android:summaryOff="@string/revanced_reel_summary_off" />
|
||||
<SwitchPreference android:title="@string/revanced_suggestion_title" android:key="revanced_info_cards_enabled" android:defaultValue="false" android:summaryOn="@string/revanced_suggestion_summary_on" android:summaryOff="@string/revanced_suggestion_summary_off" />
|
||||
<SwitchPreference android:title="@string/revanced_branding_watermark_title" android:key="revanced_branding_watermark_enabled" android:defaultValue="false" android:summaryOn="@string/revanced_branding_watermark_summary_on" android:summaryOff="@string/revanced_branding_watermark_summary_off" />
|
||||
<SwitchPreference android:title="@string/revanced_cast_button_title" android:key="revanced_cast_button_enabled" android:defaultValue="false" android:summaryOn="@string/revanced_cast_button_summary_on" android:summaryOff="@string/revanced_cast_button_summary_off" />
|
||||
<SwitchPreference android:title="@string/revanced_autoplay_button_title" android:key="revanced_autoplay_button_enabled" android:defaultValue="false" android:summaryOn="@string/revanced_autoplay_button_summary_on" android:summaryOff="@string/revanced_autoplay_button_summary_off" />
|
||||
<!--<SwitchPreference android:title="@string/revanced_tablet_miniplayer_title" android:key="revanced_tablet_miniplayer" android:defaultValue="false" android:summaryOn="@string/revanced_tablet_miniplayer_summary_on" android:summaryOff="@string/revanced_tablet_miniplayer_summary_off" />-->
|
||||
<SwitchPreference android:title="@string/revanced_create_button_title" android:key="revanced_create_button_enabled" android:defaultValue="false" android:summaryOn="@string/revanced_create_button_summary_on" android:summaryOff="@string/revanced_create_button_summary_off" />
|
||||
<SwitchPreference android:title="@string/revanced_new_actionbar_title" android:key="revanced_new_actionbar" android:defaultValue="false" android:summaryOn="@string/revanced_new_actionbar_summary_on" android:summaryOff="@string/revanced_new_actionbar_summary_off" />
|
||||
<SwitchPreference android:title="@string/revanced_shorts_button_title" android:key="revanced_shorts_button_enabled" android:defaultValue="false" android:summaryOn="@string/revanced_shorts_button_summary_on" android:summaryOff="@string/revanced_shorts_button_summary_off" />
|
||||
<SwitchPreference android:title="@string/revanced_fullscreen_panels_title" android:key="revanced_fullscreen_panels_enabled" android:defaultValue="false" android:summaryOn="@string/revanced_fullscreen_panels_summary_on" android:summaryOff="@string/revanced_fullscreen_panels_summary_off" />
|
||||
</PreferenceScreen>
|
||||
<PreferenceScreen android:title="@string/revanced_misc_title" android:key="misc_screen">
|
||||
<SwitchPreference android:title="@string/revanced_auto_repeat_title" android:key="revanced_pref_auto_repeat" android:defaultValue="false" android:summaryOn="@string/revanced_auto_repeat_summary_on" android:summaryOff="@string/revanced_auto_repeat_summary_off" />
|
||||
<!--<ListPreference android:entries="@array/revanced_button_location_entries" android:title="@string/revanced_copy_video_url_timestamp_title" android:key="revanced_pref_copy_video_url_timestamp_button_list" android:entryValues="@array/revanced_button_location_entry_values" />
|
||||
<ListPreference android:entries="@array/revanced_button_location_entries" android:title="@string/revanced_copy_video_url_title" android:key="revanced_pref_copy_video_url_button_list" android:entryValues="@array/revanced_button_location_entry_values" />-->
|
||||
<SwitchPreference android:title="@string/revanced_hdr_full_brightness_title" android:key="revanced_pref_hdr_autobrightness" android:defaultValue="false" android:summaryOn="@string/revanced_hdr_full_brightness_summary_on" android:summaryOff="@string/revanced_hdr_full_brightness_summary_off" />
|
||||
<SwitchPreference android:title="@string/revanced_seekbar_tapping" android:key="revanced_enable_tap_seeking" android:defaultValue="true" android:summaryOn="@string/revanced_seekbar_tapping_on" android:summaryOff="@string/revanced_seekbar_tapping_off" />
|
||||
<SwitchPreference android:title="@string/revanced_minimized_playback" android:key="revanced_enable_minimized_playback" android:defaultValue="true" android:summaryOn="@string/revanced_minimized_playback_on" android:summaryOff="@string/revanced_minimized_playback_off" />
|
||||
</PreferenceScreen>
|
||||
<PreferenceScreen android:title="@string/revanced_swipe_title" android:key="swipe_screen" android:summary="@string/revanced_swipe_screen_summary">
|
||||
<SwitchPreference android:title="@string/revanced_swipe_brightness_title" android:key="revanced_enable_swipe_brightness" android:defaultValue="false" android:summaryOn="@string/revanced_swipe_brightness_summary_on" android:summaryOff="@string/revanced_swipe_brightness_summary_off" />
|
||||
<SwitchPreference android:title="@string/revanced_swipe_volume_title" android:key="revanced_enable_swipe_volume" android:defaultValue="false" android:summaryOn="@string/revanced_swipe_volume_summary_on" android:summaryOff="@string/revanced_swipe_volume_summary_off" />
|
||||
<SwitchPreference android:title="@string/revanced_swipe_pts_title" android:key="revanced_enable_press_to_swipe" android:defaultValue="false" android:summaryOn="@string/revanced_swipe_pts_summary_on" android:summaryOff="@string/revanced_swipe_pts_summary_off" />
|
||||
<SwitchPreference android:title="@string/revanced_swipe_pts_haptic_title" android:key="revanced_enable_swipe_haptic_feedback" android:defaultValue="false" android:summaryOn="@string/revanced_swipe_pts_haptic_summary_on" android:summaryOff="@string/revanced_swipe_pts_haptic_summary_off" />
|
||||
<EditTextPreference android:inputType="number" android:title="@string/revanced_swipe_overlay_timeout_title" android:key="revanced_swipe_overlay_timeout" android:summary="@string/revanced_swipe_overlay_timeout_summary" android:defaultValue="500" />
|
||||
<EditTextPreference android:inputType="number" android:title="@string/revanced_swipe_overlay_text_size_title" android:key="revanced_swipe_overlay_text_size" android:summary="@string/revanced_swipe_overlay_text_size_summary" android:defaultValue="22" />
|
||||
<EditTextPreference android:inputType="number" android:title="@string/revanced_swipe_overlay_bg_alpha_title" android:key="revanced_swipe_overlay_background_alpha" android:summary="@string/revanced_swipe_overlay_bg_alpha_summary" android:defaultValue="127" />
|
||||
<EditTextPreference android:inputType="number" android:title="@string/revanced_swipe_magnitude_threshold_title" android:key="revanced_swipe_magnitude_threshold" android:summary="@string/revanced_swipe_magnitude_threshold_summary" android:defaultValue="30" />
|
||||
</PreferenceScreen>
|
||||
<PreferenceScreen android:title="@string/revanced_buffer_title" android:key="buffer_screen">
|
||||
<EditTextPreference android:inputType="number" android:title="@string/revanced_maximum_buffer_title" android:key="revanced_pref_max_buffer_ms" android:summary="@string/revanced_maximum_buffer_summary" android:defaultValue="120000" />
|
||||
<EditTextPreference android:inputType="number" android:title="@string/revanced_playback_start_title" android:key="revanced_pref_buffer_for_playback_ms" android:summary="@string/revanced_playback_start_summary" android:defaultValue="2500" />
|
||||
<EditTextPreference android:inputType="number" android:title="@string/revanced_rebuffer_title" android:key="revanced_pref_buffer_for_playback_after_rebuffer_ms" android:summary="@string/revanced_rebuffer_summary" android:defaultValue="5000" />
|
||||
</PreferenceScreen>
|
||||
<PreferenceScreen android:title="@string/revanced_support_title" android:key="support_screen" android:summary="@string/revanced_support_summary">
|
||||
<Preference android:title="@string/revanced_discord_title" android:summary="@string/revanced_discord_summary">
|
||||
<intent android:action="android.intent.action.VIEW" android:data="https://discord.gg/rF2YcEjcrT" />
|
||||
</Preference>
|
||||
<Preference android:title="@string/revanced_website_title" android:summary="@string/revanced_website_summary">
|
||||
<intent android:action="android.intent.action.VIEW" android:data="https://revanced.app" />
|
||||
</Preference>
|
||||
</PreferenceScreen>
|
||||
<SwitchPreference android:title="@string/revanced_debug_title" android:key="revanced_debug_enabled" android:defaultValue="false" android:summaryOn="@string/revanced_debug_summary_on" android:summaryOff="@string/revanced_debug_summary_off" />
|
||||
</PreferenceScreen>
|
||||
@@ -57,7 +57,7 @@
|
||||
<string name="about">About</string>
|
||||
<string name="about_api">This app uses the API from SponsorBlock</string>
|
||||
<string name="about_api_sum">Tap to learn more, and see downloads for other platforms at: sponsor.ajay.app</string>
|
||||
<string name="about_madeby">Integration made by JakubWeg</string>
|
||||
<string name="about_madeby">Integration made by JakubWeg, recoded by oSumAtrIX</string>
|
||||
<string name="tap_skip">Tap to skip</string>
|
||||
|
||||
<string name="submit_failed_unknown_error" formatted="false">Unable to submit segments: Status: %d %s</string>
|
||||
@@ -105,9 +105,6 @@
|
||||
<string name="sb_guidelines_popup_already_read">Already read</string>
|
||||
<string name="sb_guidelines_popup_open">Show me</string>
|
||||
|
||||
<string name="sb_settings">SponsorBlock settings</string>
|
||||
<string name="sb_summary">Uses the sponsor.ajay.app API</string>
|
||||
|
||||
<string name="general_time_without_sb">Show time without segments</string>
|
||||
<string name="general_time_without_sb_sum">This time appears in brackets next to the current time. This shows the total video duration minus any segments.</string>
|
||||
<string name="general_whitelisting">Channel whitelisting</string>
|
||||
|
||||
Reference in New Issue
Block a user