mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1176159 (part 1) - Remove pref_SaveTypes. r=bsmedberg.
Because SAVE_ALL is the only value ever used.
This commit is contained in:
parent
ec9df1cf53
commit
38c2aad78a
@ -960,7 +960,6 @@ Preferences::WritePrefFile(nsIFile* aFile)
|
||||
memset(valueArray, 0, gHashTable->EntryCount() * sizeof(char*));
|
||||
pref_saveArgs saveArgs;
|
||||
saveArgs.prefArray = valueArray;
|
||||
saveArgs.saveTypes = SAVE_ALL;
|
||||
|
||||
// get the lines that we're supposed to be writing to the file
|
||||
PL_DHashTableEnumerate(gHashTable, pref_savePref, &saveArgs);
|
||||
|
@ -343,13 +343,8 @@ pref_savePref(PLDHashTable *table, PLDHashEntryHdr *heh, uint32_t i, void *arg)
|
||||
pref->flags & PREF_STICKY_DEFAULT)) {
|
||||
sourcePref = &pref->userPref;
|
||||
} else {
|
||||
if (argData->saveTypes == SAVE_ALL_AND_DEFAULTS) {
|
||||
prefPrefix.AssignLiteral("pref(\"");
|
||||
sourcePref = &pref->defaultPref;
|
||||
}
|
||||
else
|
||||
// do not save default prefs that haven't changed
|
||||
return PL_DHASH_NEXT;
|
||||
// do not save default prefs that haven't changed
|
||||
return PL_DHASH_NEXT;
|
||||
}
|
||||
|
||||
// strings are in quotes!
|
||||
|
@ -19,12 +19,9 @@ class PrefSetting;
|
||||
}
|
||||
}
|
||||
|
||||
enum pref_SaveTypes { SAVE_NONSHARED, SAVE_SHARED, SAVE_ALL, SAVE_ALL_AND_DEFAULTS };
|
||||
|
||||
// Passed as the arg to pref_savePref
|
||||
struct pref_saveArgs {
|
||||
char **prefArray;
|
||||
pref_SaveTypes saveTypes;
|
||||
};
|
||||
|
||||
PLDHashOperator
|
||||
|
Loading…
Reference in New Issue
Block a user