mirror of
https://github.com/arichornlover/uYouEnhanced.git
synced 2026-05-14 19:40:52 +00:00
Update Icons (uYouPlus.xm) - 1/2
This commit is contained in:
parent
3557287863
commit
d2b5633a9a
1 changed files with 3 additions and 3 deletions
|
|
@ -588,8 +588,8 @@ static NSMutableArray <YTIItemSectionRenderer *> *filteredArray(NSArray <YTIItem
|
||||||
%hook YTHeaderLogoController
|
%hook YTHeaderLogoController
|
||||||
- (void)setTopbarLogoRenderer:(YTITopbarLogoRenderer *)renderer {
|
- (void)setTopbarLogoRenderer:(YTITopbarLogoRenderer *)renderer {
|
||||||
// Modify the type of the icon before setting the renderer
|
// Modify the type of the icon before setting the renderer
|
||||||
YTIIcon *iconImage = renderer.iconImage;
|
YTIIcon *icon = [%c(YTIIcon) new];
|
||||||
iconImage.iconType = 537; // magic number for Premium icon, hopefully it doesnt change. 158 is default logo.
|
icon.iconType = YT_PREMIUM_LOGO; // magic number (537) for Premium icon, hopefully it doesnt change. 158 (YT_DEFAULT_LOGO) is default logo.
|
||||||
// Use this modified renderer
|
// Use this modified renderer
|
||||||
%orig;
|
%orig;
|
||||||
}
|
}
|
||||||
|
|
@ -637,7 +637,7 @@ static NSMutableArray <YTIItemSectionRenderer *> *filteredArray(NSArray <YTIItem
|
||||||
// Check if the icon is for the premium advertisement - 117 is magic number for the icon
|
// Check if the icon is for the premium advertisement - 117 is magic number for the icon
|
||||||
if ([icon hasIconType] && icon.iconType == 117) {
|
if ([icon hasIconType] && icon.iconType == 117) {
|
||||||
// Modify the icon type to be Premium
|
// Modify the icon type to be Premium
|
||||||
icon.iconType = 741; // Magic number for premium icon
|
icon.iconType = YT_PREMIUM_STANDALONE; // Magic number (741) for premium icon
|
||||||
// Modify the text
|
// Modify the text
|
||||||
((YTIStringRun *)(compactLinkRenderer.title.runsArray.firstObject)).text = LOC(@"FAKE_YOUR_PREMIUM_BENEFITS");
|
((YTIStringRun *)(compactLinkRenderer.title.runsArray.firstObject)).text = LOC(@"FAKE_YOUR_PREMIUM_BENEFITS");
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue