Adopt localizedStringWithFormat for displayed quantities (#4109)

* Adopt localizedStringWithFormat for displayed quantities

* xib internationalization support is done
This commit is contained in:
A Cœur
2022-11-15 02:30:03 +08:00
committed by GitHub
parent 1d9159fffc
commit bde1359d5d
22 changed files with 114 additions and 110 deletions

View File

@@ -504,7 +504,7 @@ typedef NS_ENUM(unsigned int, tabTag) {
self.fImageView.image = [NSImage imageNamed:NSImageNameMultipleDocuments];
self.fNameField.stringValue = [NSString
stringWithFormat:NSLocalizedString(@"%lu Torrents Selected", "Inspector -> selected torrents"), numberSelected];
localizedStringWithFormat:NSLocalizedString(@"%lu Torrents Selected", "Inspector -> selected torrents"), numberSelected];
self.fNameField.hidden = NO;
uint64_t size = 0;
@@ -529,7 +529,8 @@ typedef NS_ENUM(unsigned int, tabTag) {
}
else
{
fileString = [NSString stringWithFormat:NSLocalizedString(@"%lu files", "Inspector -> selected torrents"), fileCount];
fileString = [NSString
localizedStringWithFormat:NSLocalizedString(@"%lu files", "Inspector -> selected torrents"), fileCount];
}
[fileStrings addObject:fileString];
}
@@ -543,7 +544,7 @@ typedef NS_ENUM(unsigned int, tabTag) {
else
{
magnetString = [NSString
stringWithFormat:NSLocalizedString(@"%lu magnetized transfers", "Inspector -> selected torrents"), magnetCount];
localizedStringWithFormat:NSLocalizedString(@"%lu magnetized transfers", "Inspector -> selected torrents"), magnetCount];
}
[fileStrings addObject:magnetString];
}
@@ -606,7 +607,8 @@ typedef NS_ENUM(unsigned int, tabTag) {
}
else
{
fileString = [NSString stringWithFormat:NSLocalizedString(@"%lu files", "Inspector -> selected torrents"), fileCount];
fileString = [NSString
localizedStringWithFormat:NSLocalizedString(@"%lu files", "Inspector -> selected torrents"), fileCount];
}
basicString = [NSString stringWithFormat:@"%@, %@", fileString, basicString];
}