Closed Bug 758574 Opened 13 years ago Closed 11 years ago

Port |Bug 662178 - Simplify timed callbacks| to SeaMonkey

Categories

(SeaMonkey :: Sync UI, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
seamonkey2.25

People

(Reporter: sgautherie, Assigned: InvisibleSmiley)

References

Details

Attachments

(1 file)

No description provided.
I think the only thing we need to do is: http://hg.mozilla.org/mozilla-central/rev/f66e634eb6eb#l1.12 > - Utils.delay(function () { f(items[i], cb); }); > + Utils.nextTick(function () { f(items[i], cb); }); The rest is in toolkit. Jens is this still needed?
Flags: needinfo?(jh)
(In reply to Philip Chee from comment #1) > I think the only thing we need to do is: > http://hg.mozilla.org/mozilla-central/rev/f66e634eb6eb#l1.12 > > > - Utils.delay(function () { f(items[i], cb); }); > > + Utils.nextTick(function () { f(items[i], cb); }); > > The rest is in toolkit. Jens is this still needed? [You quoted the wrong part, though the link is correct.] Yes, still needed. Actually, I think our current code in syncQuota.js is broken. Looking at mozilla-central changeset f66e634eb6eb one would get the impression that delay() still existed, but somewhere between then and now, the namedTimer function declaration has been updated and "delay" been removed from it. So unless I'm mistaken, line 73 should throw an error right now.
Attached patch patchSplinter Review
Assignee: nobody → jh
Status: NEW → ASSIGNED
Attachment #826513 - Flags: review?(neil)
Comment on attachment 826513 [details] [diff] [review] patch > // The 'Weave' object will disappear once the window closes. > let Service = Weave.Service; >+ Weave.Utils.nextTick(function() { Service.sync(); }); r=me as it is an exact port of the browser code and will make further porting easier, but I just wanted to point out that a better way to write this would be Weave.Utils.nextTick(Weave.Service.sync, Weave.Service);
Attachment #826513 - Flags: review?(neil) → review+
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → seamonkey2.25
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: