Alert controller with icon, have fun.
- Add
pod 'MCIconAlertController', '~> 0.0.1'to your Podfile. - Run
pod installorpod update. - Import <MCIconAlertController.h>.
- Add
github "chucklab/MCIconAlertController"to your Cartfile. - Run
carthage update --platform iosand add the framework to your project. - Import <MCIconAlertController/MCIconAlertController.h>.
MCIconAlertController *iconAlertController = [[MCIconAlertController alloc] init];
iconAlertController.iconImage = [UIImage imageNamed:@"dog.jpg"];
iconAlertController.title = @"Rigo";
iconAlertController.message = @"Hello there, how are you!";
iconAlertController.leftButtonTitle = @"Accept";
iconAlertController.rightButtonTitle = @"Ignore";
iconAlertController.leftButtonTappedBlock = ^(){
NSLog(@"leftButtonTappedBlock");
};
iconAlertController.rightButtonTappedBlock = ^(){
NSLog(@"rightButtonTappedBlock");
};
[iconAlertController show];This library requires a deployment target of iOS 6.0 or greater.
MCIconAlertController is provided under the MIT license. See LICENSE file for details.