测试测试 | ✗ |
语言语言 | Obj-CObjective C |
许可证 | MIT |
发布最新发布 | 2015年2月 |
由 Francis Visoiu Mistrih 维护。
适用于 iOS SDK 的自定义 AlertView。
要运行示例项目,首先克隆仓库,然后在 FVCustomAlertView-Example 目录下运行 pod install
。
将 .xcodeproj 文件拖入您的 Xcode 项目,并将其添加为构建阶段中的目标。不要忘记在“链接二进制与库”中添加 libFVCustomAlertView.a,并在“其他链接器标志”中设置 -ObjC 标志。
将以下文件和文件夹添加到您的 iOS 项目中。
FVCustomAlertView 提供 4 种默认模式和一种自定义模式。默认模式包括:(请确保您在示例应用程序中尝试它们)
[FVCustomAlertView showDefaultLoadingAlertOnView:self.view withTitle:@"Loading..." withBlur:YES];
[FVCustomAlertView showDefaultDoneAlertOnView:self.view withTitle:@"Done" withBlur:YES];
[FVCustomAlertView showDefaultErrorAlertOnView:self.view withTitle:@"Error" withBlur:YES];
[FVCustomAlertView showDefaultWarningAlertOnView:self.view withTitle:@"Be careful" withBlur:YES];
UIView *sw = [[UISwitch alloc] init];
[FVCustomAlertView showAlertOnView:self.view withTitle:@"Do you want to recieve notifications from us?"titleColor:[UIColor whiteColor] width:120 height:140 blur:YES backgroundImage:nil backgroundColor:[UIColor blackColor] cornerRadius:20 shadowAlpha:0.2 alpha:0.8 contentView:sw type:FVAlertTypeCustom];
可以使用以下方法检索当前视图
+ (UIView *)currentView;
添加了模糊选项,使用 UIBlurEffect
。 iOS8+ 仅限。
Francis Visoiu Mistrih http://francisvm.com/
本代码根据 MIT 许可证的条款和条件进行分发。