From 254c7b9f2dab385a1cede92804277849ed76632c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Minh=20Nguye=CC=82=CC=83n?= Date: Mon, 18 Dec 2017 09:43:26 -0800 Subject: [ios, macos] Cleaned up base localization files MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Localizable strings in Darwin classes need to specify “Foundation” as the table so that NSBundle consults the right .strings files. Reran make genstrings to add some missing strings to the base localizations and undo some manual edits to the base localizations that contained errors. --- .../darwin/resources/Base.lproj/Foundation.strings | 6 ++++++ platform/darwin/src/MGLAttributionInfo.mm | 4 ++-- platform/ios/resources/Base.lproj/Localizable.strings | Bin 7378 -> 3962 bytes platform/macos/sdk/Base.lproj/Localizable.strings | Bin 298 -> 840 bytes 4 files changed, 8 insertions(+), 2 deletions(-) diff --git a/platform/darwin/resources/Base.lproj/Foundation.strings b/platform/darwin/resources/Base.lproj/Foundation.strings index 9d63dfa697..ba7db3fc63 100644 --- a/platform/darwin/resources/Base.lproj/Foundation.strings +++ b/platform/darwin/resources/Base.lproj/Foundation.strings @@ -289,3 +289,9 @@ /* West longitude format, short: {longitude} */ "COORD_W_SHORT" = "%@W"; +/* OpenStreetMap full name attribution */ +"OSM_FULL_NAME" = "OpenStreetMap"; + +/* OpenStreetMap short name attribution */ +"OSM_SHORT_NAME" = "OSM"; + diff --git a/platform/darwin/src/MGLAttributionInfo.mm b/platform/darwin/src/MGLAttributionInfo.mm index 29dd5229a7..52a83fd18e 100644 --- a/platform/darwin/src/MGLAttributionInfo.mm +++ b/platform/darwin/src/MGLAttributionInfo.mm @@ -170,8 +170,8 @@ - (NSAttributedString *)titleWithStyle:(MGLAttributionInfoStyle)style { - NSString *openStreetMap = NSLocalizedStringWithDefaultValue(@"OSM_FULL_NAME", nil, nil, @"OpenStreetMap", @"OpenStreetMap full name attribution"); - NSString *OSM = NSLocalizedStringWithDefaultValue(@"OSM_SHORT_NAME", nil, nil, @"OSM", @"OpenStreetMap short name attribution"); + NSString *openStreetMap = NSLocalizedStringWithDefaultValue(@"OSM_FULL_NAME", @"Foundation", nil, @"OpenStreetMap", @"OpenStreetMap full name attribution"); + NSString *OSM = NSLocalizedStringWithDefaultValue(@"OSM_SHORT_NAME", @"Foundation", nil, @"OSM", @"OpenStreetMap short name attribution"); NSMutableAttributedString *title = [[NSMutableAttributedString alloc] initWithAttributedString:self.title]; [title removeAttribute:NSUnderlineStyleAttributeName range:NSMakeRange(0, [title.string length])]; diff --git a/platform/ios/resources/Base.lproj/Localizable.strings b/platform/ios/resources/Base.lproj/Localizable.strings index 245b122fb6..571a6bca6b 100644 Binary files a/platform/ios/resources/Base.lproj/Localizable.strings and b/platform/ios/resources/Base.lproj/Localizable.strings differ diff --git a/platform/macos/sdk/Base.lproj/Localizable.strings b/platform/macos/sdk/Base.lproj/Localizable.strings index cb085add6a..68360320eb 100644 Binary files a/platform/macos/sdk/Base.lproj/Localizable.strings and b/platform/macos/sdk/Base.lproj/Localizable.strings differ -- cgit v1.2.1