Re: NSMovieView blocks Energy Saver
Re: NSMovieView blocks Energy Saver
- Subject: Re: NSMovieView blocks Energy Saver
- From: Michael Diehr <email@hidden>
- Date: Sat, 23 Oct 2004 14:39:29 -0700
On samedi, octobre 23, 2004, at 09:35 PM, Michael Diehr wrote:
I'm using a NSMovieView inside a ScreenSaverView to play back
quicktime movies. It works fine, but I notice two significant
problems:
1. the NSMovieView captures mouse clicks and key presses (so that
if the user hits the space bar or clicks in the window, instead of
exiting the screensaver the movie simply pauses).
Override the mouseDown: and keyDown: methods in a subclass of NSMovieView?
You can find some source code doing this here (though I don't
prevent space bar hits):
http://s.sudre.free.fr/Software/SaveHollywood.html
Thank you!
2. The energy saver will never kick in when the movie is playing.
Is there any way to tell QuickTime and/or the Energy Saver control
panel to honor energy saving settings while a NSMovieView is
playing?
This is a "feature" which was introduced in Mac OS X 10.1 because
someone discovered that when you were watching a long QuickTime
movie, it was not great to have the computer go to sleep during the
show.
Last time I asked the question on the QuickTime mailing list, I saw
no answer. I didn't find a clue in the QuickTime documentation when
I had a look at it but this was sometimes ago.
I understand the reasoning for having screensaver or energy saver
start when you are manually watching a video, but when the
screensaver itself IS the video, that just seems wrong to me.
Apple should fix this. Lots of electricity being wasted.
I wonder if there is a work-around? Perhaps before I start the
movie playback in the screensaver, I could read the system energy
saver settings, and then automatically stop movie playback at the
correct time? For example, if the computer is set to "Sleep after X
minutes", I could have the screensaver pause or quit the movie
playback after X+1 minutes. I wonder if this would then allow the
energy saver to start on time?
Does anyone know the API for reading the energy saver settings? Or,
are there energy saver calls to say "Force energy saver to start now"?
thx
-mike
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden