зеркало из https://github.com/mozilla/pjs.git
39790 : [L12y] Move all localizable prefs into chrome:// .r=morse
This commit is contained in:
Родитель
6a34171888
Коммит
cd8caee4f5
|
@ -195,6 +195,20 @@ SI_GetCharPref(const char * prefname, char** aPrefvalue) {
|
|||
}
|
||||
}
|
||||
|
||||
PUBLIC void
|
||||
SI_GetLocalizedUnicharPref(const char * prefname, PRUnichar** aPrefvalue) {
|
||||
nsresult ret;
|
||||
nsCOMPtr<nsIPref> pPrefService = do_GetService(kPrefServiceCID, &ret);
|
||||
if (!NS_FAILED(ret)) {
|
||||
ret = pPrefService->GetLocalizedUnicharPref(prefname, aPrefvalue);
|
||||
if (NS_FAILED(ret)) {
|
||||
*aPrefvalue = nsnull;
|
||||
}
|
||||
} else {
|
||||
*aPrefvalue = nsnull;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*********************************
|
||||
* Preferences for Single Signon *
|
||||
|
|
|
@ -98,6 +98,9 @@ SI_SetCharPref(const char * prefname, const char * prefvalue);
|
|||
extern void
|
||||
SI_GetCharPref(const char * prefname, char** aPrefvalue);
|
||||
|
||||
extern void
|
||||
SI_GetLocalizedUnicharPref(const char * prefname, PRUnichar** aPrefvalue);
|
||||
|
||||
extern void SI_InitSignonFileName();
|
||||
|
||||
extern PRBool
|
||||
|
|
|
@ -2276,7 +2276,13 @@ static void
|
|||
wallet_FetchFileForUseInNextBrowserSession() {
|
||||
|
||||
/* obtain the server from which to fetch the composite file to be used in next session */
|
||||
#if 1
|
||||
nsXPIDLString ustr;
|
||||
SI_GetLocalizedUnicharPref(pref_WalletServer, getter_Copies(ustr));
|
||||
wallet_Server = NS_ConvertUCS2toUTF8(ustr);
|
||||
#else
|
||||
SI_GetCharPref(pref_WalletServer, &wallet_Server);
|
||||
#endif
|
||||
if (!wallet_Server || (*wallet_Server == '\0')) {
|
||||
/* user does not want to download mapping tables */
|
||||
return;
|
||||
|
|
Загрузка…
Ссылка в новой задаче