RE: Move window to second display

2008-07-16 Thread Gary L. Wade
Try breaking out the call path to examine each succeeding value when assigning a value to display. One thing that jumps out at me: are you running this in 64-bit mode? The size of an int in 64-bit mode is 32 bits but a CGDirectDisplayID may have 64 significant bits as it's technically a point

Re: Move window to second display

2008-07-16 Thread Scott Ribe
> So what's wrong with the code then? I got nothing ;-( It actually looks correct to me. -- Scott Ribe [EMAIL PROTECTED] http://www.killerbytes.com/ (303) 722-0567 voice ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admi

Re: Move window to second display

2008-07-16 Thread Fabian
Hum, OK. Thanks to both of you. So what's wrong with the code then? On Wed, Jul 16, 2008 at 6:36 PM, Jean-Daniel Dupas <[EMAIL PROTECTED]> wrote: > > Le 16 juil. 08 à 18:15, Scott Ribe a écrit : > >>> The window frame origin is a position relative to the screen origin. >>> >>> Try this: >>> >>> sc

Re: Move window to second display

2008-07-16 Thread Jean-Daniel Dupas
Le 16 juil. 08 à 18:15, Scott Ribe a écrit : The window frame origin is a position relative to the screen origin. Try this: screenRect.origin = NSZeroPoint; [win setFrame:screenRect display:YES]; No, that will just position the window on the main screen. If the window frame origin were re

Re: Move window to second display

2008-07-16 Thread Scott Ribe
> The window frame origin is a position relative to the screen origin. > > Try this: > > screenRect.origin = NSZeroPoint; > [win setFrame:screenRect display:YES]; No, that will just position the window on the main screen. If the window frame origin were relative to the screen origin rather than

Re: Move window to second display

2008-07-16 Thread Fabian
Thanks Jean-Daniel, I will try that. F. On Wed, Jul 16, 2008 at 1:21 PM, Jean-Daniel Dupas <[EMAIL PROTECTED]> wrote: > > Le 16 juil. 08 à 13:01, Fabian a écrit : > >> Hi, >> >> I only have one monitor, so I'm having a bit of a problem figuring this >> out. >> >> I have a (borderless) window that

Re: Move window to second display

2008-07-16 Thread Jean-Daniel Dupas
Le 16 juil. 08 à 13:01, Fabian a écrit : Hi, I only have one monitor, so I'm having a bit of a problem figuring this out. I have a (borderless) window that should be displayed on any display chosen by the user. I figured the code below would do the trick, but apparently it's a no go (I use