Re: Update and another question
Re: Update and another question
- Subject: Re: Update and another question
- From: Brian Webster <email@hidden>
- Date: Mon, 11 Mar 2002 15:41:01 -0600
On Monday, March 11, 2002, at 03:27 PM, cocoa-dev-
email@hidden wrote:
Now, for my question. I've read every relevant part of the docs as far
as I can tell (and checked the list archives), so forgive me if this is
obvious. When the user initiates a drag in my app when the
window is in
the background, the window forces itself to the front as soon as he
clicks (I overrode setAcceptsFirstMouse: so the user can begin the drag
immediately though). Obviously, this can be rather annoying if one
intends to drag things from my app into the foreground app, so I want
the window to stay in the background if the user initiates a drag.
I know this is possible (Mail an Omniweb do it, among others) but for
the life of me I can't figure out how. So my question is... "How?" :-)
Take a look at -[NSApplication preventWindowOrdering]. If you
override your mouseDown: method and call this and then call
[super mouseDown:], this should prevent your window from coming
to the front for that event.
--
Brian Webster
email@hidden
http://homepage.mac.com/bwebster
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.