mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-11 01:57:00 +00:00
To reduce confusion, read preferences.js for UNIX, prefs.js for Win/Mac, M3 bug #2343, approved dp
This commit is contained in:
parent
53b3380a59
commit
4113a96d6e
@ -28,6 +28,10 @@
|
||||
#include "nsIServiceManager.h"
|
||||
#include "nsCOMPtr.h"
|
||||
|
||||
#ifdef PREF_USE_SYSDIR
|
||||
#include "nsSpecialSystemDirectory.h" // For exe dir
|
||||
#endif /* PREF_USE_SYSDIR */
|
||||
|
||||
static NS_DEFINE_IID(kIPrefIID, NS_IPREF_IID);
|
||||
static NS_DEFINE_CID(kPrefCID, NS_PREF_CID);
|
||||
|
||||
@ -198,7 +202,19 @@ nsPref::useDefaultPrefFile(nsPref *aPrefInst)
|
||||
if (!aPrefInst)
|
||||
return;
|
||||
|
||||
#ifdef PREF_USE_SYSDIR
|
||||
nsSpecialSystemDirectory sysDir(nsSpecialSystemDirectory::OS_CurrentProcessDirectory);
|
||||
sysDir += "prefs.js";
|
||||
nsFilePath prefPath(sysDir);
|
||||
/* incomplete */
|
||||
#endif /* PREF_USE_SYSDIR */
|
||||
|
||||
|
||||
#ifdef XP_UNIX
|
||||
aPrefInst->Startup("preferences.js");
|
||||
#else /* all others XP_WIN && XP_MAC */
|
||||
aPrefInst->Startup("prefs.js");
|
||||
#endif
|
||||
|
||||
return;
|
||||
}
|
||||
|
@ -957,7 +957,11 @@ pref_CompareStrings (const void *v1, const void *v2)
|
||||
PR_IMPLEMENT(PRBool)
|
||||
pref_useDefaultPrefFile(void)
|
||||
{
|
||||
#ifdef XP_UNIX
|
||||
return PREF_Init("preferences.js");
|
||||
#else /* all others XP_WIN && XP_MAC */
|
||||
return PREF_Init("prefs.js");
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
@ -957,7 +957,11 @@ pref_CompareStrings (const void *v1, const void *v2)
|
||||
PR_IMPLEMENT(PRBool)
|
||||
pref_useDefaultPrefFile(void)
|
||||
{
|
||||
#ifdef XP_UNIX
|
||||
return PREF_Init("preferences.js");
|
||||
#else /* all others XP_WIN && XP_MAC */
|
||||
return PREF_Init("prefs.js");
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user