Re: Screensaver multiple monitor detect
Re: Screensaver multiple monitor detect
- Subject: Re: Screensaver multiple monitor detect
- From: Tommaso Pecorella <email@hidden>
- Date: Wed, 31 Oct 2001 21:48:47 +0100
At 19:03 -0500 30-10-2001, Jim Correia and Stiphane Sudre wrote:
Hi, I have a little problem.
I am writing a screensaver and I want to draw different things on
the monitor if I have more than one device.
Let me explain better: if the user has one monitor, then the saver
act normally, but if there are multiple monitors, I want to be able
to draw in a specific one or on all, but differently.
So my question is: how can I check on what monitor the saver is
actually running ?
NSWindow has a method to do so, but the ScreenSaver desn't have a
similar function (apparently).
ScreenSaverView is just a subclass of NSView so you should be able to say
[[self window] screen]
Thank you for the quick response , however it doesn't work, because
ScreenSaver doesn't have a window... As a matter of fact [self
window] returns "nil", so this method can't be applied.
Any other idea (other than to look inside NSWindow and copy the code) ?
Thank you, Tommaso ;-{))
--
--------------------------------------------------------------------------
Ing. Tommaso Pecorella
snail-mail: e-mail :
via del Pergolino 8/a
mailto:email@hidden
50139 Firenze - ITALY
RSA Key fingerprint = 232A D084 AD2F 7815 3D44 AFF0 AA52 A3AA
--------------------------------------------------------------------------