iOS 弹出框:JKAlertDialog

jopen 9年前

JKAlertDialog 类似 Android 中的 AlertDialog,可以指定任意的 View 显示在 Alert 弹出框中,样式和 ios UIAlertView 样式一致。

使用方法

JKAlertDialog *alert = [[JKAlertDialog alloc]initWithTitle:@"提示" message:@"你有新的消息"];  //alert.buttonWidth = 100;  //alert.contentView =  _table;    [alert addButtonWithTitle:@"确定"];    [alert addButton:Button_OTHER withTitle:@"取消" handler:^(JKAlertDialogItem *item) {      NSLog(@"click %@",item.title);  }];;  [alert addButton:Button_OTHER withTitle:@"ok" handler:^(JKAlertDialogItem *item) {      NSLog(@"click %@",item.title);    }];  [alert addButton:Button_OTHER withTitle:@"cancle" handler:^(JKAlertDialogItem *item) {      NSLog(@"click %@",item.title);    }];    [alert show];


项目主页:http://www.open-open.com/lib/view/home/1426819520476