Closed Bug 953311 Opened 6 years ago Closed 6 years ago

nsIdleService.idl and .cpp comments are incorrect

Categories

(Core :: Widget, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla29

People

(Reporter: rnewman, Assigned: mak)

References

Details

Attachments

(1 file)

http://mxr.mozilla.org/mozilla-central/source/widget/nsIIdleService.idl

40      * @note
41      * The subject of the notification the observer will get is always the
42      * nsIIdleService itself.
43      * When the user goes idle, the observer topic is "idle" and when they get
44      * back, the observer topic is "back".
45      * The data param for the notification contains the current user idle time.

widget/xpwidgets/nsIdleService.cpp
581:  // Now send "back" events to all, if any should have timed out allready, then

vs

https://developer.mozilla.org/en-US/docs/XPCOM_Interface_Reference/nsIIdleService

"and receive a 'back' (Gecko 3 to 15) or 'active' (Gecko 16+) notification when the user starts using their computer again."

See also: Bug 953282. When this changed, nobody updated Sync, and perhaps other consumers, too. I see this in Places:

toolkit/components/places/nsPlacesExpiration.js
39:const TOPIC_IDLE_END = "back";
Blocks: 953312
Blocks: 953282
Depends on: 715041
Depends on: 957585
Attached patch fix commentsSplinter Review
Assignee: nobody → mak77
Status: NEW → ASSIGNED
Attachment #8357120 - Flags: review?(gsvelto)
Comment on attachment 8357120 [details] [diff] [review]
fix comments

I'm no widget peer so I'm unsure if my review is enough but considering it's comments only it shouldn't hurt.

I've grepped around to see if there were still uses of the old event and found only what's already been reported as bug 953312.
Attachment #8357120 - Flags: review?(gsvelto) → review+
Considered it's comment only and nobody complained about a patch landing without SR that broke all of the consumers...
https://hg.mozilla.org/mozilla-central/rev/d19f386b9061
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Blocks: 715041
No longer blocks: 953282, 953312
No longer depends on: 715041, 957585
You need to log in before you can comment on or make changes to this bug.