mirror of
				https://github.com/SoPat712/YTLitePlus.git
				synced 2025-10-30 12:33:57 -04:00 
			
		
		
		
	
							
								
								
									
										18
									
								
								Header.h
									
									
									
									
									
								
							
							
						
						
									
										18
									
								
								Header.h
									
									
									
									
									
								
							| @@ -115,6 +115,24 @@ | |||||||
| @end | @end | ||||||
|  |  | ||||||
| // App Theme | // App Theme | ||||||
|  | @interface YTColor : NSObject | ||||||
|  | + (UIColor *)white1; | ||||||
|  | + (UIColor *)white2; | ||||||
|  | + (UIColor *)white3; | ||||||
|  | + (UIColor *)white4; | ||||||
|  | + (UIColor *)white5; | ||||||
|  | + (UIColor *)black0; | ||||||
|  | + (UIColor *)black1; | ||||||
|  | + (UIColor *)black2; | ||||||
|  | + (UIColor *)black3; | ||||||
|  | + (UIColor *)black4; | ||||||
|  | + (UIColor *)blackPure; | ||||||
|  | + (UIColor *)grey1; | ||||||
|  | + (UIColor *)grey2; | ||||||
|  | + (UIColor *)white1Alpha98; | ||||||
|  | + (UIColor *)white1Alpha95; | ||||||
|  | @end | ||||||
|  |  | ||||||
| @interface YCHLiveChatView : UIView | @interface YCHLiveChatView : UIView | ||||||
| @end | @end | ||||||
|  |  | ||||||
|   | |||||||
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							| @@ -12,8 +12,8 @@ static BOOL IsEnabled(NSString *key) { | |||||||
| static int GetSelection(NSString *key) { | static int GetSelection(NSString *key) { | ||||||
|     return [[NSUserDefaults standardUserDefaults] integerForKey:key]; |     return [[NSUserDefaults standardUserDefaults] integerForKey:key]; | ||||||
| } | } | ||||||
| static int colorContrastMode() { | static int contrastMode() { | ||||||
|     return [[NSUserDefaults standardUserDefaults] integerForKey:@"lcmColor"]; |     return [[NSUserDefaults standardUserDefaults] integerForKey:@"lcm"]; | ||||||
| } | } | ||||||
| static int appVersionSpoofer() { | static int appVersionSpoofer() { | ||||||
|     return [[NSUserDefaults standardUserDefaults] integerForKey:@"versionSpoofer"]; |     return [[NSUserDefaults standardUserDefaults] integerForKey:@"versionSpoofer"]; | ||||||
| @@ -124,80 +124,31 @@ extern NSBundle *YTLitePlusBundle(); | |||||||
|     [sectionItems addObject:videoControlOverlayGroup]; |     [sectionItems addObject:videoControlOverlayGroup]; | ||||||
|  |  | ||||||
| # pragma mark - LowContrastMode | # pragma mark - LowContrastMode | ||||||
|     YTSettingsSectionItem *lowContrastModeSection = [YTSettingsSectionItemClass itemWithTitle:LOC(@"LCM_CHOOSE_COLOR") |     YTSettingsSectionItem *lowContrastModeSection = [YTSettingsSectionItemClass itemWithTitle:LOC(@"Low Contrast Mode") | ||||||
|         accessibilityIdentifier:nil |         accessibilityIdentifier:nil | ||||||
|         detailTextBlock:^NSString *() { |         detailTextBlock:^NSString *() { | ||||||
|             switch (colorContrastMode()) { |             switch (contrastMode()) { | ||||||
|                 case 1: |                 case 1: | ||||||
|                     return LOC(@"RED_UI"); |                     return LOC(@"Hex Color"); | ||||||
|                 case 2: |  | ||||||
|                     return LOC(@"BLUE_UI"); |  | ||||||
|                 case 3: |  | ||||||
|                     return LOC(@"GREEN_UI"); |  | ||||||
|                 case 4: |  | ||||||
|                     return LOC(@"YELLOW_UI"); |  | ||||||
|                 case 5: |  | ||||||
|                     return LOC(@"ORANGE_UI"); |  | ||||||
|                 case 6: |  | ||||||
|                     return LOC(@"PURPLE_UI"); |  | ||||||
|                 case 7: |  | ||||||
|                     return LOC(@"VIOLET_UI"); |  | ||||||
|                 case 8: |  | ||||||
|                     return LOC(@"PINK_UI"); |  | ||||||
|                 case 0: |                 case 0: | ||||||
|                 default: |                 default: | ||||||
|                     return LOC(@"DEFAULT_UI"); |                     return LOC(@"Default"); | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
|         selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) { |         selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) { | ||||||
|             NSArray <YTSettingsSectionItem *> *rows = @[ |             NSArray <YTSettingsSectionItem *> *rows = @[ | ||||||
|                 [YTSettingsSectionItemClass checkmarkItemWithTitle:LOC(@"DEFAULT_UI") titleDescription:nil selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) { |                 [YTSettingsSectionItemClass checkmarkItemWithTitle:LOC(@"Default") titleDescription:nil selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) { | ||||||
|                     [[NSUserDefaults standardUserDefaults] setInteger:0 forKey:@"lcmColor"]; |                     [[NSUserDefaults standardUserDefaults] setInteger:0 forKey:@"lcm"]; | ||||||
|                     [settingsViewController reloadData]; |                     [settingsViewController reloadData]; | ||||||
|                     return YES; |                     return YES; | ||||||
|                 }], |                 }], | ||||||
|                 [YTSettingsSectionItemClass checkmarkItemWithTitle:LOC(@"RED_UI") titleDescription:nil selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) { |                 [YTSettingsSectionItemClass checkmarkItemWithTitle:LOC(@"Hex Color") titleDescription:nil selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) { | ||||||
|                     [[NSUserDefaults standardUserDefaults] setInteger:1 forKey:@"lcmColor"]; |                     [[NSUserDefaults standardUserDefaults] setInteger:1 forKey:@"lcm"]; | ||||||
|                     [settingsViewController reloadData]; |  | ||||||
|                     return YES; |  | ||||||
|                 }], |  | ||||||
|                 [YTSettingsSectionItemClass checkmarkItemWithTitle:LOC(@"BLUE_UI") titleDescription:nil selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) { |  | ||||||
|                     [[NSUserDefaults standardUserDefaults] setInteger:2 forKey:@"lcmColor"]; |  | ||||||
|                     [settingsViewController reloadData]; |  | ||||||
|                     return YES; |  | ||||||
|                 }], |  | ||||||
|                 [YTSettingsSectionItemClass checkmarkItemWithTitle:LOC(@"GREEN_UI") titleDescription:nil selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) { |  | ||||||
|                     [[NSUserDefaults standardUserDefaults] setInteger:3 forKey:@"lcmColor"]; |  | ||||||
|                     [settingsViewController reloadData]; |  | ||||||
|                     return YES; |  | ||||||
|                 }], |  | ||||||
|                 [YTSettingsSectionItemClass checkmarkItemWithTitle:LOC(@"YELLOW_UI") titleDescription:nil selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) { |  | ||||||
|                     [[NSUserDefaults standardUserDefaults] setInteger:4 forKey:@"lcmColor"]; |  | ||||||
|                     [settingsViewController reloadData]; |  | ||||||
|                     return YES; |  | ||||||
|                 }], |  | ||||||
|                 [YTSettingsSectionItemClass checkmarkItemWithTitle:LOC(@"ORANGE_UI") titleDescription:nil selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) { |  | ||||||
|                     [[NSUserDefaults standardUserDefaults] setInteger:5 forKey:@"lcmColor"]; |  | ||||||
|                     [settingsViewController reloadData]; |  | ||||||
|                     return YES; |  | ||||||
|                 }], |  | ||||||
|                 [YTSettingsSectionItemClass checkmarkItemWithTitle:LOC(@"PURPLE_UI") titleDescription:nil selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) { |  | ||||||
|                     [[NSUserDefaults standardUserDefaults] setInteger:6 forKey:@"lcmColor"]; |  | ||||||
|                     [settingsViewController reloadData]; |  | ||||||
|                     return YES; |  | ||||||
|                 }], |  | ||||||
|                 [YTSettingsSectionItemClass checkmarkItemWithTitle:LOC(@"VIOLET_UI") titleDescription:nil selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) { |  | ||||||
|                     [[NSUserDefaults standardUserDefaults] setInteger:7 forKey:@"lcmColor"]; |  | ||||||
|                     [settingsViewController reloadData]; |  | ||||||
|                     return YES; |  | ||||||
|                 }], |  | ||||||
|                 [YTSettingsSectionItemClass checkmarkItemWithTitle:LOC(@"PINK_UI") titleDescription:nil selectBlock:^BOOL (YTSettingsCell *cell, NSUInteger arg1) { |  | ||||||
|                     [[NSUserDefaults standardUserDefaults] setInteger:8 forKey:@"lcmColor"]; |  | ||||||
|                     [settingsViewController reloadData]; |                     [settingsViewController reloadData]; | ||||||
|                     return YES; |                     return YES; | ||||||
|                 }] |                 }] | ||||||
|             ]; |             ]; | ||||||
|             YTSettingsPickerViewController *picker = [[%c(YTSettingsPickerViewController) alloc] initWithNavTitle:LOC(@"LCM_CHOOSE_COLOR") pickerSectionTitle:nil rows:rows selectedItemIndex:colorContrastMode() parentResponder:[self parentResponder]]; |             YTSettingsPickerViewController *picker = [[%c(YTSettingsPickerViewController) alloc] initWithNavTitle:LOC(@"Low Contrast Mode") pickerSectionTitle:nil rows:rows selectedItemIndex:contrastMode() parentResponder:[self parentResponder]]; | ||||||
|             [settingsViewController pushViewController:picker]; |             [settingsViewController pushViewController:picker]; | ||||||
|             return YES; |             return YES; | ||||||
|         }]; |         }]; | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Balackburn
					Balackburn