iPhone UIButton with UISwitch functionality

UIButton already supports a “switch” functionality.

Just set a different image in Interface Builder for the “Selected State Configuration”, and use the selected property of UIButton to toggle its state.

Leave a Comment