Re: Can I talk about iPhone SDK/API?
Re: Can I talk about iPhone SDK/API?
- Subject: Re: Can I talk about iPhone SDK/API?
- From: Alexander von Below <email@hidden>
- Date: Tue, 24 Nov 2009 15:34:49 +0100
Am 24.11.2009 um 14:33 schrieb lbland:
> I agree with that too but also API and tools intersect. For example, I notice IB can bind (connect a control to) the action:
>
> - (IBAction)changeStuff
>
> as well as:
>
> - (IBAction)changeStuff:(id)sender
>
> I always use :(id)sender, so it seems that IB can do something that is new API. Is this new to IB and does the action method API now permit selectors without an argument?
RTFM:
"Defining Action Methods
In Cocoa applications, an action method takes a single parameter of type id and returns the type IBAction, which is defined as void. The name of the action method can be anything you want but is typically evocative of the action being performed. For example, to respond to a click in a button, you might define the following method in the controller object that manages the button:
- (IBAction)respondToButtonClick:(id)sender;
In Cocoa Touch applications, an action method can take one of three forms, shown here:
- (IBAction)respondToButtonClick;
- (IBAction)respondToButtonClick:(id)sender;
- (IBAction)respondToButtonClick:(id)sender forEvent:(UIEvent*)event;"
http://developer.apple.com/mac/library/documentation/DeveloperTools/Conceptual/IB_UserGuide/CodeIntegration/CodeIntegration.html
Alex
_______________________________________________
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