From c80acf9fd9116cc16515da42248892c2279f670a Mon Sep 17 00:00:00 2001 From: Diego Pavani Date: Wed, 11 Oct 2023 16:37:33 -0300 Subject: [PATCH] fix:Fix text color reverting to default after changing tintColor --- ios/RNCSegmentedControl.m | 9 --------- 1 file changed, 9 deletions(-) diff --git a/ios/RNCSegmentedControl.m b/ios/RNCSegmentedControl.m index 285abbdc..11368cf1 100644 --- a/ios/RNCSegmentedControl.m +++ b/ios/RNCSegmentedControl.m @@ -60,15 +60,6 @@ - (void)setTintColor:(UIColor *)tintColor { __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_13_0 if (@available(iOS 13.0, *)) { [self setSelectedSegmentTintColor:tintColor]; - NSDictionary *attributes = [NSDictionary - dictionaryWithObjectsAndKeys:tintColor, NSForegroundColorAttributeName, - nil]; - NSDictionary *activeAttributes = [NSDictionary - dictionaryWithObjectsAndKeys:UIColor.labelColor, - NSForegroundColorAttributeName, nil]; - [self setTitleTextAttributes:attributes forState:UIControlStateNormal]; - [self setTitleTextAttributes:activeAttributes - forState:UIControlStateSelected]; } #endif }