Closed
Bug 562599
Opened 14 years ago
Closed 14 years ago
Add an event to notify that Addon.applyBackgroundUpdates has changed
Categories
(Toolkit :: Add-ons Manager, defect, P1)
Toolkit
Add-ons Manager
Tracking
()
VERIFIED
FIXED
mozilla2.0b2
Tracking | Status | |
---|---|---|
blocking2.0 | --- | beta2+ |
People
(Reporter: Unfocused, Assigned: mossop)
References
Details
(Keywords: APIchange, Whiteboard: [rewrite])
Attachments
(1 file)
4.23 KB,
patch
|
robert.strong.bugs
:
review+
|
Details | Diff | Splinter Review |
Currently, there's no way of listening for when addon.applyBackgroundUpdates changes. Would be great to have an event, either specific to this property, or a generic one that passes a list of what properties changed.
Updated•14 years ago
|
Flags: in-testsuite?
Reporter | ||
Updated•14 years ago
|
Assignee | ||
Comment 1•14 years ago
|
||
What do we lose by not having this Blair?
Reporter | ||
Comment 2•14 years ago
|
||
Without this, we can't guarantee the automatic updates checkbox for each addon is in sync (without constant polling, that is). Mostly important with multiple copies of about:addons open, but other things could potentially change it too (thinking extensions - like the Tor addon disabling automatic updates for itself). Not needed for beta 1, but its something I want to be able to do before final. We could make this a miscellaneous catch-all event for other properties that don't have events either. addon.blocklistState comes to mind. Something like onPropertyChanged(aAddon, aProperty)
Assignee | ||
Comment 3•14 years ago
|
||
Ah yeah I hadn't thought about the multiple tabs case much, makes sense.
blocking2.0: ? → final+
Assignee | ||
Updated•14 years ago
|
blocking2.0: final+ → beta2+
Whiteboard: [rewrite] → [rewrite][apichange]
Assignee | ||
Updated•14 years ago
|
Assignee: nobody → dtownsend
Assignee | ||
Comment 4•14 years ago
|
||
Added as a generic property changed event that may be useful for other things in the future. The event is passed an array of property names that may have changed so we can dispatch a single event for multiple changes. Receivers should not assume that the named properties have actually changed since we may just want to dispatch this after some update method may or may not have made changes.
Attachment #455784 -
Flags: review?(robert.bugzilla)
Assignee | ||
Updated•14 years ago
|
Status: NEW → ASSIGNED
Updated•14 years ago
|
Attachment #455784 -
Flags: review?(robert.bugzilla) → review+
Assignee | ||
Comment 5•14 years ago
|
||
http://hg.mozilla.org/mozilla-central/rev/d8c1051908ad
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Flags: in-testsuite? → in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9.3b2
Comment 6•14 years ago
|
||
I would tend to say it should only be an automated test.
Flags: in-litmus-
Version: unspecified → Trunk
Comment 7•14 years ago
|
||
Verified fixed based on check-in and passing tests.
Status: RESOLVED → VERIFIED
Reporter | ||
Comment 8•14 years ago
|
||
(In reply to comment #4) > Receivers should not assume that > the named properties have actually changed since we may just want to dispatch > this after some update method may or may not have made changes. Just as a for-the-record followup: Discussed this with Dave, and its best if consumers can rely on onPropertyChanged meaning that properties did in fact change. So the API *will* guarantee that properties changed, and consumers *can assume* that the properties changed. This was already the case for applyBackgroundUpdates, but any use of onPropertyChanged in the future will also need to guarantee this.
You need to log in
before you can comment on or make changes to this bug.
Description
•