12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394 |
- #import <UIKit/UIKit.h>
- typedef NS_ENUM(NSInteger, AHKActionSheetButtonType) {
- AHKActionSheetButtonTypeDefault = 0,
- AHKActionSheetButtonTypeDisabled,
- AHKActionSheetButtonTypeDestructive,
- AHKActionSheetButtonTypeEncrypted
- };
- @class AHKActionSheet;
- typedef void(^AHKActionSheetHandler)(AHKActionSheet *actionSheet);
- @interface AHKActionSheet : UIView <UIAppearanceContainer>
- @property (nonatomic) CGFloat buttonHeight UI_APPEARANCE_SELECTOR;
- @property (nonatomic) CGFloat cancelButtonHeight UI_APPEARANCE_SELECTOR;
- @property (nonatomic) CGFloat separatorHeight UI_APPEARANCE_SELECTOR;
- @property (strong, nonatomic) NSNumber *automaticallyTintButtonImages UI_APPEARANCE_SELECTOR;
- @property (strong, nonatomic) NSNumber *buttonTextCenteringEnabled UI_APPEARANCE_SELECTOR;
- @property (strong, nonatomic) UIColor *separatorColor UI_APPEARANCE_SELECTOR;
- @property (copy, nonatomic) NSDictionary *buttonTextAttributes UI_APPEARANCE_SELECTOR;
- @property (copy, nonatomic) NSDictionary *disableButtonTextAttributes UI_APPEARANCE_SELECTOR;
- @property (copy, nonatomic) NSDictionary *destructiveButtonTextAttributes UI_APPEARANCE_SELECTOR;
- @property (copy, nonatomic) NSDictionary *encryptedButtonTextAttributes UI_APPEARANCE_SELECTOR;
- @property (copy, nonatomic) NSDictionary *cancelButtonTextAttributes UI_APPEARANCE_SELECTOR;
- @property (nonatomic) NSTimeInterval animationDuration UI_APPEARANCE_SELECTOR;
- @property (strong, nonatomic) NSNumber *cancelOnPanGestureEnabled UI_APPEARANCE_SELECTOR;
- @property (strong, nonatomic) NSNumber *cancelOnTapEmptyAreaEnabled UI_APPEARANCE_SELECTOR;
- @property (strong, nonatomic) AHKActionSheetHandler cancelHandler;
- @property (copy, nonatomic) NSString *cancelButtonTitle;
- @property (copy, nonatomic) NSString *title;
- @property (strong, nonatomic) UIView *headerView;
- @property (weak, nonatomic, readonly) UIWindow *previousKeyWindow;
- @property (nonatomic, weak) UIView *view;
- @property CGFloat bottomPadding;
- - (instancetype)initWithView:(UIView *)view title:(NSString *)title;
- - (void)addButtonWithTitle:(NSString *)title image:(UIImage *)image backgroundColor:(UIColor *)backgroundColor height:(CGFloat)height type:(AHKActionSheetButtonType)type handler:(AHKActionSheetHandler)handler;
- - (void)show;
- - (void)dismissAnimated:(BOOL)animated;
- @end
|