mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-30 00:01:50 +00:00
Bug 310194: Change events can get fired multiple times for preference elements, patch by Dave Townsend <mossop@blueprintit.co.uk>, r=mconnor
This commit is contained in:
parent
fea7d4fb9c
commit
1b6d9f88d6
@ -35,7 +35,6 @@
|
||||
var preference = this.childNodes[i];
|
||||
if (preference.name == aData) {
|
||||
preference.value = preference.valueFromPreferences;
|
||||
this.fireChangedEvent(preference);
|
||||
}
|
||||
}
|
||||
]]>
|
||||
@ -138,13 +137,14 @@
|
||||
<parameter name="aUpdate"/>
|
||||
<body>
|
||||
<![CDATA[
|
||||
this._value = aValue;
|
||||
if (this.instantApply && aUpdate)
|
||||
this.valueFromPreferences = aValue;
|
||||
else if (aUpdate) {
|
||||
if (aUpdate && this.value != aValue) {
|
||||
this._value = aValue;
|
||||
if (this.instantApply)
|
||||
this.valueFromPreferences = aValue;
|
||||
this.preferences.fireChangedEvent(this);
|
||||
}
|
||||
else {
|
||||
else if (!aUpdate) {
|
||||
this._value = aValue;
|
||||
this.updateElements();
|
||||
}
|
||||
return aValue;
|
||||
|
Loading…
Reference in New Issue
Block a user