зеркало из https://github.com/mozilla/pjs.git
Use CFBundleName string key wherever we refer to the app name in strings.
This commit is contained in:
Родитель
203848bedd
Коммит
f64cb004b9
|
@ -54,7 +54,7 @@ static CHAboutBox *sharedInstance = nil;
|
|||
return;
|
||||
}
|
||||
|
||||
[window setTitle:@"About Navigator"];
|
||||
[window setTitle:[NSString stringWithFormat: @"About %@", NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)]];
|
||||
|
||||
creditsPath = [[NSBundle mainBundle] pathForResource:@"Credits" ofType:@"rtf"];
|
||||
creditsString = [[NSAttributedString alloc] initWithPath:creditsPath documentAttributes:nil];
|
||||
|
|
|
@ -494,7 +494,7 @@ static const char* ioServiceContractID = "@mozilla.org/network/io-service;1";
|
|||
// popup.
|
||||
nsAlertController* controller = nsCocoaBrowserService::GetAlertController();
|
||||
BOOL confirm = [controller confirm: [self window] title: @"Unrequested Popup Detected"
|
||||
text: [NSString stringWithFormat: NSLocalizedString(@"PopupBlockMsg", @""), NSLocalizedString(@"Navigator", @"")]];
|
||||
text: [NSString stringWithFormat: NSLocalizedString(@"PopupBlockMsg", @""), NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)]];
|
||||
|
||||
// This is a one-time dialog.
|
||||
pref->SetBoolPref("browser.popups.showPopupBlocker", PR_FALSE);
|
||||
|
|
|
@ -166,8 +166,8 @@ app_getModuleInfo(nsStaticModuleInfo **info, PRUint32 *count);
|
|||
rv = profileService->SetCurrentProfile(newProfileName.get());
|
||||
if (NS_FAILED(rv)) {
|
||||
if (rv == NS_ERROR_FILE_ACCESS_DENIED) {
|
||||
NSString *alert = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningAlert", @""), NSLocalizedString(@"Navigator", @"")];
|
||||
NSString *message = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningMsg", @""), NSLocalizedString(@"Navigator", @"")];
|
||||
NSString *alert = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningAlert", @""), NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)];
|
||||
NSString *message = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningMsg", @""), NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)];
|
||||
NSString *quit = NSLocalizedString(@"AlreadyRunningButton",@"");
|
||||
NSRunAlertPanel(alert,message,quit,nil,nil);
|
||||
[NSApp terminate:self];
|
||||
|
|
|
@ -54,7 +54,7 @@ static CHAboutBox *sharedInstance = nil;
|
|||
return;
|
||||
}
|
||||
|
||||
[window setTitle:@"About Navigator"];
|
||||
[window setTitle:[NSString stringWithFormat: @"About %@", NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)]];
|
||||
|
||||
creditsPath = [[NSBundle mainBundle] pathForResource:@"Credits" ofType:@"rtf"];
|
||||
creditsString = [[NSAttributedString alloc] initWithPath:creditsPath documentAttributes:nil];
|
||||
|
|
|
@ -494,7 +494,7 @@ static const char* ioServiceContractID = "@mozilla.org/network/io-service;1";
|
|||
// popup.
|
||||
nsAlertController* controller = nsCocoaBrowserService::GetAlertController();
|
||||
BOOL confirm = [controller confirm: [self window] title: @"Unrequested Popup Detected"
|
||||
text: [NSString stringWithFormat: NSLocalizedString(@"PopupBlockMsg", @""), NSLocalizedString(@"Navigator", @"")]];
|
||||
text: [NSString stringWithFormat: NSLocalizedString(@"PopupBlockMsg", @""), NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)]];
|
||||
|
||||
// This is a one-time dialog.
|
||||
pref->SetBoolPref("browser.popups.showPopupBlocker", PR_FALSE);
|
||||
|
|
|
@ -166,8 +166,8 @@ app_getModuleInfo(nsStaticModuleInfo **info, PRUint32 *count);
|
|||
rv = profileService->SetCurrentProfile(newProfileName.get());
|
||||
if (NS_FAILED(rv)) {
|
||||
if (rv == NS_ERROR_FILE_ACCESS_DENIED) {
|
||||
NSString *alert = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningAlert", @""), NSLocalizedString(@"Navigator", @"")];
|
||||
NSString *message = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningMsg", @""), NSLocalizedString(@"Navigator", @"")];
|
||||
NSString *alert = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningAlert", @""), NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)];
|
||||
NSString *message = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningMsg", @""), NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)];
|
||||
NSString *quit = NSLocalizedString(@"AlreadyRunningButton",@"");
|
||||
NSRunAlertPanel(alert,message,quit,nil,nil);
|
||||
[NSApp terminate:self];
|
||||
|
|
|
@ -54,7 +54,7 @@ static CHAboutBox *sharedInstance = nil;
|
|||
return;
|
||||
}
|
||||
|
||||
[window setTitle:@"About Navigator"];
|
||||
[window setTitle:[NSString stringWithFormat: @"About %@", NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)]];
|
||||
|
||||
creditsPath = [[NSBundle mainBundle] pathForResource:@"Credits" ofType:@"rtf"];
|
||||
creditsString = [[NSAttributedString alloc] initWithPath:creditsPath documentAttributes:nil];
|
||||
|
|
|
@ -494,7 +494,7 @@ static const char* ioServiceContractID = "@mozilla.org/network/io-service;1";
|
|||
// popup.
|
||||
nsAlertController* controller = nsCocoaBrowserService::GetAlertController();
|
||||
BOOL confirm = [controller confirm: [self window] title: @"Unrequested Popup Detected"
|
||||
text: [NSString stringWithFormat: NSLocalizedString(@"PopupBlockMsg", @""), NSLocalizedString(@"Navigator", @"")]];
|
||||
text: [NSString stringWithFormat: NSLocalizedString(@"PopupBlockMsg", @""), NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)]];
|
||||
|
||||
// This is a one-time dialog.
|
||||
pref->SetBoolPref("browser.popups.showPopupBlocker", PR_FALSE);
|
||||
|
|
|
@ -166,8 +166,8 @@ app_getModuleInfo(nsStaticModuleInfo **info, PRUint32 *count);
|
|||
rv = profileService->SetCurrentProfile(newProfileName.get());
|
||||
if (NS_FAILED(rv)) {
|
||||
if (rv == NS_ERROR_FILE_ACCESS_DENIED) {
|
||||
NSString *alert = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningAlert", @""), NSLocalizedString(@"Navigator", @"")];
|
||||
NSString *message = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningMsg", @""), NSLocalizedString(@"Navigator", @"")];
|
||||
NSString *alert = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningAlert", @""), NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)];
|
||||
NSString *message = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningMsg", @""), NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)];
|
||||
NSString *quit = NSLocalizedString(@"AlreadyRunningButton",@"");
|
||||
NSRunAlertPanel(alert,message,quit,nil,nil);
|
||||
[NSApp terminate:self];
|
||||
|
|
|
@ -54,7 +54,7 @@ static CHAboutBox *sharedInstance = nil;
|
|||
return;
|
||||
}
|
||||
|
||||
[window setTitle:@"About Navigator"];
|
||||
[window setTitle:[NSString stringWithFormat: @"About %@", NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)]];
|
||||
|
||||
creditsPath = [[NSBundle mainBundle] pathForResource:@"Credits" ofType:@"rtf"];
|
||||
creditsString = [[NSAttributedString alloc] initWithPath:creditsPath documentAttributes:nil];
|
||||
|
|
|
@ -494,7 +494,7 @@ static const char* ioServiceContractID = "@mozilla.org/network/io-service;1";
|
|||
// popup.
|
||||
nsAlertController* controller = nsCocoaBrowserService::GetAlertController();
|
||||
BOOL confirm = [controller confirm: [self window] title: @"Unrequested Popup Detected"
|
||||
text: [NSString stringWithFormat: NSLocalizedString(@"PopupBlockMsg", @""), NSLocalizedString(@"Navigator", @"")]];
|
||||
text: [NSString stringWithFormat: NSLocalizedString(@"PopupBlockMsg", @""), NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)]];
|
||||
|
||||
// This is a one-time dialog.
|
||||
pref->SetBoolPref("browser.popups.showPopupBlocker", PR_FALSE);
|
||||
|
|
|
@ -166,8 +166,8 @@ app_getModuleInfo(nsStaticModuleInfo **info, PRUint32 *count);
|
|||
rv = profileService->SetCurrentProfile(newProfileName.get());
|
||||
if (NS_FAILED(rv)) {
|
||||
if (rv == NS_ERROR_FILE_ACCESS_DENIED) {
|
||||
NSString *alert = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningAlert", @""), NSLocalizedString(@"Navigator", @"")];
|
||||
NSString *message = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningMsg", @""), NSLocalizedString(@"Navigator", @"")];
|
||||
NSString *alert = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningAlert", @""), NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)];
|
||||
NSString *message = [NSString stringWithFormat: NSLocalizedString(@"AlreadyRunningMsg", @""), NSLocalizedStringFromTable(@"CFBundleName", @"InfoPlist", nil)];
|
||||
NSString *quit = NSLocalizedString(@"AlreadyRunningButton",@"");
|
||||
NSRunAlertPanel(alert,message,quit,nil,nil);
|
||||
[NSApp terminate:self];
|
||||
|
|
Загрузка…
Ссылка в новой задаче