Re: Activating applications
Re: Activating applications
- Subject: Re: Activating applications
- From: "Sean McBride" <email@hidden>
- Date: Fri, 12 Jan 2007 16:03:22 -0500
- Organization: Rogue Research
On 2007-01-12 15:11, Michael Watson said:
>Is there a Cocoa equivalent to AppleScript's "tell application
>"whatever" to activate" that brings all of an application's windows
>forward? Using -[NSWorkspace launchApplication:] will activate the
>application but only bring its frontmost window forward in the
>overall window stack.
To bring your own app to the front you can use NSApplication's
activateIgnoringOtherApps.
To bring an arbitrary app to the front you can use the Carbon function
SetFrontProcessWithOptions(). Look through Processes.h for how to get
an app's PSN.
--
____________________________________________________________
Sean McBride, B. Eng email@hidden
Rogue Research www.rogue-research.com
Mac Software Developer Montréal, Québec, Canada
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden