口袋优选

CCAlertShowView.h 901B

1234567891011121314151617181920212223242526272829303132333435
  1. //
  2. // CCAlertShowView.h
  3. // ProjectManager
  4. //
  5. // Created by 小花 on 2017/1/18.
  6. // Copyright © 2017年 vaic. All rights reserved.
  7. //
  8. #import <UIKit/UIKit.h>
  9. @interface CCAlertShowView : UIView
  10. @property (nonatomic, weak, readonly) UIView *alertView;
  11. @property (nonatomic, strong) UIView *backgroundView;
  12. // Default is 15
  13. @property (nonatomic, assign) CGFloat alertViewMargin;
  14. // Default centerY
  15. @property (nonatomic, assign) CGFloat alertOriginY;
  16. // 是否可以点击背景消失(默认为yes)
  17. @property (nonatomic, assign) BOOL tapBackgroundDismissEnable;
  18. @property (nonatomic, copy) void (^tapDismissBlock)(void);
  19. // 初始化
  20. + (instancetype)alertViewWithView:(UIView *)view;
  21. //显示方式
  22. + (instancetype)showAlertViewWithView:(UIView *)alertView backgroundDismissEnable:(BOOL)backgroundDismissEnable;
  23. - (void)show;
  24. - (void)showInView:(UIView *)superView;
  25. - (void)dismiss;
  26. @end