• 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: Size limit on Xcode projects?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Size limit on Xcode projects?


  • Subject: Re: Size limit on Xcode projects?
  • From: Brian Christmas <email@hidden>
  • Date: Tue, 27 Nov 2012 21:32:54 +1100

Thank you very, very much Shane, I've got it working now.

Regards

Santa


On 27/11/2012, at 9:02 PM, Shane Stanley <email@hidden> wrote:

On 27/11/2012, at 7:06 PM, Brian Christmas <email@hidden> wrote:

> You were right, I've tried to build an ObjC project  out of my applescript, and quickly ran out of room. Nasty results!
>
> I  can split the script into two quite easily, but even after reading your book, I'm not sure about the following..
>
> What initializing code do I need to add to the second script? It will be purely a collection of handlers that the main script needs to access.

You can just put them in a separate script file.
>
> 1. How do I go about calling the handlers?

Let's say the second class file is called Misc.applescript. You can call its handlers as class methods like this:

set x to current application's Misc's doSomething_(y)

You have to follow the Cocoa naming convention of one underscore per argument, and you have to coerce the values at each end. So if doSomething takes a string, it would usually need to start:

on doSomething_(y)
set y to y as text
...

And if the value returned is a string you need to coerce x to a string, like:

set x to current application's Misc's doSomething_(y) as text


> 2. How doI pass parameters  to the second script?

See above.
>
> 3. I've been though your book twice, and I think page 183 is what I need, but can't understand how to progress.

More like pages 181-182. And chapter 7 covers how to create the second class file in some detail.

--
Shane Stanley <email@hidden>
'AppleScriptObjC Explored' <www.macosxautomation.com/applescript/apps/>



 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

References: 
 >Size limit on Xcode projects? (From: Brian Christmas <email@hidden>)
 >Re: Size limit on Xcode projects? (From: Shane Stanley <email@hidden>)
 >Re: Size limit on Xcode projects? (From: Shane Stanley <email@hidden>)
 >Re: Size limit on Xcode projects? (From: Brian Christmas <email@hidden>)
 >Re: Size limit on Xcode projects? (From: Shane Stanley <email@hidden>)

  • Prev by Date: Re: Xcode Installation
  • Next by Date: Re: Simple script used to work, not now
  • Previous by thread: Re: Size limit on Xcode projects?
  • Next by thread: how to add a file to my Xcode project using AS
  • Index(es):
    • Date
    • Thread