• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Activating applications
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

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

References: 
 >Activating applications (From: Michael Watson <email@hidden>)

  • Prev by Date: Re: Activating applications
  • Next by Date: Re: nstask with admin privs
  • Previous by thread: Re: Activating applications
  • Next by thread: Strange use of files in the Trash
  • Index(es):
    • Date
    • Thread