This repository was archived by the owner on Feb 25, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +0
-16
lines changed
shell/platform/darwin/ios/framework/Source Expand file tree Collapse file tree 1 file changed +0
-16
lines changed Original file line number Diff line number Diff line change @@ -762,22 +762,6 @@ - (void)onLocaleUpdated:(NSNotification*)notification {
762762 NSArray <NSString *>* preferredLocales = [NSLocale preferredLanguages ];
763763 NSMutableArray <NSString *>* data = [[NSMutableArray new ] autorelease ];
764764
765- // Force prepend the [NSLocale currentLocale] to the front of the list
766- // to ensure we are including the full default locale. preferredLocales
767- // is not guaranteed to include anything beyond the languageCode.
768- NSLocale * currentLocale = [NSLocale currentLocale ];
769- NSString * languageCode = [currentLocale objectForKey: NSLocaleLanguageCode ];
770- NSString * countryCode = [currentLocale objectForKey: NSLocaleCountryCode ];
771- NSString * scriptCode = [currentLocale objectForKey: NSLocaleScriptCode ];
772- NSString * variantCode = [currentLocale objectForKey: NSLocaleVariantCode ];
773- if (languageCode) {
774- [data addObject: languageCode];
775- [data addObject: (countryCode ? countryCode : @" " )];
776- [data addObject: (scriptCode ? scriptCode : @" " )];
777- [data addObject: (variantCode ? variantCode : @" " )];
778- }
779-
780- // Add any secondary locales/languages to the list.
781765 for (NSString * localeID in preferredLocales) {
782766 NSLocale * currentLocale = [[[NSLocale alloc ] initWithLocaleIdentifier: localeID] autorelease ];
783767 NSString * languageCode = [currentLocale objectForKey: NSLocaleLanguageCode ];
You can’t perform that action at this time.
0 commit comments