Compare commits
173 commits
main
...
main-night
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9f726e09be | ||
|
|
19d32e6fd5 | ||
|
|
5ad86b9af8 | ||
|
|
83cc6b12d2 | ||
|
|
9c5992b075 | ||
|
|
d7c3bb86ec | ||
|
|
9596faad77 | ||
|
|
86677c720c | ||
|
|
5caf4a3206 | ||
|
|
b6897d50bc | ||
|
|
5476d72761 | ||
|
|
959c71033c | ||
|
|
dc0c71c74c | ||
|
|
0fe0d748e1 | ||
|
|
d06fab0703 | ||
|
|
ad6db4f972 | ||
|
|
dd258d092e | ||
|
|
93c73d6c73 | ||
|
|
3f06713815 | ||
|
|
cc0651b9d5 | ||
|
|
450df5d505 | ||
|
|
36bcad3950 | ||
|
|
f60bc5f283 | ||
|
|
654bce5531 | ||
|
|
07c2b22a29 | ||
|
|
36f762136d | ||
|
|
a09362d70e | ||
|
|
ca7e5e40fc | ||
|
|
498f5bd3b7 | ||
|
|
f535c919ca | ||
|
|
70d73a31e4 | ||
|
|
5bf8355b39 | ||
|
|
19e2bb2d73 | ||
|
|
513a486523 | ||
|
|
536364a88f | ||
|
|
e900e85a73 | ||
|
|
7a4edbec64 | ||
|
|
03591936d0 | ||
|
|
55a8a11c75 | ||
|
|
9e6d753199 | ||
|
|
b6ec2f5f1a | ||
|
|
d9eba087fc | ||
|
|
c20b8cf0d0 | ||
|
|
bc7233df02 | ||
|
|
d7333d4595 | ||
|
|
641a1afbd7 | ||
|
|
286ae41019 | ||
|
|
0a81e45d51 | ||
|
|
e27e5f206a | ||
|
|
c8e76e0efe | ||
|
|
f710ea4745 | ||
|
|
3822138bc0 | ||
|
|
09829f0d70 | ||
|
|
7970ffb29d | ||
|
|
9d4ef4fb32 | ||
|
|
d5a2f77cca | ||
|
|
c06a938b9b | ||
|
|
7e0a087a40 | ||
|
|
6595de8a60 | ||
|
|
e0c0949251 | ||
|
|
2fb8d70b48 | ||
|
|
6e6e6592e6 | ||
|
|
218fe12328 | ||
|
|
d63ee3a9f3 | ||
|
|
18ee4e871f | ||
|
|
43a9491dce | ||
|
|
57b1ac17a9 | ||
|
|
9501445c19 | ||
|
|
8e417b7cde | ||
|
|
581f15d32d | ||
|
|
644db69a3f | ||
|
|
ced6e2c7bb | ||
|
|
81dcce8555 | ||
|
|
69c9399f9f | ||
|
|
4d8e9f70b7 | ||
|
|
7db477d9a9 | ||
|
|
6057279454 | ||
|
|
0a74391fba | ||
|
|
9de3ac645e | ||
|
|
26b8ca0a95 | ||
|
|
addc8cc914 | ||
|
|
1fe2b9f684 | ||
|
|
22a56d3450 | ||
|
|
c66e5247e1 | ||
|
|
95ae61fd0a | ||
|
|
c258c339fe | ||
|
|
53eb25f260 | ||
|
|
6987753f93 | ||
|
|
06e014dff7 | ||
|
|
e44fbcf16c | ||
|
|
11d28bc4f5 | ||
|
|
e1bce2c0eb | ||
|
|
baea7e8cd7 | ||
|
|
e437e8cecc | ||
|
|
3830d87b77 | ||
|
|
77153f0bfb | ||
|
|
a857168423 | ||
|
|
5d2ea47fd6 | ||
|
|
6e95fc554f | ||
|
|
de59708a3c | ||
|
|
c9c7952ae3 | ||
|
|
ddf5070386 | ||
|
|
57e299f708 | ||
|
|
1e1c4b4dae | ||
|
|
e389ecb6d6 | ||
|
|
8d8a2b2135 | ||
|
|
0b4b55c2cb | ||
|
|
760895a50f | ||
|
|
2c59ef4231 | ||
|
|
3715faeac8 | ||
|
|
338701eac0 | ||
|
|
3b9fee4d93 | ||
|
|
5fc2d7c204 | ||
|
|
3c94b4ba98 | ||
|
|
81d1ddaea1 | ||
|
|
20f447027d | ||
|
|
0d2d10334a | ||
|
|
7024fed57d | ||
|
|
4ff78dc8f7 | ||
|
|
67d16973f3 | ||
|
|
c22e4c4714 | ||
|
|
747aa5414d | ||
|
|
e7280ef787 | ||
|
|
ebc95d8de2 | ||
|
|
f0d0797eca | ||
|
|
0d11f24c44 | ||
|
|
ed6e421da9 | ||
|
|
d93cfe2713 | ||
|
|
8bb96cd365 | ||
|
|
8129de961f | ||
|
|
f310fd4680 | ||
|
|
6b0c1424ea | ||
|
|
9c61a8868a | ||
|
|
a7dbb42a44 | ||
|
|
9df9b15975 | ||
|
|
425935de27 | ||
|
|
40a15fdf3f | ||
|
|
c568291586 | ||
|
|
9b82c82851 | ||
|
|
9b3f01bcd0 | ||
|
|
752ca2f693 | ||
|
|
7f240104cd | ||
|
|
237ad26bdb | ||
|
|
39b6f34782 | ||
|
|
6243f61d46 | ||
|
|
a85478572b | ||
|
|
98f021ffb3 | ||
|
|
f1269e7ef3 | ||
|
|
09438f7fc6 | ||
|
|
2f01bb36c7 | ||
|
|
f8ea01e32c | ||
|
|
0851ba0b04 | ||
|
|
c99d7620af | ||
|
|
cfc2ac4497 | ||
|
|
f3a927869a | ||
|
|
696f144a43 | ||
|
|
4d9927ea7e | ||
|
|
35e14f7dbe | ||
|
|
a0c1890012 | ||
|
|
4ef8b6e000 | ||
|
|
a59b0264d0 | ||
|
|
14dcb8831f | ||
|
|
b261bef5ef | ||
|
|
a51084e4be | ||
|
|
cdcbb475fc | ||
|
|
9187e9132a | ||
|
|
46007fd0f8 | ||
|
|
1e421b9447 | ||
|
|
860e554898 | ||
|
|
ef26c08644 | ||
|
|
66bea70288 | ||
|
|
a28dd2dcec | ||
|
|
813603b214 |
8
.github/workflows/buildapp.yml
vendored
|
|
@ -8,7 +8,7 @@ on:
|
||||||
inputs:
|
inputs:
|
||||||
sdk_version:
|
sdk_version:
|
||||||
description: "iOS SDK Version"
|
description: "iOS SDK Version"
|
||||||
default: "16.4"
|
default: "16.5"
|
||||||
required: true
|
required: true
|
||||||
type: string
|
type: string
|
||||||
uyou_version:
|
uyou_version:
|
||||||
|
|
@ -38,12 +38,12 @@ on:
|
||||||
type: string
|
type: string
|
||||||
upload_artifact:
|
upload_artifact:
|
||||||
description: "Upload IPA as artifact"
|
description: "Upload IPA as artifact"
|
||||||
default: true
|
default: false
|
||||||
required: false
|
required: false
|
||||||
type: boolean
|
type: boolean
|
||||||
create_release:
|
create_release:
|
||||||
description: "Create a draft release"
|
description: "Create a draft release"
|
||||||
default: false
|
default: true
|
||||||
required: false
|
required: false
|
||||||
type: boolean
|
type: boolean
|
||||||
|
|
||||||
|
|
@ -137,7 +137,7 @@ jobs:
|
||||||
cd ${{ github.workspace }}/main
|
cd ${{ github.workspace }}/main
|
||||||
sed -i '' "27s#.*#BUNDLE_ID = ${{ env.BUNDLE_ID }}#g" Makefile # Modify the bundle ID
|
sed -i '' "27s#.*#BUNDLE_ID = ${{ env.BUNDLE_ID }}#g" Makefile # Modify the bundle ID
|
||||||
sed -i '' "26s#.*#DISPLAY_NAME = ${{ env.APP_NAME }}#g" Makefile # Modify the app name
|
sed -i '' "26s#.*#DISPLAY_NAME = ${{ env.APP_NAME }}#g" Makefile # Modify the app name
|
||||||
sed -i '' "1s#.*#export TARGET = iphone:clang:${{ inputs.sdk_version }}:14.0#g" Makefile # Modify the SDK version
|
sed -i '' "1s#.*#export TARGET = iphone:clang:${{ inputs.sdk_version }}:15.0#g" Makefile # Modify the SDK version
|
||||||
make package THEOS_PACKAGE_SCHEME=rootless IPA=Payload/YouTube.app FINALPACKAGE=1
|
make package THEOS_PACKAGE_SCHEME=rootless IPA=Payload/YouTube.app FINALPACKAGE=1
|
||||||
echo "package=$(ls -t packages | head -n1)" >>$GITHUB_OUTPUT
|
echo "package=$(ls -t packages | head -n1)" >>$GITHUB_OUTPUT
|
||||||
echo -e "==> \033[1mSHASUM256: $(shasum -a 256 packages/*.ipa | cut -f1 -d' ')\033[0m"
|
echo -e "==> \033[1mSHASUM256: $(shasum -a 256 packages/*.ipa | cut -f1 -d' ')\033[0m"
|
||||||
|
|
|
||||||
2
.github/workflows/update-submodules.yml
vendored
|
|
@ -9,7 +9,7 @@ jobs:
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
uses: actions/checkout@v4.1.4
|
uses: actions/checkout@v4.1.6
|
||||||
|
|
||||||
- name: Set up Git
|
- name: Set up Git
|
||||||
run: |
|
run: |
|
||||||
|
|
|
||||||
4
.gitmodules
vendored
|
|
@ -78,3 +78,7 @@
|
||||||
[submodule "Tweaks/YouTimeStamp"]
|
[submodule "Tweaks/YouTimeStamp"]
|
||||||
path = Tweaks/YouTimeStamp
|
path = Tweaks/YouTimeStamp
|
||||||
url = https://github.com/arichornlover/YouTimeStamp.git
|
url = https://github.com/arichornlover/YouTimeStamp.git
|
||||||
|
branch = wip
|
||||||
|
[submodule "Tweaks/protobuf"]
|
||||||
|
path = Tweaks/protobuf
|
||||||
|
url = https://github.com/protocolbuffers/protobuf.git
|
||||||
|
|
|
||||||
|
Before Width: | Height: | Size: 12 KiB |
BIN
Localizations/uYouPlus.bundle/AppIcons/2013/2013@2x.png
Normal file
|
After Width: | Height: | Size: 8 KiB |
BIN
Localizations/uYouPlus.bundle/AppIcons/2013/2013@3x.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
|
After Width: | Height: | Size: 9.5 KiB |
|
After Width: | Height: | Size: 26 KiB |
BIN
Localizations/uYouPlus.bundle/AppIcons/Gold/Gold@2x.png
Normal file
|
After Width: | Height: | Size: 4.9 KiB |
BIN
Localizations/uYouPlus.bundle/AppIcons/Gold/Gold@3x.png
Normal file
|
After Width: | Height: | Size: 9.6 KiB |
BIN
Localizations/uYouPlus.bundle/AppIcons/Pink.png
Normal file
|
After Width: | Height: | Size: 28 KiB |
BIN
Localizations/uYouPlus.bundle/AppIcons/Purple.png
Normal file
|
After Width: | Height: | Size: 31 KiB |
BIN
Localizations/uYouPlus.bundle/AppIcons/Rainbow.png
Normal file
|
After Width: | Height: | Size: 111 KiB |
BIN
Localizations/uYouPlus.bundle/AppIcons/Shorts/Shorts@2x.png
Normal file
|
After Width: | Height: | Size: 5.2 KiB |
BIN
Localizations/uYouPlus.bundle/AppIcons/Shorts/Shorts@3x.png
Normal file
|
After Width: | Height: | Size: 6.9 KiB |
|
|
@ -26,7 +26,7 @@
|
||||||
<dict>
|
<dict>
|
||||||
<key>CFBundleIconFiles</key>
|
<key>CFBundleIconFiles</key>
|
||||||
<array>
|
<array>
|
||||||
<string>AppIcon</string>
|
<string>logo_youtube_color</string>
|
||||||
</array>
|
</array>
|
||||||
</dict>
|
</dict>
|
||||||
<key>CFBundleAlternateIcons</key>
|
<key>CFBundleAlternateIcons</key>
|
||||||
|
|
@ -59,6 +59,13 @@
|
||||||
<string>Outline</string>
|
<string>Outline</string>
|
||||||
</array>
|
</array>
|
||||||
</dict>
|
</dict>
|
||||||
|
<key>Shorts</key>
|
||||||
|
<dict>
|
||||||
|
<key>CFBundleIconFiles</key>
|
||||||
|
<array>
|
||||||
|
<string>Shorts</string>
|
||||||
|
</array>
|
||||||
|
</dict>
|
||||||
<key>2012</key>
|
<key>2012</key>
|
||||||
<dict>
|
<dict>
|
||||||
<key>CFBundleIconFiles</key>
|
<key>CFBundleIconFiles</key>
|
||||||
|
|
|
||||||
BIN
Localizations/uYouPlus.bundle/UI/explore_24pt.png
Normal file
|
After Width: | Height: | Size: 1.7 KiB |
BIN
Localizations/uYouPlus.bundle/UI/explore_selected_24pt.png
Normal file
|
After Width: | Height: | Size: 1.4 KiB |
BIN
Localizations/uYouPlus.bundle/UI/home_24pt.png
Normal file
|
After Width: | Height: | Size: 891 B |
BIN
Localizations/uYouPlus.bundle/UI/home_selected_24pt.png
Normal file
|
After Width: | Height: | Size: 733 B |
BIN
Localizations/uYouPlus.bundle/UI/notifications_24pt.png
Normal file
|
After Width: | Height: | Size: 4 KiB |
BIN
Localizations/uYouPlus.bundle/UI/notifications_selected_24pt.png
Normal file
|
After Width: | Height: | Size: 554 B |
BIN
Localizations/uYouPlus.bundle/UI/subscriptions_24pt.png
Normal file
|
After Width: | Height: | Size: 711 B |
BIN
Localizations/uYouPlus.bundle/UI/subscriptions_selected_24pt.png
Normal file
|
After Width: | Height: | Size: 618 B |
|
After Width: | Height: | Size: 688 B |
|
After Width: | Height: | Size: 928 B |
BIN
Localizations/uYouPlus.bundle/UI/yt_outline_download_24pt.png
Normal file
|
After Width: | Height: | Size: 683 B |
BIN
Localizations/uYouPlus.bundle/UI/yt_outline_gear_24pt.png
Normal file
|
After Width: | Height: | Size: 4.5 KiB |
BIN
Localizations/uYouPlus.bundle/UI/yt_outline_my_videos_24pt.png
Normal file
|
After Width: | Height: | Size: 661 B |
|
After Width: | Height: | Size: 1.6 KiB |
BIN
Localizations/uYouPlus.bundle/UI/yt_outline_search_24pt.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
2
Makefile
|
|
@ -1,4 +1,4 @@
|
||||||
export TARGET = iphone:clang:16.4:14.0
|
export TARGET = iphone:clang:16.5:14.0
|
||||||
export ARCHS = arm64
|
export ARCHS = arm64
|
||||||
|
|
||||||
export libcolorpicker_ARCHS = arm64
|
export libcolorpicker_ARCHS = arm64
|
||||||
|
|
|
||||||
54
README.md
|
|
@ -40,8 +40,6 @@
|
||||||
[](#wiki)<br>
|
[](#wiki)<br>
|
||||||
|
|
||||||
# Credits
|
# Credits
|
||||||
- Special thanks to all the developers who have worked on uYouPlus/uYouEnhanced!
|
|
||||||
|
|
||||||
<table id='credit'>
|
<table id='credit'>
|
||||||
<tr>
|
<tr>
|
||||||
|
|
||||||
|
|
@ -204,13 +202,13 @@
|
||||||
<a href='https://github.com/balackburn'>balackburn</a>
|
<a href='https://github.com/balackburn'>balackburn</a>
|
||||||
</td>
|
</td>
|
||||||
|
|
||||||
<theos>
|
<dodieboy>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<a href='https://github.com/theos/theos'>
|
<a href='https://github.com/dodieboy'>
|
||||||
<img src='https://user-images.githubusercontent.com/78001398/271813393-56a63730-a56d-41ba-b473-4d37761526c9.png' width='110px'>
|
<img src='https://github.com/arichornlover/YouTubeRebornPlus/assets/78001398/0d43912b-e561-4865-8312-5e241d34bf72' width='110px;'>
|
||||||
</a>
|
</a>
|
||||||
<br>
|
<br>
|
||||||
<a href='https://theos.dev'>theos</a>
|
<a href='https://github.com/dodieboy'>dodieboy</a>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
|
|
@ -224,6 +222,15 @@
|
||||||
<br>
|
<br>
|
||||||
<a href='https://github.com/bhackel'>bhackel</a>
|
<a href='https://github.com/bhackel'>bhackel</a>
|
||||||
</td>
|
</td>
|
||||||
|
|
||||||
|
<theos>
|
||||||
|
<td align="center">
|
||||||
|
<a href='https://github.com/theos/theos'>
|
||||||
|
<img src='https://user-images.githubusercontent.com/78001398/271813393-56a63730-a56d-41ba-b473-4d37761526c9.png' width='110px'>
|
||||||
|
</a>
|
||||||
|
<br>
|
||||||
|
<a href='https://theos.dev'>theos</a>
|
||||||
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
|
@ -337,14 +344,29 @@ or [qnblackcat/Building - Wiki](https://github.com/qnblackcat/uYouPlus/wiki/Buil
|
||||||
See [Installation - Wiki](https://github.com/qnblackcat/uYouPlus/wiki/Installation).
|
See [Installation - Wiki](https://github.com/qnblackcat/uYouPlus/wiki/Installation).
|
||||||
|
|
||||||
# Support the developers
|
# Support the developers
|
||||||
- [**MiRO92**](https://twitter.com/miro92): https://github.com/MiRO92/uYou-for-YouTube#support
|
<a href="https://buymeacoffee.com/dayanch96"><img src="https://github.com/YTLitePlus/Assets/blob/main/Github/Buttons/Donations/Dayanch96(buymeacoffee).png" width="200"></a>
|
||||||
- [**PoomSmart**](https://github.com/PoomSmart): https://poomsmart.github.io
|
|
||||||
- [**level3tjg**](https://twitter.com/level3tjg): https://ko-fi.com/level3tjg
|
<a href="https://github.com/sponsors/dayanch96"><img src="https://github.com/YTLitePlus/Assets/blob/main/Github/Buttons/Donations/Dayanch96(Github).png" width="200"></a>
|
||||||
- [**BandarHL**](https://twitter.com/bandarhl): https://www.paypal.com/paypalme/BandarHL
|
|
||||||
- [**julioverne**](https://twitter.com/ijulioverne): https://www.patreon.com/julioverne
|
<a href="https://ko-fi.com/dayanch966"><img src="https://github.com/YTLitePlus/Assets/blob/main/Github/Buttons/Donations/Dayanch96(ko-fi).png" width="200"></a>
|
||||||
- [**Galactic-dev**](https://twitter.com/dev_galactic):
|
|
||||||
- Paypal: https://www.paypal.com/paypalme/DBrett684
|
<a href="https://www.paypal.com/paypalme/poomsmart"><img src="https://github.com/YTLitePlus/Assets/blob/main/Github/Buttons/Donations/Poomsmart.png" width="200"></a>
|
||||||
- Venmo: https://venmo.com/u/DavidBrett
|
|
||||||
|
<a href="https://www.paypal.com/paypalme/DBrett684"><img src="https://github.com/YTLitePlus/Assets/blob/main/Github/Buttons/Donations/Galactic-dev(Paypal).png" width="200"></a>
|
||||||
|
|
||||||
|
<a href="https://venmo.com/u/DavidBrett"><img src="https://github.com/YTLitePlus/Assets/blob/main/Github/Buttons/Donations/Galactic-dev(Venmo).png?raw=true" width="200"></a>
|
||||||
|
|
||||||
|
|
||||||
|
<a href="https://github.com/MiRO92/uYou-for-YouTube#support"><img src="https://raw.githubusercontent.com/YTLitePlus/Assets/main/Github/Buttons/Donations/MIRO92.png" width="200"></a>
|
||||||
|
|
||||||
|
|
||||||
|
<a href="https://www.paypal.com/paypalme/BandarHL"><img src="https://github.com/YTLitePlus/Assets/blob/main/Github/Buttons/Donations/BandarHL.png" width="200"></a>
|
||||||
|
|
||||||
|
|
||||||
|
<a href="https://ko-fi.com/level3tjg"><img src="https://github.com/YTLitePlus/Assets/blob/main/Github/Buttons/Donations/level3tjg.png?raw=true" width="200"></a>
|
||||||
|
|
||||||
|
|
||||||
|
<a href="https://www.patreon.com/julioverne"><img src="https://github.com/YTLitePlus/Assets/blob/main/Github/Buttons/Donations/julioverne.png?raw=true" width="200"></a>
|
||||||
|
|
||||||
# Wiki
|
# Wiki
|
||||||
|
|
||||||
|
|
@ -371,9 +393,9 @@ https://github.com/Balackburn/YTLitePlus/releases
|
||||||
|
|
||||||
- YTLitePlus does not cause your device to overheat, unlike uYouEnhanced.
|
- YTLitePlus does not cause your device to overheat, unlike uYouEnhanced.
|
||||||
|
|
||||||
**Cons**
|
- YTLitePlus provides faster video & audio downloading than uYouPlus/uYouEnhanced.
|
||||||
|
|
||||||
- No custom video downloading feature in YTLitePlus.
|
**Cons**
|
||||||
|
|
||||||
- Video quality on WiFi option is not available in YTLitePlus.
|
- Video quality on WiFi option is not available in YTLitePlus.
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,4 @@
|
||||||
#import "uYouPlus.h"
|
#import "uYouPlus.h"
|
||||||
|
|
||||||
@interface YTMainAppVideoPlayerOverlayView : UIView
|
|
||||||
- (UIViewController *)_viewControllerForAncestor;
|
|
||||||
@end
|
|
||||||
|
|
||||||
@interface YTWatchMiniBarView : UIView
|
@interface YTWatchMiniBarView : UIView
|
||||||
@end
|
@end
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ static BOOL customContrastMode() {
|
||||||
|
|
||||||
UIColor *lcmHexColor;
|
UIColor *lcmHexColor;
|
||||||
|
|
||||||
%group gLowContrastMode // Low Contrast Mode v1.5.2 (Compatible with only YouTube v17.33.2-v17.38.10)
|
%group gLowContrastMode // Low Contrast Mode v1.6.0 BETA (Compatible with only YouTube v17.33.2-v17.38.10)
|
||||||
%hook UIColor
|
%hook UIColor
|
||||||
+ (UIColor *)whiteColor { // Dark Theme Color
|
+ (UIColor *)whiteColor { // Dark Theme Color
|
||||||
return [UIColor colorWithRed: 0.56 green: 0.56 blue: 0.56 alpha: 1.00];
|
return [UIColor colorWithRed: 0.56 green: 0.56 blue: 0.56 alpha: 1.00];
|
||||||
|
|
@ -246,12 +246,21 @@ UIColor *lcmHexColor;
|
||||||
[modifiedAttributes setObject:[UIColor whiteColor] forKey:NSForegroundColorAttributeName];
|
[modifiedAttributes setObject:[UIColor whiteColor] forKey:NSForegroundColorAttributeName];
|
||||||
%orig(modifiedAttributes, state);
|
%orig(modifiedAttributes, state);
|
||||||
}
|
}
|
||||||
|
- (void)setCustomTitleTextAttributes:(NSDictionary *)attributes forState:(UIControlState)state {
|
||||||
|
NSMutableDictionary *customAttributes = [NSMutableDictionary dictionaryWithDictionary:attributes];
|
||||||
|
[customAttributes setObject:[UIColor whiteColor] forKey:NSForegroundColorAttributeName];
|
||||||
|
%orig(customAttributes, state);
|
||||||
|
}
|
||||||
%end
|
%end
|
||||||
%hook UIButton
|
%hook UIButton
|
||||||
- (void)setTitleColor:(UIColor *)color forState:(UIControlState)state {
|
- (void)setTitleColor:(UIColor *)color forState:(UIControlState)state {
|
||||||
color = [UIColor whiteColor];
|
color = [UIColor whiteColor];
|
||||||
%orig(color, state);
|
%orig(color, state);
|
||||||
}
|
}
|
||||||
|
- (void)setCustomTitleColor:(UIColor *)color forState:(UIControlState)state {
|
||||||
|
color = [UIColor whiteColor];
|
||||||
|
%orig(color, state);
|
||||||
|
}
|
||||||
%end
|
%end
|
||||||
%hook UIBarButtonItem
|
%hook UIBarButtonItem
|
||||||
- (void)setTitleTextAttributes:(NSDictionary *)attributes forState:(UIControlState)state {
|
- (void)setTitleTextAttributes:(NSDictionary *)attributes forState:(UIControlState)state {
|
||||||
|
|
@ -259,6 +268,11 @@ UIColor *lcmHexColor;
|
||||||
[modifiedAttributes setObject:[UIColor whiteColor] forKey:NSForegroundColorAttributeName];
|
[modifiedAttributes setObject:[UIColor whiteColor] forKey:NSForegroundColorAttributeName];
|
||||||
%orig(modifiedAttributes, state);
|
%orig(modifiedAttributes, state);
|
||||||
}
|
}
|
||||||
|
- (void)setCustomTitleTextAttributes:(NSDictionary *)attributes forState:(UIControlState)state {
|
||||||
|
NSMutableDictionary *customAttributes = [NSMutableDictionary dictionaryWithDictionary:attributes];
|
||||||
|
[customAttributes setObject:[UIColor whiteColor] forKey:NSForegroundColorAttributeName];
|
||||||
|
%orig(customAttributes, state);
|
||||||
|
}
|
||||||
%end
|
%end
|
||||||
%hook NSAttributedString
|
%hook NSAttributedString
|
||||||
- (instancetype)initWithString:(NSString *)str attributes:(NSDictionary<NSAttributedStringKey, id> *)attrs {
|
- (instancetype)initWithString:(NSString *)str attributes:(NSDictionary<NSAttributedStringKey, id> *)attrs {
|
||||||
|
|
|
||||||
|
|
@ -1,50 +1,49 @@
|
||||||
#import <UIKit/UIKit.h>
|
#import <UIKit/UIKit.h>
|
||||||
#import <LocalAuthentication/LocalAuthentication.h>
|
|
||||||
#import <CaptainHook/CaptainHook.h>
|
|
||||||
#import <Foundation/Foundation.h>
|
#import <Foundation/Foundation.h>
|
||||||
#import <objc/runtime.h>
|
#import <CaptainHook/CaptainHook.h>
|
||||||
#import <dlfcn.h>
|
#import <dlfcn.h>
|
||||||
#import <sys/utsname.h>
|
#import <LocalAuthentication/LocalAuthentication.h>
|
||||||
#import <substrate.h>
|
#import <objc/runtime.h>
|
||||||
#import <rootless.h>
|
#import <rootless.h>
|
||||||
|
#import <substrate.h>
|
||||||
#import "uYouPlusThemes.h" // Hide "Buy Super Thanks" banner (_ASDisplayView)
|
#import <sys/utsname.h>
|
||||||
#import <YouTubeHeader/YTAppDelegate.h> // Activate FLEX
|
#import <YouTubeHeader/ASCollectionElement.h>
|
||||||
#import <YouTubeHeader/YTIMenuConditionalServiceItemRenderer.h>
|
#import <YouTubeHeader/ASCollectionView.h>
|
||||||
#import <YouTubeHeader/YTIPlayerBarDecorationModel.h>
|
#import <YouTubeHeader/ELMCellNode.h>
|
||||||
#import <YouTubeHeader/YTPlayerBarRectangleDecorationView.h>
|
#import <YouTubeHeader/ELMNodeController.h>
|
||||||
#import <YouTubeHeader/YTVideoQualitySwitchOriginalController.h>
|
#import <YouTubeHeader/GPBMessage.h>
|
||||||
#import <YouTubeHeader/YTIGuideResponse.h>
|
#import <YouTubeHeader/YTAppDelegate.h>
|
||||||
#import <YouTubeHeader/YTIGuideResponseSupportedRenderers.h>
|
#import <YouTubeHeader/YTCollectionViewCell.h>
|
||||||
#import <YouTubeHeader/YTIPivotBarSupportedRenderers.h>
|
|
||||||
#import <YouTubeHeader/YTIPivotBarItemRenderer.h>
|
|
||||||
#import <YouTubeHeader/YTIBrowseRequest.h>
|
#import <YouTubeHeader/YTIBrowseRequest.h>
|
||||||
#import <YouTubeHeader/YTIButtonRenderer.h>
|
#import <YouTubeHeader/YTIButtonRenderer.h>
|
||||||
#import <YouTubeHeader/YTIElementRenderer.h>
|
#import <YouTubeHeader/YTIElementRenderer.h>
|
||||||
#import <YouTubeHeader/YTISectionListRenderer.h>
|
|
||||||
#import <YouTubeHeader/YTWatchNextResultsViewController.h>
|
|
||||||
#import <YouTubeHeader/YTPlayerOverlay.h>
|
|
||||||
#import <YouTubeHeader/YTPlayerOverlayProvider.h>
|
|
||||||
#import <YouTubeHeader/YTReelWatchPlaybackOverlayView.h>
|
|
||||||
#import <YouTubeHeader/YTInlinePlayerBarContainerView.h>
|
|
||||||
#import <YouTubeHeader/YTInnerTubeCollectionViewController.h>
|
|
||||||
#import <YouTubeHeader/YTPivotBarItemView.h>
|
|
||||||
#import <YouTubeHeader/YTCollectionViewCell.h>
|
|
||||||
#import <YouTubeHeader/YTIFormattedString.h>
|
#import <YouTubeHeader/YTIFormattedString.h>
|
||||||
#import <YouTubeHeader/GPBMessage.h>
|
#import <YouTubeHeader/YTIGuideResponse.h>
|
||||||
#import <YouTubeHeader/YTIStringRun.h>
|
#import <YouTubeHeader/YTIGuideResponseSupportedRenderers.h>
|
||||||
#import <YouTubeHeader/YTWatchViewController.h>
|
#import <YouTubeHeader/YTIMenuConditionalServiceItemRenderer.h>
|
||||||
|
#import <YouTubeHeader/YTInnerTubeCollectionViewController.h>
|
||||||
|
#import <YouTubeHeader/YTInlinePlayerBarContainerView.h>
|
||||||
|
#import <YouTubeHeader/YTIPivotBarItemRenderer.h>
|
||||||
#import <YouTubeHeader/YTIPivotBarRenderer.h>
|
#import <YouTubeHeader/YTIPivotBarRenderer.h>
|
||||||
|
#import <YouTubeHeader/YTIPivotBarSupportedRenderers.h>
|
||||||
// Hide buttons under the video player by @PoomSmart
|
#import <YouTubeHeader/YTIPlayerBarDecorationModel.h>
|
||||||
#import <YouTubeHeader/ASCollectionElement.h>
|
#import <YouTubeHeader/YTISectionListRenderer.h>
|
||||||
#import <YouTubeHeader/ASCollectionView.h>
|
#import <YouTubeHeader/YTIStringRun.h>
|
||||||
#import <YouTubeHeader/ELMNodeController.h>
|
#import <YouTubeHeader/YTMainAppVideoPlayerOverlayViewController.h>
|
||||||
|
#import <YouTubeHeader/YTMainAppVideoPlayerOverlayView.h>
|
||||||
// YouTube-X
|
#import <YouTubeHeader/YTPlayerBarController.h>
|
||||||
|
#import <YouTubeHeader/YTPlayerBarRectangleDecorationView.h>
|
||||||
|
#import <YouTubeHeader/YTPlayerOverlay.h>
|
||||||
|
#import <YouTubeHeader/YTPlayerOverlayManager.h>
|
||||||
#import <YouTubeHeader/YTReelModel.h>
|
#import <YouTubeHeader/YTReelModel.h>
|
||||||
|
#import <YouTubeHeader/YTReelWatchPlaybackOverlayView.h>
|
||||||
|
#import <YouTubeHeader/YTResponder.h>
|
||||||
|
#import <YouTubeHeader/YTVideoQualitySwitchOriginalController.h>
|
||||||
#import <YouTubeHeader/YTVideoWithContextNode.h>
|
#import <YouTubeHeader/YTVideoWithContextNode.h>
|
||||||
#import <YouTubeHeader/ELMCellNode.h>
|
#import <YouTubeHeader/YTWatchNextResultsViewController.h>
|
||||||
|
#import <YouTubeHeader/YTWatchPullToFullController.h>
|
||||||
|
#import <YouTubeHeader/YTWatchViewController.h>
|
||||||
|
#import "uYouPlusThemes.h" // uYouPlus Themes
|
||||||
|
|
||||||
#define LOC(x) [tweakBundle localizedStringForKey:x value:nil table:nil]
|
#define LOC(x) [tweakBundle localizedStringForKey:x value:nil table:nil]
|
||||||
#define IS_ENABLED(k) [[NSUserDefaults standardUserDefaults] boolForKey:k]
|
#define IS_ENABLED(k) [[NSUserDefaults standardUserDefaults] boolForKey:k]
|
||||||
|
|
@ -55,12 +54,8 @@
|
||||||
#define LOWCONTRASTMODE_CUTOFF_VERSION @"17.38.10" // LowContrastMode (v17.33.2-17.38.10)
|
#define LOWCONTRASTMODE_CUTOFF_VERSION @"17.38.10" // LowContrastMode (v17.33.2-17.38.10)
|
||||||
|
|
||||||
// Always show remaining time in video player - @bhackel
|
// Always show remaining time in video player - @bhackel
|
||||||
@interface YTPlayerBarController : NSObject
|
// Header has been moved to https://github.com/PoomSmart/YouTubeHeader/blob/main/YTPlayerBarController.h
|
||||||
@property(nonatomic, strong) YTInlinePlayerBarContainerView *playerBar;
|
// Header has been moved to https://github.com/PoomSmart/YouTubeHeader/blob/main/YTInlinePlayerBarContainerView.h
|
||||||
@end
|
|
||||||
@interface YTInlinePlayerBarContainerView (uYouEnhanced)
|
|
||||||
@property(nonatomic, assign) BOOL shouldDisplayTimeRemaining;
|
|
||||||
@end
|
|
||||||
|
|
||||||
// IAmYouTube
|
// IAmYouTube
|
||||||
@interface SSOConfiguration : NSObject
|
@interface SSOConfiguration : NSObject
|
||||||
|
|
@ -82,14 +77,10 @@
|
||||||
// Hide Home Tab - @bhackel
|
// Hide Home Tab - @bhackel
|
||||||
@interface YTPivotBarItemViewAccessibilityControl : UIControl
|
@interface YTPivotBarItemViewAccessibilityControl : UIControl
|
||||||
@end
|
@end
|
||||||
@interface YTPivotBarItemView (uYouEnhanced)
|
// YTPivotBarItemView Header has been moved to https://github.com/arichornloverALT/YouTubeHeader/blob/main/YTPivotBarItemView.h
|
||||||
@property (nonatomic, strong) YTPivotBarItemViewAccessibilityControl *hitTarget;
|
|
||||||
@end
|
|
||||||
|
|
||||||
// YTTapToSeek - https://github.com/bhackel/YTTapToSeek
|
// YTTapToSeek - https://github.com/bhackel/YTTapToSeek
|
||||||
@interface YTMainAppVideoPlayerOverlayViewController : UIViewController
|
// YTMainAppVideoPlayerOverlayViewController Header has been moved to https://github.com/arichornloverALT/YouTubeHeader/blob/main/YTMainAppVideoPlayerOverlayViewController.h
|
||||||
- (CGFloat)totalTime;
|
|
||||||
@end
|
|
||||||
|
|
||||||
// Enable Premium logo - @bhackel
|
// Enable Premium logo - @bhackel
|
||||||
@interface YTITopbarLogoRenderer : NSObject
|
@interface YTITopbarLogoRenderer : NSObject
|
||||||
|
|
@ -121,12 +112,7 @@
|
||||||
- (BOOL)hasIcon;
|
- (BOOL)hasIcon;
|
||||||
- (BOOL)hasThumbnail;
|
- (BOOL)hasThumbnail;
|
||||||
@end
|
@end
|
||||||
@interface YTIItemSectionSupportedRenderers (uYouEnhanced)
|
// YTIItemSectionSupportedRenderers Header has been moved to https://github.com/arichornloverALT/YouTubeHeader/blob/main/YTIItemSectionSupportedRenderers.h
|
||||||
@property(readonly, nonatomic) YTICompactLinkRenderer *compactLinkRenderer;
|
|
||||||
@property(readonly, nonatomic) YTICompactListItemRenderer *compactListItemRenderer;
|
|
||||||
- (BOOL)hasCompactLinkRenderer;
|
|
||||||
- (BOOL)hasCompactListItemRenderer;
|
|
||||||
@end
|
|
||||||
@interface YTAppCollectionViewController : YTInnerTubeCollectionViewController
|
@interface YTAppCollectionViewController : YTInnerTubeCollectionViewController
|
||||||
- (void)uYouEnhancedFakePremiumModel:(YTISectionListRenderer *)model;
|
- (void)uYouEnhancedFakePremiumModel:(YTISectionListRenderer *)model;
|
||||||
@end
|
@end
|
||||||
|
|
@ -135,12 +121,13 @@
|
||||||
@end
|
@end
|
||||||
|
|
||||||
// Disable Pull to Full for landscape videos - @bhackel
|
// Disable Pull to Full for landscape videos - @bhackel
|
||||||
@interface YTWatchPullToFullController : NSObject
|
// YTWatchPullToFullController Header has been moved to https://github.com/PoomSmart/YouTubeHeader/blob/main/YTWatchPullToFullController.h
|
||||||
@property(nonatomic, strong) YTWatchViewController *playerViewSource;
|
|
||||||
@end
|
// Fullscreen to the Right (uYouEnhanced Version) - @arichornlover
|
||||||
@interface YTWatchViewController (uYouEnhanced)
|
@interface YTWatchViewController (uYouEnhanced)
|
||||||
@property(nonatomic, strong) YTWatchPullToFullController *pullToFullController;
|
- (UIInterfaceOrientationMask) supportedInterfaceOrientations;
|
||||||
- (NSUInteger)allowedFullScreenOrientations;
|
- (UIInterfaceOrientation) preferredInterfaceOrientationForPresentation;
|
||||||
|
- (void)forceRightFullscreenOrientation;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
// uYouPlus
|
// uYouPlus
|
||||||
|
|
@ -161,10 +148,6 @@
|
||||||
- (void)confirmAlertDidPressConfirm;
|
- (void)confirmAlertDidPressConfirm;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
@interface YTMainAppControlsOverlayView : UIView
|
|
||||||
@property(readonly, nonatomic) YTQTMButton *watchCollapseButton;
|
|
||||||
@end
|
|
||||||
|
|
||||||
@interface YTTransportControlsButtonView : UIView
|
@interface YTTransportControlsButtonView : UIView
|
||||||
@end
|
@end
|
||||||
|
|
||||||
|
|
@ -194,17 +177,16 @@
|
||||||
// Buttons
|
// Buttons
|
||||||
@interface YTRightNavigationButtons : UIView
|
@interface YTRightNavigationButtons : UIView
|
||||||
- (id)_viewControllerForAncestor;
|
- (id)_viewControllerForAncestor;
|
||||||
@property(readonly, nonatomic) YTQTMButton *searchButton;
|
@property (readonly, nonatomic) NSArray *dynamicButtons;
|
||||||
@property(readonly, nonatomic) YTQTMButton *notificationButton;
|
@property (readonly, nonatomic) NSArray *visibleButtons;
|
||||||
@property(strong, nonatomic) YTQTMButton *sponsorBlockButton;
|
@property (readonly, nonatomic) NSArray *buttons;
|
||||||
@property(strong, nonatomic) YTQTMButton *uYouPlusButton;
|
@property (readonly, nonatomic) YTQTMButton *searchButton;
|
||||||
|
@property (readonly, nonatomic) YTQTMButton *notificationButton;
|
||||||
|
@property (strong, nonatomic) YTQTMButton *sponsorBlockButton;
|
||||||
|
@property (strong, nonatomic) YTQTMButton *settingsButton;
|
||||||
|
- (void)setDynamicButtons:(NSArray *)buttons;
|
||||||
- (void)setLeadingPadding:(CGFloat)arg1;
|
- (void)setLeadingPadding:(CGFloat)arg1;
|
||||||
- (void)uYouPlusRootOptionsAction;
|
- (void)settingsAction;
|
||||||
@end
|
|
||||||
|
|
||||||
@interface YTISlimMetadataButtonSupportedRenderers : NSObject
|
|
||||||
- (id)slimButton_buttonRenderer;
|
|
||||||
- (id)slimMetadataButtonRenderer;
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
// YTSpeed
|
// YTSpeed
|
||||||
|
|
|
||||||
|
|
@ -14,19 +14,6 @@ NSBundle *uYouPlusBundle() {
|
||||||
return bundle;
|
return bundle;
|
||||||
}
|
}
|
||||||
NSBundle *tweakBundle = uYouPlusBundle();
|
NSBundle *tweakBundle = uYouPlusBundle();
|
||||||
|
|
||||||
// uYouPlusSettings.xm
|
|
||||||
static int contrastMode() {
|
|
||||||
NSString *appVersion = [[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleShortVersionString"];
|
|
||||||
NSComparisonResult result1 = [appVersion compare:@"17.33.2" options:NSNumericSearch];
|
|
||||||
NSComparisonResult result2 = [appVersion compare:@"17.38.10" options:NSNumericSearch];
|
|
||||||
|
|
||||||
if (result1 != NSOrderedAscending && result2 != NSOrderedDescending) {
|
|
||||||
return [[NSUserDefaults standardUserDefaults] integerForKey:@"lcm"];
|
|
||||||
} else {
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
//
|
//
|
||||||
|
|
||||||
# pragma mark - Other hooks
|
# pragma mark - Other hooks
|
||||||
|
|
@ -51,19 +38,7 @@ static int contrastMode() {
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
|
|
||||||
// Fixes uYou crash when trying to play video (#1422)
|
// Fixes uYou crash when trying to play video (qnblackcat/#1422) - @Dayanch96
|
||||||
@interface YTVarispeedSwitchController : NSObject
|
|
||||||
@end
|
|
||||||
|
|
||||||
@interface YTPlayerOverlayManager : NSObject
|
|
||||||
@property (nonatomic, assign) float currentPlaybackRate;
|
|
||||||
@property (nonatomic, strong, readonly) YTVarispeedSwitchController *varispeedController;
|
|
||||||
|
|
||||||
- (void)varispeedSwitchController:(YTVarispeedSwitchController *)varispeed didSelectRate:(float)rate;
|
|
||||||
- (void)setCurrentPlaybackRate:(float)rate;
|
|
||||||
- (void)setPlaybackRate:(float)rate;
|
|
||||||
@end
|
|
||||||
|
|
||||||
%hook YTPlayerOverlayManager
|
%hook YTPlayerOverlayManager
|
||||||
%property (nonatomic, assign) float currentPlaybackRate;
|
%property (nonatomic, assign) float currentPlaybackRate;
|
||||||
|
|
||||||
|
|
@ -95,6 +70,11 @@ static int contrastMode() {
|
||||||
- (BOOL)isMonetized { return NO; }
|
- (BOOL)isMonetized { return NO; }
|
||||||
%end
|
%end
|
||||||
|
|
||||||
|
%hook YTAdShieldUtils
|
||||||
|
+ (id)spamSignalsDictionary { return @{}; }
|
||||||
|
+ (id)spamSignalsDictionaryWithoutIDFA { return @{}; }
|
||||||
|
%end
|
||||||
|
|
||||||
%hook YTDataUtils
|
%hook YTDataUtils
|
||||||
+ (id)spamSignalsDictionary { return @{}; }
|
+ (id)spamSignalsDictionary { return @{}; }
|
||||||
+ (id)spamSignalsDictionaryWithoutIDFA { return @{}; }
|
+ (id)spamSignalsDictionaryWithoutIDFA { return @{}; }
|
||||||
|
|
@ -127,6 +107,10 @@ static int contrastMode() {
|
||||||
%hook YTIPlayerResponse
|
%hook YTIPlayerResponse
|
||||||
- (BOOL)isMonetized { return NO; }
|
- (BOOL)isMonetized { return NO; }
|
||||||
%end
|
%end
|
||||||
|
%hook YTAdShieldUtils
|
||||||
|
+ (id)spamSignalsDictionary { return @{}; }
|
||||||
|
+ (id)spamSignalsDictionaryWithoutIDFA { return @{}; }
|
||||||
|
%end
|
||||||
%hook YTDataUtils
|
%hook YTDataUtils
|
||||||
+ (id)spamSignalsDictionary { return @{}; }
|
+ (id)spamSignalsDictionary { return @{}; }
|
||||||
+ (id)spamSignalsDictionaryWithoutIDFA { return @{}; }
|
+ (id)spamSignalsDictionaryWithoutIDFA { return @{}; }
|
||||||
|
|
@ -145,28 +129,44 @@ static int contrastMode() {
|
||||||
%orig;
|
%orig;
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
BOOL isAdString(NSString *description) {
|
NSString *getAdString(NSString *description) {
|
||||||
if ([description containsString:@"brand_promo"]
|
if ([description containsString:@"brand_promo"])
|
||||||
|| [description containsString:@"carousel_footered_layout"]
|
return @"brand_promo";
|
||||||
|| [description containsString:@"carousel_headered_layout"]
|
if ([description containsString:@"carousel_footered_layout"])
|
||||||
|| [description containsString:@"feed_ad_metadata"]
|
return @"carousel_footered_layout";
|
||||||
|| [description containsString:@"full_width_portrait_image_layout"]
|
if ([description containsString:@"carousel_headered_layout"])
|
||||||
|| [description containsString:@"full_width_square_image_layout"]
|
return @"carousel_headered_layout";
|
||||||
|| [description containsString:@"home_video_with_context"]
|
if ([description containsString:@"feed_ad_metadata"])
|
||||||
|| [description containsString:@"landscape_image_wide_button_layout"]
|
return @"feed_ad_metadata";
|
||||||
|| [description containsString:@"product_engagement_panel"]
|
if ([description containsString:@"full_width_portrait_image_layout"])
|
||||||
|| [description containsString:@"product_item"]
|
return @"full_width_portrait_image_layout";
|
||||||
|| [description containsString:@"shelf_header"]
|
if ([description containsString:@"full_width_square_image_layout"])
|
||||||
|| [description containsString:@"square_image_layout"]
|
return @"full_width_square_image_layout";
|
||||||
|| [description containsString:@"text_image_button_layout"]
|
if ([description containsString:@"landscape_image_wide_button_layout"])
|
||||||
|| [description containsString:@"text_search_ad"]
|
return @"landscape_image_wide_button_layout";
|
||||||
|| [description containsString:@"expandable_list"]
|
if ([description containsString:@"post_shelf"])
|
||||||
|| [description containsString:@"expandable_metadata"]
|
return @"post_shelf";
|
||||||
|| [description containsString:@"video_display_full_buttoned_layout"])
|
if ([description containsString:@"product_carousel"])
|
||||||
return YES;
|
return @"product_carousel";
|
||||||
return NO;
|
if ([description containsString:@"product_engagement_panel"])
|
||||||
|
return @"product_engagement_panel";
|
||||||
|
if ([description containsString:@"product_item"])
|
||||||
|
return @"product_item";
|
||||||
|
if ([description containsString:@"statement_banner"])
|
||||||
|
return @"statement_banner";
|
||||||
|
if ([description containsString:@"square_image_layout"])
|
||||||
|
return @"square_image_layout";
|
||||||
|
if ([description containsString:@"text_image_button_layout"])
|
||||||
|
return @"text_image_button_layout";
|
||||||
|
if ([description containsString:@"text_search_ad"])
|
||||||
|
return @"text_search_ad";
|
||||||
|
if ([description containsString:@"video_display_full_layout"])
|
||||||
|
return @"video_display_full_layout";
|
||||||
|
if ([description containsString:@"video_display_full_buttoned_layout"])
|
||||||
|
return @"video_display_full_buttoned_layout";
|
||||||
|
return nil;
|
||||||
}
|
}
|
||||||
NSData *cellDividerData;
|
static __strong NSData *cellDividerData;
|
||||||
%hook YTIElementRenderer
|
%hook YTIElementRenderer
|
||||||
- (NSData *)elementData {
|
- (NSData *)elementData {
|
||||||
NSString *description = [self description];
|
NSString *description = [self description];
|
||||||
|
|
@ -174,7 +174,16 @@ NSData *cellDividerData;
|
||||||
if (!cellDividerData) cellDividerData = %orig;
|
if (!cellDividerData) cellDividerData = %orig;
|
||||||
return cellDividerData;
|
return cellDividerData;
|
||||||
}
|
}
|
||||||
if ([self respondsToSelector:@selector(hasCompatibilityOptions)] && self.hasCompatibilityOptions && self.compatibilityOptions.hasAdLoggingData) return cellDividerData;
|
if (!cellDividerData) return %orig;
|
||||||
|
if ([self respondsToSelector:@selector(hasCompatibilityOptions)] && self.hasCompatibilityOptions && self.compatibilityOptions.hasAdLoggingData) {
|
||||||
|
// HBLogInfo(@"YTX adLogging 1 %@", cellDividerData);
|
||||||
|
return cellDividerData;
|
||||||
|
}
|
||||||
|
NSString *adString = getAdString(description);
|
||||||
|
if (adString) {
|
||||||
|
// HBLogInfo(@"YTX getAdString 1 %@ %@", adString, cellDividerData);
|
||||||
|
return cellDividerData;
|
||||||
|
}
|
||||||
return %orig;
|
return %orig;
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
|
|
@ -188,41 +197,23 @@ NSData *cellDividerData;
|
||||||
YTIItemSectionRenderer *sectionRenderer = renderers.itemSectionRenderer;
|
YTIItemSectionRenderer *sectionRenderer = renderers.itemSectionRenderer;
|
||||||
YTIItemSectionSupportedRenderers *firstObject = [sectionRenderer.contentsArray firstObject];
|
YTIItemSectionSupportedRenderers *firstObject = [sectionRenderer.contentsArray firstObject];
|
||||||
YTIElementRenderer *elementRenderer = firstObject.elementRenderer;
|
YTIElementRenderer *elementRenderer = firstObject.elementRenderer;
|
||||||
|
if ([elementRenderer respondsToSelector:@selector(hasCompatibilityOptions)] && elementRenderer.hasCompatibilityOptions && elementRenderer.compatibilityOptions.hasAdLoggingData) {
|
||||||
|
// HBLogInfo(@"YTX adLogging 2 %@", elementRenderer);
|
||||||
|
return YES;
|
||||||
|
}
|
||||||
NSString *description = [elementRenderer description];
|
NSString *description = [elementRenderer description];
|
||||||
return isAdString(description)
|
NSString *adString = getAdString(description);
|
||||||
|| [description containsString:@"post_shelf"]
|
if (adString) {
|
||||||
|| [description containsString:@"product_carousel"]
|
// HBLogInfo(@"YTX getAdString 2 %@ %@", adString, elementRenderer);
|
||||||
|| [description containsString:@"statement_banner"];
|
return YES;
|
||||||
|
}
|
||||||
|
return NO;
|
||||||
}];
|
}];
|
||||||
[contentsArray removeObjectsAtIndexes:removeIndexes];
|
[contentsArray removeObjectsAtIndexes:removeIndexes];
|
||||||
}
|
}
|
||||||
%orig;
|
%orig;
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
%hook YTWatchNextResultsViewController
|
|
||||||
- (void)loadWithModel:(YTISectionListRenderer *)watchNextResults {
|
|
||||||
if ([watchNextResults isKindOfClass:%c(YTISectionListRenderer)]) {
|
|
||||||
NSMutableArray <YTISectionListSupportedRenderers *> *contentsArray = watchNextResults.contentsArray;
|
|
||||||
NSIndexSet *removeIndexes = [contentsArray indexesOfObjectsPassingTest:^BOOL(YTISectionListSupportedRenderers *renderers, NSUInteger idx, BOOL *stop) {
|
|
||||||
if (![renderers isKindOfClass:%c(YTISectionListSupportedRenderers)])
|
|
||||||
return NO;
|
|
||||||
YTIItemSectionRenderer *sectionRenderer = renderers.itemSectionRenderer;
|
|
||||||
YTIItemSectionSupportedRenderers *firstObject = [sectionRenderer.contentsArray firstObject];
|
|
||||||
YTIElementRenderer *elementRenderer = firstObject.elementRenderer;
|
|
||||||
NSString *description = [elementRenderer description];
|
|
||||||
return isAdString(description);
|
|
||||||
}];
|
|
||||||
[contentsArray removeObjectsAtIndexes:removeIndexes];
|
|
||||||
}
|
|
||||||
%orig;
|
|
||||||
}
|
|
||||||
%end
|
|
||||||
%hook _ASDisplayView
|
|
||||||
- (void)didMoveToWindow {
|
|
||||||
%orig();
|
|
||||||
if ([self.accessibilityIdentifier isEqualToString:@"id.products_in_video_with_preview_overlay_badge.view"]) self.hidden = YES;
|
|
||||||
}
|
|
||||||
%end
|
|
||||||
%end
|
%end
|
||||||
|
|
||||||
// Hide YouTube Logo - @dayanch96
|
// Hide YouTube Logo - @dayanch96
|
||||||
|
|
@ -255,7 +246,6 @@ NSData *cellDividerData;
|
||||||
%end
|
%end
|
||||||
%end
|
%end
|
||||||
|
|
||||||
|
|
||||||
// Fix App Group Directory by move it to document directory
|
// Fix App Group Directory by move it to document directory
|
||||||
%hook NSFileManager
|
%hook NSFileManager
|
||||||
- (NSURL *)containerURLForSecurityApplicationGroupIdentifier:(NSString *)groupIdentifier {
|
- (NSURL *)containerURLForSecurityApplicationGroupIdentifier:(NSString *)groupIdentifier {
|
||||||
|
|
@ -310,6 +300,9 @@ NSData *cellDividerData;
|
||||||
- (BOOL)isLandscapeEngagementPanelSwipeRightToDismissEnabled { return YES; } // Swipe right to dismiss the right panel in fullscreen mode
|
- (BOOL)isLandscapeEngagementPanelSwipeRightToDismissEnabled { return YES; } // Swipe right to dismiss the right panel in fullscreen mode
|
||||||
- (BOOL)enableModularPlayerBarController { return NO; } // fixes some of the iSponorBlock problems
|
- (BOOL)enableModularPlayerBarController { return NO; } // fixes some of the iSponorBlock problems
|
||||||
- (BOOL)mainAppCoreClientEnableCairoSettings { return IS_ENABLED(@"newSettingsUI_enabled"); } // New grouped settings UI
|
- (BOOL)mainAppCoreClientEnableCairoSettings { return IS_ENABLED(@"newSettingsUI_enabled"); } // New grouped settings UI
|
||||||
|
- (BOOL)enableIosFloatingMiniplayer { return IS_ENABLED(@"floatingMiniplayer_enabled"); } // Floating Miniplayer
|
||||||
|
- (BOOL)enableIosFloatingMiniplayerSwipeUpToExpand { return IS_ENABLED(@"floatingMiniplayer_enabled"); } // Floating Miniplayer
|
||||||
|
- (BOOL)enableIosFloatingMiniplayerRepositioning { return IS_ENABLED(@"floatingMiniplayer2_enabled"); } // Floating Miniplayer (Repositioning Support, Removes Swiping Up Gesture)
|
||||||
%end
|
%end
|
||||||
|
|
||||||
// Fix Casting: https://github.com/arichornlover/uYouEnhanced/issues/606#issuecomment-2098289942
|
// Fix Casting: https://github.com/arichornlover/uYouEnhanced/issues/606#issuecomment-2098289942
|
||||||
|
|
@ -358,6 +351,21 @@ NSData *cellDividerData;
|
||||||
- (BOOL)savedSettingShouldExpire { return NO; }
|
- (BOOL)savedSettingShouldExpire { return NO; }
|
||||||
%end
|
%end
|
||||||
|
|
||||||
|
// Restore Settings Button in Navigaton Bar - @arichornlover & @bhackel - https://github.com/arichornlover/uYouEnhanced/issues/178
|
||||||
|
/* WILL RESULT IN LOSING THE SETTINGS BUTTON!
|
||||||
|
%hook YTRightNavigationButtons
|
||||||
|
- (id)visibleButtons {
|
||||||
|
Class YTVersionUtilsClass = %c(YTVersionUtils);
|
||||||
|
NSString *appVersion = [YTVersionUtilsClass performSelector:@selector(appVersion)];
|
||||||
|
NSComparisonResult result = [appVersion compare:@"18.35.4" options:NSNumericSearch];
|
||||||
|
if (result == NSOrderedAscending) {
|
||||||
|
return %orig;
|
||||||
|
}
|
||||||
|
return [self dynamicButtons];
|
||||||
|
}
|
||||||
|
%end
|
||||||
|
*/
|
||||||
|
|
||||||
// Hide "Get Youtube Premium" in "You" tab - @bhackel
|
// Hide "Get Youtube Premium" in "You" tab - @bhackel
|
||||||
%group gHidePremiumPromos
|
%group gHidePremiumPromos
|
||||||
%hook YTAppCollectionViewController
|
%hook YTAppCollectionViewController
|
||||||
|
|
@ -551,27 +559,6 @@ NSData *cellDividerData;
|
||||||
- (BOOL)enablePlayerBarForVerticalVideoWhenControlsHiddenInFullscreen { return YES; }
|
- (BOOL)enablePlayerBarForVerticalVideoWhenControlsHiddenInFullscreen { return YES; }
|
||||||
%end
|
%end
|
||||||
|
|
||||||
// YTNoTracking - @arichornlover - https://github.com/arichornlover/YTNoTracking/
|
|
||||||
%hook UIPasteboard
|
|
||||||
- (void)setString:(NSString *)string {
|
|
||||||
// Check if the shared string is a YouTube URL
|
|
||||||
if ([string containsString:@"youtu"]) {
|
|
||||||
NSError *error = NULL;
|
|
||||||
NSRegularExpression *regex = [NSRegularExpression regularExpressionWithPattern:@"youtu\\.be\\/(\\w+)" options:NSRegularExpressionCaseInsensitive error:&error];
|
|
||||||
NSArray *matches = [regex matchesInString:string options:0 range:NSMakeRange(0, [string length])];
|
|
||||||
for (NSTextCheckingResult *match in matches) {
|
|
||||||
NSRange videoIDRange = [match rangeAtIndex:1];
|
|
||||||
NSString *videoID = [string substringWithRange:videoIDRange];
|
|
||||||
NSRange timeRange = [string rangeOfString:@"t=" options:NSBackwardsSearch];
|
|
||||||
NSString *sanitizedURL = [NSString stringWithFormat:@"https://youtu.be/%@%@", videoID, [string substringFromIndex:timeRange.location]];
|
|
||||||
%orig(sanitizedURL);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
%orig(string);
|
|
||||||
}
|
|
||||||
%end
|
|
||||||
|
|
||||||
// YTNoPaidPromo: https://github.com/PoomSmart/YTNoPaidPromo
|
// YTNoPaidPromo: https://github.com/PoomSmart/YTNoPaidPromo
|
||||||
%hook YTMainAppVideoPlayerOverlayViewController
|
%hook YTMainAppVideoPlayerOverlayViewController
|
||||||
- (void)setPaidContentWithPlayerData:(id)data {
|
- (void)setPaidContentWithPlayerData:(id)data {
|
||||||
|
|
@ -591,7 +578,31 @@ NSData *cellDividerData;
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
|
|
||||||
|
// Classic Video Player (Restores the v16.xx.x Video Player Functionality) - @arichornlover
|
||||||
|
// To-do: disabling "Precise Video Scrubbing" https://9to5google.com/2022/06/29/youtube-precise-video-scrubbing/
|
||||||
|
%group gClassicVideoPlayer
|
||||||
|
%hook YTColdConfig
|
||||||
|
- (BOOL)isPinchToEnterFullscreenEnabled { return YES; } // Restore Pinch-to-fullscreen
|
||||||
|
- (BOOL)deprecateTabletPinchFullscreenGestures { return NO; } // Restore Pinch-to-fullscreen
|
||||||
|
%end
|
||||||
|
%hook YTHotConfig
|
||||||
|
- (BOOL)isTabletFullscreenSwipeGesturesEnabled { return NO; } // Disable Swipe-to-fullscreen (iPad)
|
||||||
|
%end
|
||||||
|
%end
|
||||||
|
|
||||||
// Fix LowContrastMode - @arichornlover
|
// Fix LowContrastMode - @arichornlover
|
||||||
|
static int contrastMode() {
|
||||||
|
NSString *appVersion = [[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleShortVersionString"];
|
||||||
|
NSComparisonResult result1 = [appVersion compare:@"17.33.2" options:NSNumericSearch];
|
||||||
|
NSComparisonResult result2 = [appVersion compare:@"17.38.10" options:NSNumericSearch];
|
||||||
|
|
||||||
|
if (result1 != NSOrderedAscending && result2 != NSOrderedDescending) {
|
||||||
|
return [[NSUserDefaults standardUserDefaults] integerForKey:@"lcm"];
|
||||||
|
} else {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
%group gFixLowContrastMode
|
%group gFixLowContrastMode
|
||||||
%hook NSUserDefaults
|
%hook NSUserDefaults
|
||||||
- (NSInteger)integerForKey:(NSString *)defaultName {
|
- (NSInteger)integerForKey:(NSString *)defaultName {
|
||||||
|
|
@ -631,7 +642,7 @@ NSData *cellDividerData;
|
||||||
*/
|
*/
|
||||||
%end
|
%end
|
||||||
|
|
||||||
// Disable Modern/Rounded Buttons (_ASDisplayView Version's not included) - @arichornlover
|
// Disable Modern/Rounded Buttons (_ASDisplayView Version's not supported) - @arichornlover
|
||||||
%group gDisableModernButtons
|
%group gDisableModernButtons
|
||||||
%hook YTQTMButton // Disable Modern/Rounded Buttons
|
%hook YTQTMButton // Disable Modern/Rounded Buttons
|
||||||
+ (BOOL)buttonModernizationEnabled { return NO; }
|
+ (BOOL)buttonModernizationEnabled { return NO; }
|
||||||
|
|
@ -653,15 +664,29 @@ NSData *cellDividerData;
|
||||||
- (BOOL)cxClientEnableModernizedActionSheet { return NO; }
|
- (BOOL)cxClientEnableModernizedActionSheet { return NO; }
|
||||||
- (BOOL)enableClientShortsSheetsModernization { return NO; }
|
- (BOOL)enableClientShortsSheetsModernization { return NO; }
|
||||||
- (BOOL)enableTimestampModernizationForNative { return NO; }
|
- (BOOL)enableTimestampModernizationForNative { return NO; }
|
||||||
- (BOOL)modernizeElementsTextColor { return NO; }
|
- (BOOL)mainAppCoreClientEnableModernIaFeedStretchBottom { return NO; }
|
||||||
- (BOOL)modernizeElementsBgColor { return NO; }
|
- (BOOL)mainAppCoreClientEnableModernIaFrostedBottomBar { return NO; }
|
||||||
|
- (BOOL)mainAppCoreClientEnableModernIaFrostedPivotBar { return NO; }
|
||||||
|
- (BOOL)mainAppCoreClientEnableModernIaFrostedPivotBarUpdatedBackdrop { return NO; }
|
||||||
|
- (BOOL)mainAppCoreClientEnableModernIaFrostedTopBar { return NO; }
|
||||||
|
- (BOOL)mainAppCoreClientEnableModernIaOpacityPivotBar { return NO; }
|
||||||
|
- (BOOL)mainAppCoreClientEnableModernIaTopAndBottomBarIconRefresh { return NO; }
|
||||||
|
- (BOOL)mainAppCoreClientEnableModernizedBedtimeReminderU18DefaultSettings { return NO; }
|
||||||
|
- (BOOL)modernizeCameoNavbar { return NO; }
|
||||||
- (BOOL)modernizeCollectionLockups { return NO; }
|
- (BOOL)modernizeCollectionLockups { return NO; }
|
||||||
|
- (BOOL)modernizeCollectionLockupsShowVideoCount { return NO; }
|
||||||
|
- (BOOL)modernizeElementsBgColor { return NO; }
|
||||||
|
- (BOOL)modernizeElementsTextColor { return NO; }
|
||||||
|
- (BOOL)postsCreatorClientEnableModernButtonsUi { return NO; }
|
||||||
|
- (BOOL)pullToFullModernEdu { return NO; }
|
||||||
|
- (BOOL)showModernMiniplayerRedesign { return NO; }
|
||||||
- (BOOL)uiSystemsClientGlobalConfigEnableModernButtonsForNative { return NO; }
|
- (BOOL)uiSystemsClientGlobalConfigEnableModernButtonsForNative { return NO; }
|
||||||
- (BOOL)uiSystemsClientGlobalConfigIosEnableModernTabsForNative { return NO; }
|
- (BOOL)uiSystemsClientGlobalConfigIosEnableModernTabsForNative { return NO; }
|
||||||
- (BOOL)uiSystemsClientGlobalConfigIosEnableEpUxUpdates { return NO; }
|
|
||||||
- (BOOL)uiSystemsClientGlobalConfigIosEnableSheetsUxUpdates { return NO; }
|
|
||||||
- (BOOL)uiSystemsClientGlobalConfigIosEnableSnackbarModernization { return NO; }
|
- (BOOL)uiSystemsClientGlobalConfigIosEnableSnackbarModernization { return NO; }
|
||||||
|
- (BOOL)uiSystemsClientGlobalConfigModernizeNativeBgColor { return NO; }
|
||||||
|
- (BOOL)uiSystemsClientGlobalConfigModernizeNativeTextColor { return NO; }
|
||||||
// Disable Rounded Content
|
// Disable Rounded Content
|
||||||
|
- (BOOL)enableIosFloatingMiniplayerRoundedCornerRadius { return YES; }
|
||||||
- (BOOL)iosDownloadsPageRoundedThumbs { return NO; }
|
- (BOOL)iosDownloadsPageRoundedThumbs { return NO; }
|
||||||
- (BOOL)iosRoundedSearchBarSuggestZeroPadding { return NO; }
|
- (BOOL)iosRoundedSearchBarSuggestZeroPadding { return NO; }
|
||||||
- (BOOL)uiSystemsClientGlobalConfigEnableRoundedDialogForNative { return NO; }
|
- (BOOL)uiSystemsClientGlobalConfigEnableRoundedDialogForNative { return NO; }
|
||||||
|
|
@ -713,11 +738,21 @@ NSData *cellDividerData;
|
||||||
%end
|
%end
|
||||||
%end
|
%end
|
||||||
|
|
||||||
// Hide YouTube Heatwaves in Video Player (YouTube v17.19.2-latest) - @level3tjg - https://www.reddit.com/r/jailbreak/comments/v29yvk/
|
// Hide YouTube Heatwaves in Video Player - v17.33.2+ - @arichornlover
|
||||||
%group gHideHeatwaves
|
%group gHideHeatwaves
|
||||||
%hook YTInlinePlayerBarContainerView
|
%hook YTInlinePlayerBarContainerView
|
||||||
- (BOOL)canShowHeatwave { return NO; }
|
- (BOOL)canShowHeatwave { return NO; }
|
||||||
%end
|
%end
|
||||||
|
%hook YTPlayerBarHeatwaveView
|
||||||
|
- (id)initWithFrame:(CGRect)frame heatmap:(id)heat {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
%end
|
||||||
|
%hook YTPlayerBarController
|
||||||
|
- (void)setHeatmap:(id)arg1 {
|
||||||
|
%orig(NULL);
|
||||||
|
}
|
||||||
|
%end
|
||||||
%end
|
%end
|
||||||
|
|
||||||
// YTNoSuggestedVideo - https://github.com/bhackel/YTNoSuggestedVideo
|
// YTNoSuggestedVideo - https://github.com/bhackel/YTNoSuggestedVideo
|
||||||
|
|
@ -816,6 +851,31 @@ NSData *cellDividerData;
|
||||||
%end
|
%end
|
||||||
%end
|
%end
|
||||||
|
|
||||||
|
// Fullscreen to the Right - @arichornlover
|
||||||
|
%group gFullscreenToTheRight
|
||||||
|
%hook YTWatchViewController
|
||||||
|
- (UIInterfaceOrientation)preferredInterfaceOrientationForPresentation {
|
||||||
|
if ([self fullscreen] && UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone) {
|
||||||
|
return UIInterfaceOrientationLandscapeRight;
|
||||||
|
}
|
||||||
|
return %orig;
|
||||||
|
}
|
||||||
|
- (UIInterfaceOrientationMask)supportedInterfaceOrientations {
|
||||||
|
if ([self fullscreen] && UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone) {
|
||||||
|
return UIInterfaceOrientationMaskLandscape;
|
||||||
|
}
|
||||||
|
return %orig;
|
||||||
|
}
|
||||||
|
%new
|
||||||
|
- (void)forceRightFullscreenOrientation {
|
||||||
|
if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone) {
|
||||||
|
NSNumber *value = [NSNumber numberWithInt:UIInterfaceOrientationLandscapeRight];
|
||||||
|
[[UIDevice currentDevice] setValue:value forKey:@"orientation"];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
%end
|
||||||
|
%end
|
||||||
|
|
||||||
// Disable Double tap to skip chapter - @bhackel
|
// Disable Double tap to skip chapter - @bhackel
|
||||||
%hook YTDoubleTapToSeekController
|
%hook YTDoubleTapToSeekController
|
||||||
- (void)didTwoFingerDoubleTap:(id)arg1 {
|
- (void)didTwoFingerDoubleTap:(id)arg1 {
|
||||||
|
|
@ -826,7 +886,6 @@ NSData *cellDividerData;
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
|
|
||||||
|
|
||||||
// Disable snap to chapter
|
// Disable snap to chapter
|
||||||
%hook YTSegmentableInlinePlayerBarView
|
%hook YTSegmentableInlinePlayerBarView
|
||||||
- (void)didMoveToWindow {
|
- (void)didMoveToWindow {
|
||||||
|
|
@ -837,7 +896,6 @@ NSData *cellDividerData;
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
|
|
||||||
|
|
||||||
// Disable Pinch to zoom
|
// Disable Pinch to zoom
|
||||||
%hook YTColdConfig
|
%hook YTColdConfig
|
||||||
- (BOOL)videoZoomFreeZoomEnabledGlobalConfig {
|
- (BOOL)videoZoomFreeZoomEnabledGlobalConfig {
|
||||||
|
|
@ -1006,7 +1064,9 @@ NSData *cellDividerData;
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
|
|
||||||
// Hide Fullscreen Button - @arichornlover - PoomSmart's Newer Version of the *YouQuality* tweak breaks when enabling this
|
/*
|
||||||
|
// LEGACY VERSION ⚠️
|
||||||
|
// Hide Fullscreen Button - @arichornlover - PoomSmart's 1.2.0+ Versions of the *YouQuality* tweak makes the button invisible when enabling this
|
||||||
%hook YTInlinePlayerBarContainerView
|
%hook YTInlinePlayerBarContainerView
|
||||||
- (void)layoutSubviews {
|
- (void)layoutSubviews {
|
||||||
%orig;
|
%orig;
|
||||||
|
|
@ -1023,6 +1083,18 @@ NSData *cellDividerData;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
|
*/
|
||||||
|
|
||||||
|
// NEW VERSION
|
||||||
|
// Hide Fullscreen Button - @arichornlover
|
||||||
|
%group gHideFullscreenButton
|
||||||
|
%hook YTInlinePlayerBarContainerView
|
||||||
|
- (BOOL)fullscreenButtonDisabled { return YES; }
|
||||||
|
- (BOOL)canShowFullscreenButton { return NO; }
|
||||||
|
- (BOOL)canShowFullscreenButtonExperimental { return NO; }
|
||||||
|
// - (void)setFullscreenButtonDisabled:(BOOL) // Uncomment and might implement this if needed - @arichornlover
|
||||||
|
%end
|
||||||
|
%end
|
||||||
|
|
||||||
// Hide HUD Messages
|
// Hide HUD Messages
|
||||||
%hook YTHUDMessageView
|
%hook YTHUDMessageView
|
||||||
|
|
@ -1037,7 +1109,7 @@ NSData *cellDividerData;
|
||||||
return IS_ENABLED(@"hideChannelWatermark_enabled") ? NO : %orig;
|
return IS_ENABLED(@"hideChannelWatermark_enabled") ? NO : %orig;
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
// Hide Channel Watermark (for Old YouTube Versions / Backwards Compatibility)
|
// Hide Channel Watermark (for Backwards Compatibility)
|
||||||
%hook YTAnnotationsViewController
|
%hook YTAnnotationsViewController
|
||||||
- (void)loadFeaturedChannelWatermark {
|
- (void)loadFeaturedChannelWatermark {
|
||||||
if (IS_ENABLED(@"hideChannelWatermark_enabled")) {}
|
if (IS_ENABLED(@"hideChannelWatermark_enabled")) {}
|
||||||
|
|
@ -1219,31 +1291,17 @@ NSData *cellDividerData;
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
|
|
||||||
/*
|
/* DISABLED DUE TO CONFLICTS
|
||||||
// Hide Shorts Cells - @PoomSmart, @iCrazeiOS & @Dayanch96
|
// Hide Community Posts - @michael-winay, @arichornlover, @iCrazeiOS @PoomSmart & @Dayanch96
|
||||||
%hook YTIElementRenderer
|
%hook YTIElementRenderer
|
||||||
- (NSData *)elementData {
|
- (NSData *)elementData {
|
||||||
NSString *description = [self description];
|
NSString *description = [self description];
|
||||||
if ([NSUserDefaults.standardUserDefaults boolForKey:@"removeShortsCell"]) { // uYou (Hide Shorts Cells)
|
|
||||||
if ([description containsString:@"shorts_shelf.eml"] || [description containsString:@"#shorts"] || [description containsString:@"shorts_video_cell.eml"] || [description containsString:@"6Shorts"]) {
|
|
||||||
if (![description containsString:@"history*"]) {
|
|
||||||
if (!cellDividerData) cellDividerData = %orig;
|
|
||||||
return cellDividerData;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// Hide Community Posts @michael-winay & @arichornlover
|
|
||||||
if (IS_ENABLED(@"hideCommunityPosts_enabled")) {
|
if (IS_ENABLED(@"hideCommunityPosts_enabled")) {
|
||||||
if ([description containsString:@"post_base_wrapper.eml"]) {
|
if ([description containsString:@"post_base_wrapper.eml"]) {
|
||||||
if (!cellDividerData) cellDividerData = %orig;
|
if (!cellDividerData) cellDividerData = [NSData dataWithBytes:cellDividerDataBytes length:cellDividerDataBytesLength];
|
||||||
return cellDividerData;
|
return cellDividerData;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// etc. - @Dayanch96
|
|
||||||
BOOL hasShorts = ([description containsString:@"shorts_shelf.eml"] || [description containsString:@"shorts_video_cell.eml"] || [description containsString:@"6Shorts"]) && ![description containsString:@"history*"];
|
|
||||||
BOOL hasShortsInHistory = [description containsString:@"compact_video.eml"] && [description containsString:@"youtube_shorts_"];
|
|
||||||
|
|
||||||
if (hasShorts || hasShortsInHistory) return cellDividerData;
|
|
||||||
return %orig;
|
return %orig;
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
|
|
@ -1258,21 +1316,22 @@ NSData *cellDividerData;
|
||||||
color = [UIColor redColor];
|
color = [UIColor redColor];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Hide the Button Containers under the Video Player - 17.33.2 and up - @arichornlover
|
// Hide the Button Containers under the Video Player - 17.33.2 and up - @arichornlover
|
||||||
if (IS_ENABLED(@"hideButtonContainers_enabled")) {
|
if (IS_ENABLED(@"hideButtonContainers_enabled")) {
|
||||||
if ([description containsString:@"id.video.like.button"] ||
|
if ([description containsString:@"id.video.like.button"] ||
|
||||||
[description containsString:@"id.video.dislike.button"] ||
|
[description containsString:@"id.video.dislike.button"] ||
|
||||||
[description containsString:@"id.video.share.button"] ||
|
[description containsString:@"id.video.share.button"] ||
|
||||||
[description containsString:@"id.video.remix.button"] ||
|
[description containsString:@"id.video.remix.button"] ||
|
||||||
[description containsString:@"id.ui.add_to.offline.button"]) {
|
[description containsString:@"id.ui.add_to.offline.button"]) {
|
||||||
color = [UIColor clearColor];
|
// self.hidden = YES;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
%orig(color);
|
%orig(color);
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
|
|
||||||
// Hide the (Connect / Thanks / Save / Report) Buttons under the Video Player - 17.33.2 and up - @arichornlover (inspired by @PoomSmart's version) LEGACY METHOD ⚠️
|
// LEGACY VERSION ⚠️
|
||||||
|
// Hide the (Connect / Thanks / Save / Report) Buttons under the Video Player - 17.33.2 and up - @arichornlover (inspired by @PoomSmart's version)
|
||||||
%hook _ASDisplayView
|
%hook _ASDisplayView
|
||||||
- (void)layoutSubviews {
|
- (void)layoutSubviews {
|
||||||
%orig;
|
%orig;
|
||||||
|
|
@ -1295,11 +1354,12 @@ NSData *cellDividerData;
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
|
|
||||||
|
// UPDATED VERSION
|
||||||
// Hide the (Connect / Share / Remix / Thanks / Download / Clip / Save / Report) Buttons under the Video Player - 17.33.2 and up - @PoomSmart (inspired by @arichornlover) - METHOD BROKE Server-Side on May 14th 2024
|
// Hide the (Connect / Share / Remix / Thanks / Download / Clip / Save / Report) Buttons under the Video Player - 17.33.2 and up - @PoomSmart (inspired by @arichornlover) - METHOD BROKE Server-Side on May 14th 2024
|
||||||
static BOOL findCell(ASNodeController *nodeController, NSArray <NSString *> *identifiers) {
|
static BOOL findCell(ASNodeController *nodeController, NSArray <NSString *> *identifiers) {
|
||||||
for (id child in [nodeController children]) {
|
for (id child in [nodeController children]) {
|
||||||
if ([child isKindOfClass:%c(ELMNodeController)]) {
|
if ([child isKindOfClass:%c(ELMNodeController)]) {
|
||||||
NSArray <ELMComponent *> *elmChildren = [(ELMNodeController *)child children];
|
NSArray <ELMComponent *> *elmChildren = [(ELMNodeController * _Nullable)child children];
|
||||||
for (ELMComponent *elmChild in elmChildren) {
|
for (ELMComponent *elmChild in elmChildren) {
|
||||||
for (NSString *identifier in identifiers) {
|
for (NSString *identifier in identifiers) {
|
||||||
if ([[elmChild description] containsString:identifier])
|
if ([[elmChild description] containsString:identifier])
|
||||||
|
|
@ -1309,8 +1369,8 @@ static BOOL findCell(ASNodeController *nodeController, NSArray <NSString *> *ide
|
||||||
}
|
}
|
||||||
|
|
||||||
if ([child isKindOfClass:%c(ASNodeController)]) {
|
if ([child isKindOfClass:%c(ASNodeController)]) {
|
||||||
ASDisplayNode *childNode = ((ASNodeController *)child).node; // ELMContainerNode
|
ASDisplayNode *childNode = ((ASNodeController * _Nullable)child).node; // ELMContainerNode
|
||||||
NSArray *yogaChildren = childNode.yogaChildren;
|
NSArray<id> *yogaChildren = childNode.yogaChildren;
|
||||||
for (ASDisplayNode *displayNode in yogaChildren) {
|
for (ASDisplayNode *displayNode in yogaChildren) {
|
||||||
if ([identifiers containsObject:displayNode.accessibilityIdentifier])
|
if ([identifiers containsObject:displayNode.accessibilityIdentifier])
|
||||||
return YES;
|
return YES;
|
||||||
|
|
@ -1326,7 +1386,7 @@ static BOOL findCell(ASNodeController *nodeController, NSArray <NSString *> *ide
|
||||||
|
|
||||||
%hook ASCollectionView // This stopped working on May 14th 2024 due to a Server-Side Change from YouTube.
|
%hook ASCollectionView // This stopped working on May 14th 2024 due to a Server-Side Change from YouTube.
|
||||||
|
|
||||||
- (CGSize)sizeForElement:(ASCollectionElement *)element {
|
- (CGSize)sizeForElement:(ASCollectionElement * _Nullable)element {
|
||||||
if ([self.accessibilityIdentifier isEqualToString:@"id.video.scrollable_action_bar"]) {
|
if ([self.accessibilityIdentifier isEqualToString:@"id.video.scrollable_action_bar"]) {
|
||||||
ASCellNode *node = [element node];
|
ASCellNode *node = [element node];
|
||||||
ASNodeController *nodeController = [node controller];
|
ASNodeController *nodeController = [node controller];
|
||||||
|
|
@ -1463,19 +1523,6 @@ static BOOL findCell(ASNodeController *nodeController, NSArray <NSString *> *ide
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
|
|
||||||
// %hook YTSectionListViewController
|
|
||||||
// - (void)loadWithModel:(YTISectionListRenderer *)model {
|
|
||||||
// NSMutableArray <YTISectionListSupportedRenderers *> *contentsArray = model.contentsArray;
|
|
||||||
// NSIndexSet *removeIndexes = [contentsArray indexesOfObjectsPassingTest:^BOOL(YTISectionListSupportedRenderers *renderers, NSUInteger idx, BOOL *stop) {
|
|
||||||
// YTIItemSectionRenderer *sectionRenderer = renderers.itemSectionRenderer;
|
|
||||||
// YTIItemSectionSupportedRenderers *firstObject = [sectionRenderer.contentsArray firstObject];
|
|
||||||
// return firstObject.hasPromotedVideoRenderer || firstObject.hasCompactPromotedVideoRenderer || firstObject.hasPromotedVideoInlineMutedRenderer;
|
|
||||||
// }];
|
|
||||||
// [contentsArray removeObjectsAtIndexes:removeIndexes];
|
|
||||||
// %orig;
|
|
||||||
// }
|
|
||||||
// %end
|
|
||||||
|
|
||||||
// Disable hints - https://github.com/LillieH001/YouTube-Reborn/blob/v4/
|
// Disable hints - https://github.com/LillieH001/YouTube-Reborn/blob/v4/
|
||||||
%group gDisableHints
|
%group gDisableHints
|
||||||
%hook YTSettings
|
%hook YTSettings
|
||||||
|
|
@ -1518,7 +1565,7 @@ static BOOL findCell(ASNodeController *nodeController, NSArray <NSString *> *ide
|
||||||
%end
|
%end
|
||||||
|
|
||||||
// Hide the chip bar under the video player?
|
// Hide the chip bar under the video player?
|
||||||
// %hook YTChipCloudCell //
|
// %hook YTChipCloudCell
|
||||||
// - (void)didMoveToWindow {
|
// - (void)didMoveToWindow {
|
||||||
// %orig;
|
// %orig;
|
||||||
// self.hidden = YES;
|
// self.hidden = YES;
|
||||||
|
|
@ -1583,7 +1630,7 @@ static BOOL findCell(ASNodeController *nodeController, NSArray <NSString *> *ide
|
||||||
%end
|
%end
|
||||||
%hook UIKBTree
|
%hook UIKBTree
|
||||||
- (long long)nativeIdiom {
|
- (long long)nativeIdiom {
|
||||||
return NO;
|
return YES;
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
%hook UIKBRenderer
|
%hook UIKBRenderer
|
||||||
|
|
@ -1654,6 +1701,9 @@ static BOOL findCell(ASNodeController *nodeController, NSArray <NSString *> *ide
|
||||||
if (IS_ENABLED(@"portraitFullscreen_enabled")) {
|
if (IS_ENABLED(@"portraitFullscreen_enabled")) {
|
||||||
%init(gPortraitFullscreen);
|
%init(gPortraitFullscreen);
|
||||||
}
|
}
|
||||||
|
if (IS_ENABLED(@"fullscreenToTheRight_enabled")) {
|
||||||
|
%init(gFullscreenToTheRight);
|
||||||
|
}
|
||||||
if (IS_ENABLED(@"hideFullscreenActions_enabled")) {
|
if (IS_ENABLED(@"hideFullscreenActions_enabled")) {
|
||||||
%init(hideFullscreenActions);
|
%init(hideFullscreenActions);
|
||||||
}
|
}
|
||||||
|
|
@ -1672,6 +1722,9 @@ static BOOL findCell(ASNodeController *nodeController, NSArray <NSString *> *ide
|
||||||
if (IS_ENABLED(@"noVideosInFullscreen_enabled")) {
|
if (IS_ENABLED(@"noVideosInFullscreen_enabled")) {
|
||||||
%init(gNoVideosInFullscreen);
|
%init(gNoVideosInFullscreen);
|
||||||
}
|
}
|
||||||
|
if (IS_ENABLED(@"classicVideoPlayer_enabled")) {
|
||||||
|
%init(gClassicVideoPlayer);
|
||||||
|
}
|
||||||
if (IS_ENABLED(@"fixLowContrastMode_enabled")) {
|
if (IS_ENABLED(@"fixLowContrastMode_enabled")) {
|
||||||
%init(gFixLowContrastMode);
|
%init(gFixLowContrastMode);
|
||||||
}
|
}
|
||||||
|
|
@ -1790,6 +1843,7 @@ static BOOL findCell(ASNodeController *nodeController, NSArray <NSString *> *ide
|
||||||
[[NSUserDefaults standardUserDefaults] setBool:NO forKey:@"removeYouTubeAds"];
|
[[NSUserDefaults standardUserDefaults] setBool:NO forKey:@"removeYouTubeAds"];
|
||||||
}
|
}
|
||||||
if (![allKeys containsObject:@"uYouAdBlockingWorkaround_enabled"]) {
|
if (![allKeys containsObject:@"uYouAdBlockingWorkaround_enabled"]) {
|
||||||
|
[[NSUserDefaults standardUserDefaults] setBool:NO forKey:@"uYouAdBlockingWorkaroundLite_enabled"];
|
||||||
[[NSUserDefaults standardUserDefaults] setBool:YES forKey:@"uYouAdBlockingWorkaround_enabled"];
|
[[NSUserDefaults standardUserDefaults] setBool:YES forKey:@"uYouAdBlockingWorkaround_enabled"];
|
||||||
[[NSUserDefaults standardUserDefaults] setBool:NO forKey:@"removeYouTubeAds"];
|
[[NSUserDefaults standardUserDefaults] setBool:NO forKey:@"removeYouTubeAds"];
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,10 @@
|
||||||
|
#import <UIKit/UIActivityViewController.h>
|
||||||
|
#import <YouTubeHeader/YTUIUtils.h>
|
||||||
#import <YouTubeHeader/YTColorPalette.h>
|
#import <YouTubeHeader/YTColorPalette.h>
|
||||||
#import <YouTubeHeader/YTCommonColorPalette.h>
|
#import <YouTubeHeader/YTCommonColorPalette.h>
|
||||||
|
#import "Tweaks/protobuf/objectivec/GPBDescriptor.h"
|
||||||
|
#import "Tweaks/protobuf/objectivec/GPBUnknownField.h"
|
||||||
|
#import "Tweaks/protobuf/objectivec/GPBUnknownFieldSet.h"
|
||||||
#import "uYouPlus.h"
|
#import "uYouPlus.h"
|
||||||
|
|
||||||
@interface PlayerManager : NSObject
|
@interface PlayerManager : NSObject
|
||||||
|
|
@ -53,3 +58,39 @@
|
||||||
@interface UILabel (uYou)
|
@interface UILabel (uYou)
|
||||||
+ (id)_defaultColor;
|
+ (id)_defaultColor;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
|
// YouTube Native Share Headers - https://github.com/jkhsjdhjs/youtube-native-share - @jkhsjdhjs
|
||||||
|
@interface CustomGPBMessage : GPBMessage
|
||||||
|
+ (instancetype)deserializeFromString:(NSString*)string;
|
||||||
|
@end
|
||||||
|
|
||||||
|
// @interface YTICommand : GPBMessage
|
||||||
|
// @end
|
||||||
|
|
||||||
|
@interface ELMPBCommand : GPBMessage
|
||||||
|
@end
|
||||||
|
|
||||||
|
@interface ELMPBShowActionSheetCommand : GPBMessage
|
||||||
|
@property (nonatomic, strong, readwrite) ELMPBCommand *onAppear;
|
||||||
|
@property (nonatomic, assign, readwrite) BOOL hasOnAppear;
|
||||||
|
@end
|
||||||
|
|
||||||
|
@interface YTIUpdateShareSheetCommand
|
||||||
|
@property (nonatomic, assign, readwrite) BOOL hasSerializedShareEntity;
|
||||||
|
@property (nonatomic, copy, readwrite) NSString *serializedShareEntity;
|
||||||
|
+ (GPBExtensionDescriptor*)updateShareSheetCommand;
|
||||||
|
@end
|
||||||
|
|
||||||
|
@interface YTIInnertubeCommandExtensionRoot
|
||||||
|
+ (GPBExtensionDescriptor*)innertubeCommand;
|
||||||
|
@end
|
||||||
|
|
||||||
|
@interface YTAccountScopedCommandResponderEvent
|
||||||
|
@property (nonatomic, strong, readwrite) YTICommand *command;
|
||||||
|
@end
|
||||||
|
|
||||||
|
@interface YTIShareEntityEndpoint
|
||||||
|
@property (nonatomic, assign, readwrite) BOOL hasSerializedShareEntity;
|
||||||
|
@property (nonatomic, copy, readwrite) NSString *serializedShareEntity;
|
||||||
|
+ (GPBExtensionDescriptor*)shareEntityEndpoint;
|
||||||
|
@end
|
||||||
|
|
|
||||||
|
|
@ -91,6 +91,140 @@ static void repositionCreateTab(YTIGuideResponse *response) {
|
||||||
}
|
}
|
||||||
%end
|
%end
|
||||||
|
|
||||||
|
// YouTube Native Share - https://github.com/jkhsjdhjs/youtube-native-share - @jkhsjdhjs
|
||||||
|
typedef NS_ENUM(NSInteger, ShareEntityType) {
|
||||||
|
ShareEntityFieldVideo = 1,
|
||||||
|
ShareEntityFieldPlaylist = 2,
|
||||||
|
ShareEntityFieldChannel = 3,
|
||||||
|
ShareEntityFieldClip = 8
|
||||||
|
};
|
||||||
|
|
||||||
|
static inline NSString* extractIdWithFormat(GPBUnknownFieldSet *fields, NSInteger fieldNumber, NSString *format) {
|
||||||
|
if (![fields hasField:fieldNumber])
|
||||||
|
return nil;
|
||||||
|
GPBUnknownField *idField = [fields getField:fieldNumber];
|
||||||
|
if ([idField.lengthDelimitedList count] != 1)
|
||||||
|
return nil;
|
||||||
|
NSString *id = [[NSString alloc] initWithData:[idField.lengthDelimitedList firstObject] encoding:NSUTF8StringEncoding];
|
||||||
|
return [NSString stringWithFormat:format, id];
|
||||||
|
}
|
||||||
|
|
||||||
|
static BOOL showNativeShareSheet(NSString *serializedShareEntity) {
|
||||||
|
GPBMessage *shareEntity = [%c(GPBMessage) deserializeFromString:serializedShareEntity];
|
||||||
|
GPBUnknownFieldSet *fields = shareEntity.unknownFields;
|
||||||
|
NSString *shareUrl;
|
||||||
|
|
||||||
|
if ([fields hasField:ShareEntityFieldClip]) {
|
||||||
|
GPBUnknownField *shareEntityClip = [fields getField:ShareEntityFieldClip];
|
||||||
|
if ([shareEntityClip.lengthDelimitedList count] != 1)
|
||||||
|
return FALSE;
|
||||||
|
GPBMessage *clipMessage = [%c(GPBMessage) parseFromData:[shareEntityClip.lengthDelimitedList firstObject] error:nil];
|
||||||
|
shareUrl = extractIdWithFormat(clipMessage.unknownFields, 1, @"https://youtube.com/clip/%@");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!shareUrl)
|
||||||
|
shareUrl = extractIdWithFormat(fields, ShareEntityFieldChannel, @"https://youtube.com/channel/%@");
|
||||||
|
|
||||||
|
if (!shareUrl) {
|
||||||
|
shareUrl = extractIdWithFormat(fields, ShareEntityFieldPlaylist, @"%@");
|
||||||
|
if (shareUrl) {
|
||||||
|
if (![shareUrl hasPrefix:@"PL"] && ![shareUrl hasPrefix:@"FL"])
|
||||||
|
shareUrl = [shareUrl stringByAppendingString:@"&playnext=1"];
|
||||||
|
shareUrl = [@"https://youtube.com/playlist?list=" stringByAppendingString:shareUrl];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!shareUrl)
|
||||||
|
shareUrl = extractIdWithFormat(fields, ShareEntityFieldVideo, @"https://youtube.com/watch?v=%@");
|
||||||
|
|
||||||
|
if (!shareUrl)
|
||||||
|
return FALSE;
|
||||||
|
|
||||||
|
UIActivityViewController *activityViewController = [[UIActivityViewController alloc]initWithActivityItems:@[shareUrl] applicationActivities:nil];
|
||||||
|
[[%c(YTUIUtils) topViewControllerForPresenting] presentViewController:activityViewController animated:YES completion:^{}];
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* -------------------- iPad Layout -------------------- */
|
||||||
|
|
||||||
|
%hook YTAccountScopedCommandResponderEvent
|
||||||
|
- (void)send {
|
||||||
|
GPBExtensionDescriptor *shareEntityEndpointDescriptor = [%c(YTIShareEntityEndpoint) shareEntityEndpoint];
|
||||||
|
if (![self.command hasExtension:shareEntityEndpointDescriptor])
|
||||||
|
return %orig;
|
||||||
|
YTIShareEntityEndpoint *shareEntityEndpoint = [self.command getExtension:shareEntityEndpointDescriptor];
|
||||||
|
if (!showNativeShareSheet(shareEntityEndpoint.serializedShareEntity))
|
||||||
|
return %orig;
|
||||||
|
}
|
||||||
|
%end
|
||||||
|
|
||||||
|
/* OLD
|
||||||
|
%hook YTShareRequestViewController
|
||||||
|
- (id)initWithService:(id)_service parentResponder:(id)_parentResponder {
|
||||||
|
id result = %orig;
|
||||||
|
// disable the default share sheet behavior and force the app to call [YTAccountScopedCommandRouter handleCommand] if available
|
||||||
|
if ([_parentResponder respondsToSelector:@selector(handleCommand:entry:fromView:sender:completionBlock:)]) {
|
||||||
|
[_parentResponder handleCommand:nil entry:nil fromView:nil sender:nil completionBlock:nil];
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
%end
|
||||||
|
|
||||||
|
%hook YTAccountScopedCommandRouter
|
||||||
|
- (BOOL)handleCommand:(id)command entry:(id)_entry fromView:(id)_fromView sender:(id)_sender completionBlock:(id)_completionBlock {
|
||||||
|
GPBExtensionDescriptor *shareEntityEndpointDescriptor = [%c(YTIShareEntityEndpoint) shareEntityEndpoint];
|
||||||
|
if (![command hasExtension:shareEntityEndpointDescriptor])
|
||||||
|
return %orig;
|
||||||
|
YTIShareEntityEndpoint *shareEntityEndpoint = [command getExtension:shareEntityEndpointDescriptor];
|
||||||
|
if(!shareEntityEndpoint.hasSerializedShareEntity)
|
||||||
|
return %orig;
|
||||||
|
if (!showNativeShareSheet(shareEntityEndpoint.serializedShareEntity))
|
||||||
|
return %orig;
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
%end
|
||||||
|
*/
|
||||||
|
|
||||||
|
/* EXPERIMENTAL
|
||||||
|
%hook YTAccountScopedCommandRouter
|
||||||
|
- (BOOL)handleCommand:(id)command entry:(id)_entry fromView:(id)_fromView sender:(id)_sender completionBlock:(id)_completionBlock {
|
||||||
|
GPBExtensionDescriptor *shareEntityEndpointDescriptor = [%c(YTIShareEntityEndpoint) shareEntityEndpoint];
|
||||||
|
if (![command hasExtension:shareEntityEndpointDescriptor])
|
||||||
|
return %orig;
|
||||||
|
YTIShareEntityEndpoint *shareEntityEndpoint = [command getExtension:shareEntityEndpointDescriptor];
|
||||||
|
if(!shareEntityEndpoint || !shareEntityEndpoint.hasSerializedShareEntity || !shareEntityEndpoint.serializedShareEntity) {
|
||||||
|
return %orig;
|
||||||
|
}
|
||||||
|
if (!showNativeShareSheet(shareEntityEndpoint.serializedShareEntity)) {
|
||||||
|
return %orig;
|
||||||
|
}
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
%end
|
||||||
|
*/
|
||||||
|
|
||||||
|
/* ------------------- iPhone Layout ------------------- */
|
||||||
|
|
||||||
|
%hook ELMPBShowActionSheetCommand
|
||||||
|
- (void)executeWithCommandContext:(id)_context handler:(id)_handler {
|
||||||
|
if (!self.hasOnAppear)
|
||||||
|
return %orig;
|
||||||
|
GPBExtensionDescriptor *innertubeCommandDescriptor = [%c(YTIInnertubeCommandExtensionRoot) innertubeCommand];
|
||||||
|
if (![self.onAppear hasExtension:innertubeCommandDescriptor])
|
||||||
|
return %orig;
|
||||||
|
YTICommand *innertubeCommand = [self.onAppear getExtension:innertubeCommandDescriptor];
|
||||||
|
GPBExtensionDescriptor *updateShareSheetCommandDescriptor = [%c(YTIUpdateShareSheetCommand) updateShareSheetCommand];
|
||||||
|
if(![innertubeCommand hasExtension:updateShareSheetCommandDescriptor])
|
||||||
|
return %orig;
|
||||||
|
YTIUpdateShareSheetCommand *updateShareSheetCommand = [innertubeCommand getExtension:updateShareSheetCommandDescriptor];
|
||||||
|
if (!updateShareSheetCommand.hasSerializedShareEntity)
|
||||||
|
return %orig;
|
||||||
|
if (!showNativeShareSheet(updateShareSheetCommand.serializedShareEntity))
|
||||||
|
return %orig;
|
||||||
|
}
|
||||||
|
%end
|
||||||
|
|
||||||
// iOS 16 uYou crash fix - @level3tjg: https://github.com/qnblackcat/uYouPlus/pull/224
|
// iOS 16 uYou crash fix - @level3tjg: https://github.com/qnblackcat/uYouPlus/pull/224
|
||||||
// %group iOS16
|
// %group iOS16
|
||||||
// %hook OBPrivacyLinkButton
|
// %hook OBPrivacyLinkButton
|
||||||
|
|
|
||||||
|
|
@ -71,6 +71,20 @@ SWITCH_ITEM3(
|
||||||
);
|
);
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
// Copy Settings KEYS
|
||||||
|
NSArray *copyKeys = @[
|
||||||
|
/* MAIN Player Keys */ @"portraitFullscreen_enabled", @"slideToSeek_enabled", @"YTTapToSeek_enabled", @"doubleTapToSeek_disabled", @"snapToChapter_enabled", @"pinchToZoom_enabled", @"ytMiniPlayer_enabled", @"stockVolumeHUD_enabled", @"disablePullToFull_enabled", @"disableChapterSkip_enabled", @"alwaysShowRemainingTime_enabled", @"disableRemainingTime_enabled",
|
||||||
|
/* MAIN Button Keys */ @"enableShareButton_enabled", @"enableSaveToButton_enabled", @"hideYTMusicButton_enabled", @"hideAutoplaySwitch_enabled", @"hideCC_enabled", @"hideVideoTitle_enabled", @"disableCollapseButton_enabled", @"disableFullscreenButton_enabled", @"hideHUD_enabled", @"hidePaidPromotionCard_enabled", @"hideChannelWatermark_enabled", @"hideVideoPlayerShadowOverlayButtons_enabled", @"hidePreviousAndNextButton_enabled", @"redProgressBar_enabled", @"hideHoverCards_enabled", @"hideRightPanel_enabled", @"hideFullscreenActions_enabled", @"noSuggestedVideo_enabled", @"hideHeatwaves_enabled", @"hideDoubleTapToSeekOverlay_enabled", @"hideOverlayDarkBackground_enabled", @"disableAmbientMode_enabled", @"noVideosInFullscreen_enabled", @"noRelatedWatchNexts_enabled",
|
||||||
|
/* MAIN Shorts Keys */ @"hideBuySuperThanks_enabled", @"hideSubcriptions_enabled", @"disableResumeToShorts_enabled", @"shortsQualityPicker_enabled",
|
||||||
|
/* MAIN Player UI Keys */ @"redSubscribeButton_enabled", @"hideButtonContainers_enabled", @"hideConnectButton_enabled", @"hideShareButton_enabled", @"hideRemixButton_enabled", @"hideThanksButton_enabled", @"hideDownloadButton_enabled", @"hideClipButton_enabled", @"hideSaveToPlaylistButton_enabled", @"hideReportButton_enabled", @"hidePreviewCommentSection_enabled", @"hideCommentSection_enabled",
|
||||||
|
/* MAIN Overlay Keys */ @"disableAccountSection_enabled", @"disableAutoplaySection_enabled", @"disableTryNewFeaturesSection_enabled", @"disableVideoQualityPreferencesSection_enabled", @"disableNotificationsSection_enabled", @"disableManageAllHistorySection_enabled", @"disableYourDataInYouTubeSection_enabled", @"disablePrivacySection_enabled", @"disableLiveChatSection_enabled", @"hidePremiumPromos_enabled",
|
||||||
|
/* MAIN App UI Keys */ @"hideHomeTab_enabled", @"lowContrastMode_enabled", @"classicVideoPlayer_enabled", @"fixLowContrastMode_enabled", @"disableModernButtons_enabled", @"disableRoundedHints_enabled", @"disableModernFlags_enabled", @"ytNoModernUI_enabled", @"enableVersionSpoofer_enabled",
|
||||||
|
/* MAIN Misc Keys */ @"uYouAdBlockingWorkaroundLite_enabled", @"uYouAdBlockingWorkaround_enabled", @"disableAnimatedYouTubeLogo_enabled", @"centerYouTubeLogo_enabled", @"hideYouTubeLogo_enabled", @"ytStartupAnimation_enabled", @"disableHints_enabled", @"stickNavigationBar_enabled", @"hideSponsorBlockButton_enabled", @"hideChipBar_enabled", @"hidePlayNextInQueue_enabled", @"hideCommunityPosts_enabled", @"hideChannelHeaderLinks_enabled", @"iPhoneLayout_enabled", @"bigYTMiniPlayer_enabled", @"reExplore_enabled", @"autoHideHomeBar_enabled", @"hideSubscriptionsNotificationBadge_enabled", @"fixCasting_enabled", @"newSettingsUI_enabled", @"flex_enabled",
|
||||||
|
/* TWEAK uYou Keys */ @"showedWelcomeVC", @"hideShortsTab", @"hideCreateTab", @"hideCastButton", @"relatedVideosAtTheEndOfYTVideos", @"removeYouTubeAds", @"backgroundPlayback", @"disableAgeRestriction", @"iPadLayout", @"noSuggestedVideoAtEnd", @"shortsProgressBar", @"hideShortsCells", @"removeShortsCell", @"startupPage",
|
||||||
|
/* TWEAK iSB Keys */ @"userID", @"apiInstance", @"minimumDuration", @"skipNoticeDuration", @"kShowModifiedTime", @"showSkipNotice", @"showButtonsInPlayer", @"hideStartEndButtonInPlayer", @"showModifiedTime", @"skipAudioNotification", @"enableSkipCountTracking",
|
||||||
|
/* TWEAK YTUHD Keys */ @"EnableVP9", @"AllVP9"
|
||||||
|
];
|
||||||
|
|
||||||
static int contrastMode() {
|
static int contrastMode() {
|
||||||
NSString *appVersion = [[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleShortVersionString"];
|
NSString *appVersion = [[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleShortVersionString"];
|
||||||
NSComparisonResult result1 = [appVersion compare:@"17.33.2" options:NSNumericSearch];
|
NSComparisonResult result1 = [appVersion compare:@"17.33.2" options:NSNumericSearch];
|
||||||
|
|
@ -181,49 +195,29 @@ extern NSBundle *uYouPlusBundle();
|
||||||
|
|
||||||
YTSettingsSectionItem *copySettings = [%c(YTSettingsSectionItem)
|
YTSettingsSectionItem *copySettings = [%c(YTSettingsSectionItem)
|
||||||
itemWithTitle:IS_ENABLED(@"replaceCopyandPasteButtons_enabled") ? LOC(@"EXPORT_SETTINGS") : LOC(@"COPY_SETTINGS")
|
itemWithTitle:IS_ENABLED(@"replaceCopyandPasteButtons_enabled") ? LOC(@"EXPORT_SETTINGS") : LOC(@"COPY_SETTINGS")
|
||||||
titleDescription:IS_ENABLED(@"replaceCopyandPasteButtons_enabled") ? LOC(@"EXPORT_SETTINGS_DESC") : LOC(@"COPY_SETTINGS_DESC")
|
titleDescription:IS_ENABLED(@"replaceCopyandPasteButtons_enabled") ? LOC(@"EXPORT_SETTINGS_DESC") : LOC(@"COPY_SETTINGS_DESC")
|
||||||
accessibilityIdentifier:nil
|
accessibilityIdentifier:nil
|
||||||
detailTextBlock:nil
|
detailTextBlock:nil
|
||||||
selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) {
|
selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) {
|
||||||
if (IS_ENABLED(@"replaceCopyandPasteButtons_enabled")) {
|
if (IS_ENABLED(@"replaceCopyandPasteButtons_enabled")) {
|
||||||
// Export Settings functionality
|
// Export Settings functionality
|
||||||
NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults];
|
NSURL *tempFileURL = [NSURL fileURLWithPath:[NSTemporaryDirectory() stringByAppendingPathComponent:@"exported_settings.txt"]];
|
||||||
NSMutableString *settingsString = [NSMutableString string];
|
NSMutableString *settingsString = [NSMutableString string];
|
||||||
NSArray *copyKeys = @[
|
|
||||||
/* MAIN Player Keys */ @"portraitFullscreen_enabled", @"slideToSeek_enabled", @"YTTapToSeek_enabled", @"doubleTapToSeek_disabled", @"snapToChapter_enabled", @"pinchToZoom_enabled", @"ytMiniPlayer_enabled", @"stockVolumeHUD_enabled", @"disablePullToFull_enabled", @"disableChapterSkip_enabled", @"alwaysShowRemainingTime_enabled", @"disableRemainingTime_enabled",
|
|
||||||
/* MAIN Button Keys */ @"enableShareButton_enabled", @"enableSaveToButton_enabled", @"hideYTMusicButton_enabled", @"hideAutoplaySwitch_enabled", @"hideCC_enabled", @"hideVideoTitle_enabled", @"disableCollapseButton_enabled", @"disableFullscreenButton_enabled", @"hideHUD_enabled", @"hidePaidPromotionCard_enabled", @"hideChannelWatermark_enabled", @"hideVideoPlayerShadowOverlayButtons_enabled", @"hidePreviousAndNextButton_enabled", @"redProgressBar_enabled", @"hideHoverCards_enabled", @"hideRightPanel_enabled", @"hideFullscreenActions_enabled", @"noSuggestedVideo_enabled", @"hideHeatwaves_enabled", @"hideDoubleTapToSeekOverlay_enabled", @"hideOverlayDarkBackground_enabled", @"disableAmbientMode_enabled", @"noVideosInFullscreen_enabled", @"noRelatedWatchNexts_enabled",
|
|
||||||
/* MAIN Shorts Keys */ @"hideBuySuperThanks_enabled", @"hideSubcriptions_enabled", @"disableResumeToShorts_enabled", @"shortsQualityPicker_enabled",
|
|
||||||
/* MAIN Player UI Keys */ @"redSubscribeButton_enabled", @"hideButtonContainers_enabled", @"hideConnectButton_enabled", @"hideShareButton_enabled", @"hideRemixButton_enabled", @"hideThanksButton_enabled", @"hideDownloadButton_enabled", @"hideClipButton_enabled", @"hideSaveToPlaylistButton_enabled", @"hideReportButton_enabled", @"hidePreviewCommentSection_enabled", @"hideCommentSection_enabled",
|
|
||||||
/* MAIN Overlay Keys */ @"disableAccountSection_enabled", @"disableAutoplaySection_enabled", @"disableTryNewFeaturesSection_enabled", @"disableVideoQualityPreferencesSection_enabled", @"disableNotificationsSection_enabled", @"disableManageAllHistorySection_enabled", @"disableYourDataInYouTubeSection_enabled", @"disablePrivacySection_enabled", @"disableLiveChatSection_enabled", @"hidePremiumPromos_enabled",
|
|
||||||
/* MAIN App UI Keys */ @"hideHomeTab_enabled", @"lowContrastMode_enabled", @"fixLowContrastMode_enabled", @"disableModernButtons_enabled", @"disableRoundedHints_enabled", @"disableModernFlags_enabled", @"ytNoModernUI_enabled", @"enableVersionSpoofer_enabled",
|
|
||||||
/* MAIN Misc Keys */ @"uYouAdBlockingWorkaroundLite_enabled", @"uYouAdBlockingWorkaround_enabled", @"disableAnimatedYouTubeLogo_enabled", @"centerYouTubeLogo_enabled", @"hideYouTubeLogo_enabled", @"ytStartupAnimation_enabled", @"disableHints_enabled", @"stickNavigationBar_enabled", @"hideSponsorBlockButton_enabled", @"hideChipBar_enabled", @"hidePlayNextInQueue_enabled", @"hideCommunityPosts_enabled", @"hideChannelHeaderLinks_enabled", @"iPhoneLayout_enabled", @"bigYTMiniPlayer_enabled", @"reExplore_enabled", @"autoHideHomeBar_enabled", @"hideSubscriptionsNotificationBadge_enabled", @"fixCasting_enabled", @"newSettingsUI_enabled", @"flex_enabled",
|
|
||||||
/* TWEAK uYou Keys */ @"hideShortsTab", @"hideCreateTab", @"hideCastButton", @"relatedVideosAtTheEndOfYTVideos", @"disableAgeRestriction", @"removeYouTubeAds", @"noSuggestedVideoAtEnd", @"showedWelcomeVC", @"shortsProgressBar", @"hideShortsCells", @"removeShortsCell", @"startupPage",
|
|
||||||
/* TWEAK YTUHD Keys */ @"EnableVP9", @"AllVP9"];
|
|
||||||
for (NSString *key in copyKeys) {
|
for (NSString *key in copyKeys) {
|
||||||
if ([userDefaults objectForKey:key]) {
|
id value = [[NSUserDefaults standardUserDefaults] objectForKey:key];
|
||||||
NSString *value = [userDefaults objectForKey:key];
|
if (value) {
|
||||||
[settingsString appendFormat:@"%@: %@\n", key, value];
|
[settingsString appendFormat:@"%@: %@\n", key, value];
|
||||||
}
|
}
|
||||||
}
|
|
||||||
NSString *fileName = @"uyouenhanced_settings.txt";
|
|
||||||
NSString *filePath = [NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES)[0] stringByAppendingPathComponent:fileName];
|
|
||||||
if (![settingsString writeToFile:filePath atomically:YES encoding:NSUTF8StringEncoding error:nil]) {
|
|
||||||
NSLog(@"Failed to export settings to file.");
|
|
||||||
}
|
}
|
||||||
|
[settingsString writeToURL:tempFileURL atomically:YES encoding:NSUTF8StringEncoding error:nil];
|
||||||
|
UIDocumentPickerViewController *documentPicker = [[UIDocumentPickerViewController alloc] initWithURL:tempFileURL inMode:UIDocumentPickerModeExportToService];
|
||||||
|
documentPicker.delegate = (id<UIDocumentPickerDelegate>)self;
|
||||||
|
documentPicker.allowsMultipleSelection = NO;
|
||||||
|
[settingsViewController presentViewController:documentPicker animated:YES completion:nil];
|
||||||
} else {
|
} else {
|
||||||
// Copy Settings functionality (default behavior)
|
// Copy Settings functionality (default behavior)
|
||||||
NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults];
|
NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults];
|
||||||
NSMutableString *settingsString = [NSMutableString string];
|
NSMutableString *settingsString = [NSMutableString string];
|
||||||
NSArray *copyKeys = @[
|
|
||||||
/* MAIN Player Keys */ @"portraitFullscreen_enabled", @"slideToSeek_enabled", @"YTTapToSeek_enabled", @"doubleTapToSeek_disabled", @"snapToChapter_enabled", @"pinchToZoom_enabled", @"ytMiniPlayer_enabled", @"stockVolumeHUD_enabled", @"disablePullToFull_enabled", @"disableChapterSkip_enabled", @"alwaysShowRemainingTime_enabled", @"disableRemainingTime_enabled",
|
|
||||||
/* MAIN Button Keys */ @"enableShareButton_enabled", @"enableSaveToButton_enabled", @"hideYTMusicButton_enabled", @"hideAutoplaySwitch_enabled", @"hideCC_enabled", @"hideVideoTitle_enabled", @"disableCollapseButton_enabled", @"disableFullscreenButton_enabled", @"hideHUD_enabled", @"hidePaidPromotionCard_enabled", @"hideChannelWatermark_enabled", @"hideVideoPlayerShadowOverlayButtons_enabled", @"hidePreviousAndNextButton_enabled", @"redProgressBar_enabled", @"hideHoverCards_enabled", @"hideRightPanel_enabled", @"hideFullscreenActions_enabled", @"noSuggestedVideo_enabled", @"hideHeatwaves_enabled", @"hideDoubleTapToSeekOverlay_enabled", @"hideOverlayDarkBackground_enabled", @"disableAmbientMode_enabled", @"noVideosInFullscreen_enabled", @"noRelatedWatchNexts_enabled",
|
|
||||||
/* MAIN Shorts Keys */ @"hideBuySuperThanks_enabled", @"hideSubcriptions_enabled", @"disableResumeToShorts_enabled", @"shortsQualityPicker_enabled",
|
|
||||||
/* MAIN Player UI Keys */ @"redSubscribeButton_enabled", @"hideButtonContainers_enabled", @"hideConnectButton_enabled", @"hideShareButton_enabled", @"hideRemixButton_enabled", @"hideThanksButton_enabled", @"hideDownloadButton_enabled", @"hideClipButton_enabled", @"hideSaveToPlaylistButton_enabled", @"hideReportButton_enabled", @"hidePreviewCommentSection_enabled", @"hideCommentSection_enabled",
|
|
||||||
/* MAIN Overlay Keys */ @"disableAccountSection_enabled", @"disableAutoplaySection_enabled", @"disableTryNewFeaturesSection_enabled", @"disableVideoQualityPreferencesSection_enabled", @"disableNotificationsSection_enabled", @"disableManageAllHistorySection_enabled", @"disableYourDataInYouTubeSection_enabled", @"disablePrivacySection_enabled", @"disableLiveChatSection_enabled", @"hidePremiumPromos_enabled",
|
|
||||||
/* MAIN App UI Keys */ @"hideHomeTab_enabled", @"lowContrastMode_enabled", @"fixLowContrastMode_enabled", @"disableModernButtons_enabled", @"disableRoundedHints_enabled", @"disableModernFlags_enabled", @"ytNoModernUI_enabled", @"enableVersionSpoofer_enabled",
|
|
||||||
/* MAIN Misc Keys */ @"uYouAdBlockingWorkaroundLite_enabled", @"uYouAdBlockingWorkaround_enabled", @"disableAnimatedYouTubeLogo_enabled", @"centerYouTubeLogo_enabled", @"hideYouTubeLogo_enabled", @"ytStartupAnimation_enabled", @"disableHints_enabled", @"stickNavigationBar_enabled", @"hideSponsorBlockButton_enabled", @"hideChipBar_enabled", @"hidePlayNextInQueue_enabled", @"hideCommunityPosts_enabled", @"hideChannelHeaderLinks_enabled", @"iPhoneLayout_enabled", @"bigYTMiniPlayer_enabled", @"reExplore_enabled", @"autoHideHomeBar_enabled", @"hideSubscriptionsNotificationBadge_enabled", @"fixCasting_enabled", @"newSettingsUI_enabled", @"flex_enabled",
|
|
||||||
/* TWEAK uYou Keys */ @"hideShortsTab", @"hideCreateTab", @"hideCastButton", @"relatedVideosAtTheEndOfYTVideos", @"disableAgeRestriction", @"removeYouTubeAds", @"noSuggestedVideoAtEnd", @"showedWelcomeVC", @"shortsProgressBar", @"hideShortsCells", @"removeShortsCell", @"startupPage",
|
|
||||||
/* TWEAK YTUHD Keys */ @"EnableVP9", @"AllVP9"];
|
|
||||||
for (NSString *key in copyKeys) {
|
for (NSString *key in copyKeys) {
|
||||||
if ([userDefaults objectForKey:key]) {
|
if ([userDefaults objectForKey:key]) {
|
||||||
NSString *value = [userDefaults objectForKey:key];
|
NSString *value = [userDefaults objectForKey:key];
|
||||||
|
|
@ -250,6 +244,7 @@ extern NSBundle *uYouPlusBundle();
|
||||||
documentPicker.delegate = (id<UIDocumentPickerDelegate>)self;
|
documentPicker.delegate = (id<UIDocumentPickerDelegate>)self;
|
||||||
documentPicker.allowsMultipleSelection = NO;
|
documentPicker.allowsMultipleSelection = NO;
|
||||||
[settingsViewController presentViewController:documentPicker animated:YES completion:nil];
|
[settingsViewController presentViewController:documentPicker animated:YES completion:nil];
|
||||||
|
return YES;
|
||||||
} else {
|
} else {
|
||||||
// Paste Settings functionality (default behavior)
|
// Paste Settings functionality (default behavior)
|
||||||
UIAlertController *confirmPasteAlert = [UIAlertController alertControllerWithTitle:LOC(@"Are you sure you want to paste the settings?") message:nil preferredStyle:UIAlertControllerStyleAlert];
|
UIAlertController *confirmPasteAlert = [UIAlertController alertControllerWithTitle:LOC(@"Are you sure you want to paste the settings?") message:nil preferredStyle:UIAlertControllerStyleAlert];
|
||||||
|
|
@ -265,7 +260,7 @@ extern NSBundle *uYouPlusBundle();
|
||||||
NSString *value = components[1];
|
NSString *value = components[1];
|
||||||
[[NSUserDefaults standardUserDefaults] setObject:value forKey:key];
|
[[NSUserDefaults standardUserDefaults] setObject:value forKey:key];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
[settingsViewController reloadData];
|
[settingsViewController reloadData];
|
||||||
SHOW_RELAUNCH_YT_SNACKBAR;
|
SHOW_RELAUNCH_YT_SNACKBAR;
|
||||||
}
|
}
|
||||||
|
|
@ -277,7 +272,7 @@ extern NSBundle *uYouPlusBundle();
|
||||||
];
|
];
|
||||||
[sectionItems addObject:pasteSettings];
|
[sectionItems addObject:pasteSettings];
|
||||||
|
|
||||||
// SWITCH_ITEM(LOC(@"REPLACE_COPY_AND_PASTE_BUTTONS"), LOC(@"REPLACE_COPY_AND_PASTE_BUTTONS"), @"replaceCopyandPasteButtons_enabled");
|
SWITCH_ITEM(LOC(@"REPLACE_COPY_AND_PASTE_BUTTONS"), LOC(@"REPLACE_COPY_AND_PASTE_BUTTONS_DESC"), @"replaceCopyandPasteButtons_enabled");
|
||||||
|
|
||||||
YTSettingsSectionItem *exitYT = [%c(YTSettingsSectionItem)
|
YTSettingsSectionItem *exitYT = [%c(YTSettingsSectionItem)
|
||||||
itemWithTitle:LOC(@"QUIT_YOUTUBE")
|
itemWithTitle:LOC(@"QUIT_YOUTUBE")
|
||||||
|
|
@ -297,7 +292,7 @@ extern NSBundle *uYouPlusBundle();
|
||||||
# pragma mark - uYouEnhanced Essential Menu
|
# pragma mark - uYouEnhanced Essential Menu
|
||||||
YTSettingsSectionItem *customAppMenu = [%c(YTSettingsSectionItem)
|
YTSettingsSectionItem *customAppMenu = [%c(YTSettingsSectionItem)
|
||||||
itemWithTitle:LOC(@"UYOUENHANCED_ESSENTIAL_MENU")
|
itemWithTitle:LOC(@"UYOUENHANCED_ESSENTIAL_MENU")
|
||||||
titleDescription:LOC(@"This menu includes App Color Customization & Ability to Clear the Cache 🗑️")
|
titleDescription:LOC(@"This menu includes App Color Customization 🎨 & Ability to Clear the Cache 🗑️")
|
||||||
accessibilityIdentifier:nil
|
accessibilityIdentifier:nil
|
||||||
detailTextBlock:nil
|
detailTextBlock:nil
|
||||||
selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) {
|
selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) {
|
||||||
|
|
@ -439,6 +434,24 @@ extern NSBundle *uYouPlusBundle();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
);
|
);
|
||||||
|
SWITCH_ITEM3(
|
||||||
|
LOC(@"FULLSCREEN_TO_THE_RIGHT"),
|
||||||
|
LOC(@"FULLSCREEN_TO_THE_RIGHT_DESC"),
|
||||||
|
@"fullscreenToTheRight_enabled",
|
||||||
|
({
|
||||||
|
if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone) {
|
||||||
|
[[NSUserDefaults standardUserDefaults] setBool:enable forKey:@"fullscreenToTheRight_enabled"];
|
||||||
|
SHOW_RELAUNCH_YT_SNACKBAR;
|
||||||
|
return YES;
|
||||||
|
} else {
|
||||||
|
UIAlertController *alert = [UIAlertController alertControllerWithTitle:@"Incompatibile" message:@"This Option is Incompatible on an iPad Device." preferredStyle:UIAlertControllerStyleAlert];
|
||||||
|
UIAlertAction *okAction = [UIAlertAction actionWithTitle:@"OK" style:UIAlertActionStyleDefault handler:nil];
|
||||||
|
[alert addAction:okAction];
|
||||||
|
[settingsViewController presentViewController:alert animated:YES completion:nil];
|
||||||
|
return NO;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
);
|
||||||
SWITCH_ITEM2(LOC(@"SLIDE_TO_SEEK"), LOC(@"SLIDE_TO_SEEK_DESC"), @"slideToSeek_enabled");
|
SWITCH_ITEM2(LOC(@"SLIDE_TO_SEEK"), LOC(@"SLIDE_TO_SEEK_DESC"), @"slideToSeek_enabled");
|
||||||
SWITCH_ITEM2(LOC(@"ENABLE_TAP_TO_SEEK"), LOC(@"ENABLE_TAP_TO_SEEK_DESC"), @"YTTapToSeek_enabled");
|
SWITCH_ITEM2(LOC(@"ENABLE_TAP_TO_SEEK"), LOC(@"ENABLE_TAP_TO_SEEK_DESC"), @"YTTapToSeek_enabled");
|
||||||
SWITCH_ITEM(LOC(@"DISABLE_DOUBLE_TAP_TO_SEEK"), LOC(@"DISABLE_DOUBLE_TAP_TO_SEEK_DESC"), @"doubleTapToSeek_disabled");
|
SWITCH_ITEM(LOC(@"DISABLE_DOUBLE_TAP_TO_SEEK"), LOC(@"DISABLE_DOUBLE_TAP_TO_SEEK_DESC"), @"doubleTapToSeek_disabled");
|
||||||
|
|
@ -475,16 +488,19 @@ extern NSBundle *uYouPlusBundle();
|
||||||
LOC(@"HIDE_FULLSCREEN_ACTION_BUTTONS_DESC"),
|
LOC(@"HIDE_FULLSCREEN_ACTION_BUTTONS_DESC"),
|
||||||
@"hideFullscreenActions_enabled",
|
@"hideFullscreenActions_enabled",
|
||||||
({
|
({
|
||||||
if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone) {
|
if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad) {
|
||||||
[[NSUserDefaults standardUserDefaults] setBool:enable forKey:@"hideFullscreenActions_enabled"];
|
// Show alert if the option is not compatible with iPad
|
||||||
SHOW_RELAUNCH_YT_SNACKBAR;
|
UIAlertController *alert = [UIAlertController alertControllerWithTitle:@"iPad Compatibility Issue" message:@"This option is only compatible with iPhone devices." preferredStyle:UIAlertControllerStyleAlert];
|
||||||
return YES;
|
|
||||||
} else {
|
|
||||||
UIAlertController *alert = [UIAlertController alertControllerWithTitle:@"Incompatibile" message:@"This Option is Incompatible on an iPad Device." preferredStyle:UIAlertControllerStyleAlert];
|
|
||||||
UIAlertAction *okAction = [UIAlertAction actionWithTitle:@"OK" style:UIAlertActionStyleDefault handler:nil];
|
UIAlertAction *okAction = [UIAlertAction actionWithTitle:@"OK" style:UIAlertActionStyleDefault handler:nil];
|
||||||
[alert addAction:okAction];
|
[alert addAction:okAction];
|
||||||
[settingsViewController presentViewController:alert animated:YES completion:nil];
|
[settingsViewController presentViewController:alert animated:YES completion:nil];
|
||||||
return NO;
|
return NO;
|
||||||
|
} else {
|
||||||
|
// Normal Behavior (iPhone)
|
||||||
|
[[NSUserDefaults standardUserDefaults] setBool:enable forKey:@"hideFullscreenActions_enabled"];
|
||||||
|
[settingsViewController reloadData];
|
||||||
|
SHOW_RELAUNCH_YT_SNACKBAR;
|
||||||
|
return YES;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
);
|
);
|
||||||
|
|
@ -529,7 +545,7 @@ extern NSBundle *uYouPlusBundle();
|
||||||
# pragma mark - Video player button options
|
# pragma mark - Video player button options
|
||||||
SECTION_HEADER(LOC(@"VIDEO_PLAYER_BUTTON_OPTIONS"));
|
SECTION_HEADER(LOC(@"VIDEO_PLAYER_BUTTON_OPTIONS"));
|
||||||
|
|
||||||
// (the options "Red Subscribe Button" and "Hide Button Containers under player" are currently not working)
|
// (the options "Red Subscribe Button" and "Hide Button Containers under player" are currently not working, would most likely result in effecting the whole entire app.)
|
||||||
//
|
//
|
||||||
// SWITCH_ITEM(LOC(@"RED_SUBSCRIBE_BUTTON"), LOC(@"RED_SUBSCRIBE_BUTTON_DESC"), @"redSubscribeButton_enabled");
|
// SWITCH_ITEM(LOC(@"RED_SUBSCRIBE_BUTTON"), LOC(@"RED_SUBSCRIBE_BUTTON_DESC"), @"redSubscribeButton_enabled");
|
||||||
// SWITCH_ITEM2(LOC(@"HIDE_BUTTON_CONTAINERS_UNDER_PLAYER"), LOC(@"HIDE_BUTTON_CONTAINERS_UNDER_PLAYER_DESC"), @"hideButtonContainers_enabled");
|
// SWITCH_ITEM2(LOC(@"HIDE_BUTTON_CONTAINERS_UNDER_PLAYER"), LOC(@"HIDE_BUTTON_CONTAINERS_UNDER_PLAYER_DESC"), @"hideButtonContainers_enabled");
|
||||||
|
|
@ -639,6 +655,7 @@ extern NSBundle *uYouPlusBundle();
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
[sectionItems addObject:lowContrastModeButton];
|
[sectionItems addObject:lowContrastModeButton];
|
||||||
|
SWITCH_ITEM2(LOC(@"CLASSIC_VIDEO_PLAYER"), LOC(@"CLASSIC_VIDEO_PLAYER_DESC"), @"classicVideoPlayer_enabled");
|
||||||
SWITCH_ITEM2(LOC(@"FIX_LOWCONTRASTMODE"), LOC(@"FIX_LOWCONTRASTMODE_DESC"), @"fixLowContrastMode_enabled");
|
SWITCH_ITEM2(LOC(@"FIX_LOWCONTRASTMODE"), LOC(@"FIX_LOWCONTRASTMODE_DESC"), @"fixLowContrastMode_enabled");
|
||||||
SWITCH_ITEM2(LOC(@"DISABLE_MODERN_BUTTONS"), LOC(@"DISABLE_MODERN_BUTTONS_DESC"), @"disableModernButtons_enabled");
|
SWITCH_ITEM2(LOC(@"DISABLE_MODERN_BUTTONS"), LOC(@"DISABLE_MODERN_BUTTONS_DESC"), @"disableModernButtons_enabled");
|
||||||
SWITCH_ITEM2(LOC(@"DISABLE_ROUNDED_CORNERS_ON_HINTS"), LOC(@"DISABLE_ROUNDED_CORNERS_ON_HINTS_DESC"), @"disableRoundedHints_enabled");
|
SWITCH_ITEM2(LOC(@"DISABLE_ROUNDED_CORNERS_ON_HINTS"), LOC(@"DISABLE_ROUNDED_CORNERS_ON_HINTS_DESC"), @"disableRoundedHints_enabled");
|
||||||
|
|
@ -1331,7 +1348,7 @@ extern NSBundle *uYouPlusBundle();
|
||||||
return YES;
|
return YES;
|
||||||
}]
|
}]
|
||||||
];
|
];
|
||||||
YTSettingsPickerViewController *picker = [[%c(YTSettingsPickerViewController) alloc] initWithNavTitle:LOC(@"VERSION_SPOOFER_TITLE") pickerSectionTitle:nil rows:rows selectedItemIndex:appVersionSpoofer() parentResponder:[self parentResponder]];
|
YTSettingsPickerViewController *picker = [[%c(YTSettingsPickerViewController) alloc] initWithNavTitle:LOC(@"VERSION_SPOOFER_SELECTOR") pickerSectionTitle:nil rows:rows selectedItemIndex:appVersionSpoofer() parentResponder:[self parentResponder]];
|
||||||
[settingsViewController pushViewController:picker];
|
[settingsViewController pushViewController:picker];
|
||||||
return YES;
|
return YES;
|
||||||
}
|
}
|
||||||
|
|
@ -1394,6 +1411,28 @@ extern NSBundle *uYouPlusBundle();
|
||||||
[settingsViewController setSectionItems:sectionItems forCategory:uYouPlusSection title:@"uYouEnhanced" titleDescription:LOC(@"TITLE DESCRIPTION") headerHidden:YES];
|
[settingsViewController setSectionItems:sectionItems forCategory:uYouPlusSection title:@"uYouEnhanced" titleDescription:LOC(@"TITLE DESCRIPTION") headerHidden:YES];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// File Manager (Import Settings .txt)
|
||||||
|
- (void)documentPicker:(UIDocumentPickerViewController *)controller didPickDocumentsAtURLs:(NSArray<NSURL *> *)urls {
|
||||||
|
if (urls.count > 0) {
|
||||||
|
NSURL *fileURL = urls.firstObject;
|
||||||
|
NSString *fileContents = [NSString stringWithContentsOfURL:fileURL encoding:NSUTF8StringEncoding error:nil];
|
||||||
|
if (fileContents.length > 0) {
|
||||||
|
NSArray *lines = [fileContents componentsSeparatedByString:@"\n"];
|
||||||
|
for (NSString *line in lines) {
|
||||||
|
NSArray *components = [line componentsSeparatedByString:@": "];
|
||||||
|
if (components.count == 2) {
|
||||||
|
NSString *key = components[0];
|
||||||
|
NSString *value = components[1];
|
||||||
|
[[NSUserDefaults standardUserDefaults] setObject:value forKey:key];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
YTSettingsViewController *settingsViewController = [self valueForKey:@"_settingsViewControllerDelegate"];
|
||||||
|
[settingsViewController reloadData];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
- (void)updateSectionForCategory:(NSUInteger)category withEntry:(id)entry {
|
- (void)updateSectionForCategory:(NSUInteger)category withEntry:(id)entry {
|
||||||
if (category == uYouPlusSection) {
|
if (category == uYouPlusSection) {
|
||||||
[self updateTweakSectionWithEntry:entry];
|
[self updateTweakSectionWithEntry:entry];
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@ jobs:
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
uses: actions/checkout@v4.1.4
|
uses: actions/checkout@v4.1.7
|
||||||
|
|
||||||
- name: Set up Git
|
- name: Set up Git
|
||||||
run: |
|
run: |
|
||||||
|
|
@ -20,11 +20,11 @@ jobs:
|
||||||
|
|
||||||
- name: Add uYouEnhanced submodules
|
- name: Add uYouEnhanced submodules
|
||||||
run: |
|
run: |
|
||||||
# git submodule add https://github.com/PoomSmart/FLEXing.git Tweaks/FLEXing
|
|
||||||
git submodule add https://github.com/dayanch96/uYouLocalization.git Tweaks/uYouLocalization
|
git submodule add https://github.com/dayanch96/uYouLocalization.git Tweaks/uYouLocalization
|
||||||
git submodule add https://github.com/arichornlover/YTHoldForSpeed.git Tweaks/YTHoldForSpeed
|
git submodule add https://github.com/arichornloverALT/YTHoldForSpeed.git Tweaks/YTHoldForSpeed
|
||||||
git submodule add https://github.com/arichornlover/YouGroupSettings.git Tweaks/YouGroupSettings
|
git submodule add https://github.com/arichornloverALT/YouGroupSettings.git Tweaks/YouGroupSettings
|
||||||
git submodule add https://github.com/arichornlover/YouTimeStamp.git Tweaks/YouTimeStamp
|
git submodule add https://github.com/arichornloverALT/YouTimeStamp.git Tweaks/YouTimeStamp
|
||||||
|
git submodule add https://github.com/protocolbuffers/protobuf.git Tweaks/protobuf
|
||||||
git add .
|
git add .
|
||||||
git commit -m "added uYouEnhanced submodules"
|
git commit -m "added uYouEnhanced submodules"
|
||||||
git push origin
|
git push origin
|
||||||
|
|
@ -84,7 +84,6 @@ jobs:
|
||||||
- name: Make .bundle files
|
- name: Make .bundle files
|
||||||
run: |
|
run: |
|
||||||
cd Bundles
|
cd Bundles
|
||||||
ln -s ../Tweaks/MrBeastify/layout/Library/Application\ Support/MrBeastify.bundle MrBeastify.bundle
|
|
||||||
ln -s ../Tweaks/uYouLocalization/layout/Library/Application\ Support/uYouLocalization.bundle uYouLocalization.bundle
|
ln -s ../Tweaks/uYouLocalization/layout/Library/Application\ Support/uYouLocalization.bundle uYouLocalization.bundle
|
||||||
ln -s ../Tweaks/YTHoldForSpeed/layout/Library/Application\ Support/YTHoldForSpeed.bundle YTHoldForSpeed.bundle
|
ln -s ../Tweaks/YTHoldForSpeed/layout/Library/Application\ Support/YTHoldForSpeed.bundle YTHoldForSpeed.bundle
|
||||||
ln -s ../Tweaks/YouGroupSettings/layout/Library/Application\ Support/YouGroupSettings.bundle YouGroupSettings.bundle
|
ln -s ../Tweaks/YouGroupSettings/layout/Library/Application\ Support/YouGroupSettings.bundle YouGroupSettings.bundle
|
||||||
|
|
@ -98,7 +97,6 @@ jobs:
|
||||||
# - name: Delete .bundle files
|
# - name: Delete .bundle files
|
||||||
# run: |
|
# run: |
|
||||||
# cd Bundles
|
# cd Bundles
|
||||||
# rm -f MrBeastify.bundle
|
|
||||||
# rm -f uYouLocalization.bundle
|
# rm -f uYouLocalization.bundle
|
||||||
# rm -f YTHoldForSpeed.bundle
|
# rm -f YTHoldForSpeed.bundle
|
||||||
# rm -f YouGroupSettings.bundle
|
# rm -f YouGroupSettings.bundle
|
||||||
|
|
|
||||||
|
|
@ -1 +1 @@
|
||||||
Subproject commit 4e938e351e96e5c62f6099c00b24abd179143aef
|
Subproject commit edf35a14fe99a53dc6d51a8aa2292bc8529316af
|
||||||
|
|
@ -1 +1 @@
|
||||||
Subproject commit 9bf17bfdede78a236f5d67f780cf77709a9e5fdf
|
Subproject commit 12b4991ade6d3edd1e4fb28fe19bb32b6dc93206
|
||||||
|
|
@ -1 +1 @@
|
||||||
Subproject commit 3b43f12a23aee37dcf21a26685f134c7afb224de
|
Subproject commit 6691e4c307e7e6366ee7b715f558e91904f86d95
|
||||||
|
|
@ -1 +1 @@
|
||||||
Subproject commit 38a2b7032200f700c661b6f6e9d22b4a7eb47e85
|
Subproject commit 93ff6610f856a70917adcf7fb9af2c9a94dfeb63
|
||||||
|
|
@ -1 +1 @@
|
||||||
Subproject commit 35b7fc5251ee3feddee4b003f2f76bf1cdd80ed0
|
Subproject commit 2def430a6e70ddd6e0937f03d6ebd95a0c9382e6
|
||||||
|
|
@ -1 +1 @@
|
||||||
Subproject commit fb2cc71e91bdbfd7a612b1d1bd2b1e875900564f
|
Subproject commit 58951f248bfe90298ca65007603d465f58369876
|
||||||
1
Tweaks/protobuf
Submodule
|
|
@ -0,0 +1 @@
|
||||||
|
Subproject commit 532f0c2ed52b60bc33492a2ee4cbf9c4ca960450
|
||||||
4
control
|
|
@ -1,8 +1,8 @@
|
||||||
Package: com.arichorn.uyouenhanced
|
Package: com.arichornlover.uyouenhanced
|
||||||
Name: uYouEnhanced
|
Name: uYouEnhanced
|
||||||
Architecture: iphoneos-arm
|
Architecture: iphoneos-arm
|
||||||
Description: An expanded version of uYouPlus
|
Description: An expanded version of uYouPlus
|
||||||
Maintainer: arichorn
|
Maintainer: arichornlover
|
||||||
Author: qnblackcat
|
Author: qnblackcat
|
||||||
Section: Tweaks
|
Section: Tweaks
|
||||||
Depends: mobilesubstrate (>= 0.9.5000), com.miro.uyou
|
Depends: mobilesubstrate (>= 0.9.5000), com.miro.uyou
|
||||||
|
|
|
||||||