Re: Cancel Sleep
Re: Cancel Sleep
- Subject: Re: Cancel Sleep
- From: David Elliott <email@hidden>
- Date: Tue, 1 Jan 2008 21:01:58 -0500
Hi Michael,
On Jan 1, 2008, at 8:22 PM, Michael Smith wrote:
On Jan 1, 2008, at 2:55 PM, David Elliott wrote:
What exactly is the reason for requiring the system to go to sleep
and then be woken up again?
Closing the clamshell is an explicit instruction from the user to
sleep the system.
No, it's not. It's only an instruction from me that I don't wish to
use the built-in display and keyboard anymore. I've at this point
already got external power, an external display, and an external
keyboard so it should be really obvious to even the most simple code
that I, the user, wish to keep the system awake. Why the hell would I
plug in all my peripherals, close the lid, and want the system to go
to sleep? I wouldn't.
Perhaps though you mistake my scenario (wanting to avoid a needless 1
second sleep) with the scenario that other people have which is to
allow the laptop to run without anything connected at all. I agree
that the OS should do all it can to prevent that, unless the user
installs extra software in which case.. hey.. the user knows what he's
doing.
That said, I shouldn't have to install extra software just to keep
closing the lid from sleeping the machine when I have stuff connected
to it. It should "just work" and it doesn't.
Your scenario is indistinguishable at the software level from my
daily routine, where I close the lid on my MBP, pull all the cables
from it and stuff it into my backpack. I don't stop to wait for it
to sleep, or manually sleep it; I expect that when I close the lid,
it will go to sleep and stay asleep.
Totally false. Your scenario involves pulling all the cables. My
scenario involves plugging them all in just before closing the lid.
Here is how I see your scenario playing out if lid close does not
sleep the system:
1. Close the lid
System realizes it has external peripherals (mains power, display,
keyboard) and remains on
2. Pull all the cables.
System realizes it's now no longer using mains power and goes to
sleep.
3. Stuff it in your backpack.
My scenario (leaving power and peripherals connected) and your
scenario (disconnecting everything) are easily distinguishable at the
software level. Perhaps you missed that I (unlike some of the other
people on this thread) do intend to keep mains power connected. I
agree with you that if no peripherals are connected then indeed the
scenario is indistinguishable to the machine. And of course in that
case it is better safe than sorry.
Oh, and by the way: Step 2 (pull out all the cables) puts my machine
to sleep already. So it's really just a matter of modifying the lid
close handler to check for power and peripherals. If they are
disconnected after lid close, the machine will go to sleep, and that
code already exists.
-Dave
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden