Re: Using an Applescript xcode plugin to access data from the folders under Groups&Files
Re: Using an Applescript xcode plugin to access data from the folders under Groups&Files
- Subject: Re: Using an Applescript xcode plugin to access data from the folders under Groups&Files
- From: Chris Espinosa <email@hidden>
- Date: Sat, 4 Jun 2005 08:39:27 -0700
On Jun 4, 2005, at 7:26 AM, Tommy Krul wrote: I'm trying to write an applescript xcode plugin that, when activated, displays the contents of one of the Smart Groups (thus one of the (smart) folders under Groups&Files) in its own table view (on a separate window). I managed to create the plug-in, the interface and connect all event handlers. But I don't know how to access data from the Groups&Files using applescript... Any ideas?
Try something like this:
tell application "Xcode" set theCollection to my collect(project document 1) end tell
to collect(theItem) tell application "Xcode" set rl to {} repeat with i in every item reference of theItem try set l to {name:name of i, contents:my collect(contents of i)} on error set l to {name:name of i, contents:contents of i} end try set end of rl to l end repeat end tell return rl end collect
This gives you a list of {name: "string", contents: <some Xcode object> | <list of contents of the object>} pairs.
You can't access SmartGroup contents this way, but this will give you all the actual project items and groups.
Chris |
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden