In some IBAction
I saw:
- (IBAction)pushButton:(id)sender;
This (id)sender
when do I use it?
(id)sender is the object which sent the message to that selector.
Code example:
- (IBAction)submitButton:(id)sender {
UIButton *button = (UIButton *)sender;
[button setEnabled:NO];
[button setTitle:@"foo" forState:UIControlStateDisabled];
}