Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Assuming ARC is enabled.
- // |button| is of type UIButton (works with NSButton as well).
- [button addTarget:[^{ NSLog(@"Block invoked."); } copy]
- action:@selector(invoke)
- forControlEvents:UIControlEventTouchUpInside];
Add Comment
Please, Sign In to add comment