一个自定义视图弹出动画(目前支持三种弹出动画,开题报告,项目中用得比较多),只需要导入分类头文件调用弹出的方法即可完成弹出动画:
CustomAlertView *alert = [[CustomAlertView alloc] initWithFrame:CGRectMake(0, 0, 200, 200)];
可以控制背景的透明度,和是否有隐藏视图的效果(默认是有的)
CustomAlertView *alert = [[CustomAlertView alloc] initWithFrame:CGRectMake(0, 0, 200, 200)];
[alert showInWindowWithMode:CustomAnimationModeDrop bgAlpha:0.2 needEffectView:NO]; UIView *vi = [[UIApplication sharedApplication].keyWindow viewWithTag:TagValue]; vi.userInteractionEnabled = NO;Demo地址:https://github.com/aasdsjk/CustomAlertView