PWAlertController 0.1.4

PWAlertController 0.1.4

测试已测试
语言 Obj-CObjective C
许可 MIT
发布最后发布2016年4月

wangweicheng 维护。



  • 作者:
  • Paul Wang

用法

要运行示例项目,请克隆仓库,然后在 Example 目录中首先运行 pod install。非常容易使用

PWAlertController *alert = [PWAlertController sheetWithTitle:nil cancelButtonTitle:@"取消" destructiveButtonTitle:@"删除" buttonClicked:^(NSUInteger index) {
    NSLog(@"alert selected at index:%ld", index);
} otherButtonTitles:@"标题一",@"标题二",@"标题三",nil];
[self presentViewController:alert animated:YES completion:^{

}];

iOS 7 下,需要在 [self presentViewController:alert animation:YES completion:nil]; 前面添加一句 self.modalPresentationStyle = UIModalPresentationCurrentContext;

要求

安装

PWAlertController 通过 CocoaPods 提供。要安装它,只需将以下行添加到您的 Podfile 中

pod "PWAlertController"

作者

Paul Wang, b7banana">[email protected]

许可

PWAlertController 根据 MIT 许可提供。有关更多信息,请参阅 LICENSE 文件。