idle detection

Sean Egan seanegan at
Wed Jul 25 19:39:55 EDT 2007

In ticket #1357 which points to #1308 which happens to really hit the
nail on the head, some inadaquacies of our idle detection are pointed

1. The preference for "how long before going idle," is effectively
useless, as we only poll every 10 minutes (or when sending a
message---an act which itself resets the counter). While we do check
to see if the computer has been idle for the amount of time set in
that preference, we only check every 10 minutes, meaning that anything
less than 10 is effectively 10 minutes.

2. We come back from auto-away when we poll for idleness and determine
we're no longer idle. Again, this only occurs every 10 minutes. In
worst case, you'll contnue to be auto-away 10 minutes after coming
back. You'll continue to be away on average 5 minutes after you come
back (unless you send a message which triggers a poll automatically).

I've explicitly CCed Richard because he committed 1113 which seems to
have introduced this issue.

"* Make the 5 second "Am I idle for 10 minutes" timer only fire at the
time points"

It seems like perhaps the best thing to do is to make the IDLEMARK
constant, currently set to 10 minutes, use the value set in that
preference instead, and poll that frequently when not idle. When we
are idle, we should poll very frequently (once a second, even?) to
make sure we come back as soon as possible.

This negates some of the power-saving goals of #1113, but if polling
is the only way to determine idle time, that seems unavoidable.

Is polling the only way to determine idle time?

More information about the Devel mailing list