Type Method

systemButtonWithImage:target:action:

Creates and returns a system type button with specified image, target, and action.

Declaration

+ (instancetype)systemButtonWithImage:(UIImage *)image target:(id)target action:(SEL)action;

Parameters

image

The image for a system button.

target

The object that receives the action message.

action

The action to send to target when this item is selected.

Discussion

This method is a convenience constructor for creating a UIButtonTypeSystem type button objects with a specific target and action.

See Also

Creating Buttons

+ buttonWithType:

Creates and returns a new button of the specified type.

UIButtonType

Specifies the style of a button.