Re: AppleScript-ObjC Bridge Question
Re: AppleScript-ObjC Bridge Question
- Subject: Re: AppleScript-ObjC Bridge Question
- From: Shane Stanley <email@hidden>
- Date: Mon, 02 Nov 2015 09:45:23 +1100
On 2 Nov 2015, at 12:59 AM, Dave <email@hidden> wrote:
>
> Yes, I was looking at it, but I’m confused how it knows the difference between self and super?
I misread you code. If you really want to do this:
-(void) initWithParam:(NSString*) theParam
{
self = [self initWithParam:theParam andAnotherParam:nil];
if (self == nil)
return;
// Do something
return self;
}
Then try something like:
on initWithParam:theParam
my initWithParam:theParam andAnotherParam:(missing value)
-- do something
return me
end init
Only use continue if the method is also defined in the AS class.
But unless you have to init the subclass that way, it would be a lot simpler to do a simple alloc()'s init(), and then set the (inherited) properties of the result.
--
Shane Stanley <email@hidden>
<www.macosxautomation.com/applescript/apps/>
_______________________________________________
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