<preference>'s defaultValue is wrong for string or unichar prefs (due to valueFromPreferences)

NEW
Unassigned

Status

()

Toolkit
Preferences
11 years ago
11 years ago

People

(Reporter: John Mellor (Jomel), Unassigned)

Tracking

1.8 Branch
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

11 years ago
<preference> elements get their defaultValue [1] from valueFromPreferences [2], having set _useDefault to true. However valueFromPreferences ignores _useDefault (because it doesn't use _branch) when returning string or unichar prefs, so defaultValue will return the current value instead of the defaultValue.

This has been fixed on trunk by the patch to bug 296383 (accidentally, it seems). I could do a 1.8 branch patch if it was likely to be approved, otherwise I'm just logging this as a warning to people.

[1]: http://mxr.mozilla.org/mozilla1.8/source/toolkit/content/widgets/preferences.xml#240
[2]: http://mxr.mozilla.org/mozilla1.8/source/toolkit/content/widgets/preferences.xml#259
(In reply to comment #0)
> I could do a 1.8 branch patch if it was likely to be approved,

Filing a bug and then hoping it attracts the attention of people who might care about branch releases is unlikely to work... either attach a patch and request approval, if you think it's really worth fixing on the branch, or resolve this bug WONTFIX :)
You need to log in before you can comment on or make changes to this bug.