• 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: enumerating the NSApplication instances?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: enumerating the NSApplication instances?


  • Subject: Re: enumerating the NSApplication instances?
  • From: Charles Steinman <email@hidden>
  • Date: Thu, 23 Oct 2008 11:47:37 -0700 (PDT)

--- On Thu, 10/23/08, Bill Janssen <email@hidden> wrote:

> Hi.  I'm trying to write a simple Cocoa program to
> enumerate the
> windows on the screen, across all the apps.  I can see how
> to use
> NSWorkspace.launchedApplications() to enumerate the apps,
> but I don't
> see how to go from those dictionaries to an instance of
> NSApplication,
> so that I can enumerate the application's windows.
>
> I'm sure this is perfectly simple, but I'm just not
> seeing it...

You can't get NSApplication instances for other applications. If you want get a list of all the windows on the system, take a look at CGWindow.h in Leopard. The CGWindowList* family of functions do what you want.

Cheers,
Chuck



_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please 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

  • Follow-Ups:
    • Re: enumerating the NSApplication instances?
      • From: Bill Janssen <email@hidden>
References: 
 >enumerating the NSApplication instances? (From: Bill Janssen <email@hidden>)

  • Prev by Date: Re: Controls disappearing from window during resize
  • Next by Date: Re: Controls disappearing from window during resize
  • Previous by thread: enumerating the NSApplication instances?
  • Next by thread: Re: enumerating the NSApplication instances?
  • Index(es):
    • Date
    • Thread