Bug 392407: appstrings.properties should not be using branded strings r+sr=bzbarsky, ui-r=beltzner, a=blocking1.9

This commit is contained in:
2008-01-05 05:40:46 -08:00
parent a506adf6ad
commit 8dfca73d13
3 changed files with 15 additions and 9 deletions
+12 -5
View File
@@ -8644,13 +8644,20 @@ nsDocShell::ConfirmRepost(PRBool * aRepost)
nsXPIDLString brandName;
rv = brandBundle->GetStringFromName(NS_LITERAL_STRING("brandShortName").get(),
getter_Copies(brandName));
if (NS_FAILED(rv)) return rv;
const PRUnichar *formatStrings[] = { brandName.get() };
nsXPIDLString msgString, button0Title;
rv = appBundle->FormatStringFromName(NS_LITERAL_STRING("confirmRepost").get(),
formatStrings, NS_ARRAY_LENGTH(formatStrings),
getter_Copies(msgString));
if (NS_FAILED(rv)) { // No brand, use the generic version.
rv = appBundle->GetStringFromName(NS_LITERAL_STRING("confirmRepostPrompt").get(),
getter_Copies(msgString));
}
else {
// Brand available - if the app has an override file with formatting, the app name will
// be included. Without an override, the prompt will look like the generic version.
const PRUnichar *formatStrings[] = { brandName.get() };
rv = appBundle->FormatStringFromName(NS_LITERAL_STRING("confirmRepostPrompt").get(),
formatStrings, NS_ARRAY_LENGTH(formatStrings),
getter_Copies(msgString));
}
if (NS_FAILED(rv)) return rv;
rv = appBundle->GetStringFromName(NS_LITERAL_STRING("resendButton.label").get(),