-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathWDAlertView.h
More file actions
30 lines (22 loc) · 886 Bytes
/
WDAlertView.h
File metadata and controls
30 lines (22 loc) · 886 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
//
//
// Created by Jian Yin Shen on 17/09/12.
//
//
#import <UIKit/UIKit.h>
typedef void(^WDAlertViewButtonClickBlock)(UIAlertView* alert_view, NSInteger button_index);
/*
* Extension that allows use of alert view in block form
*/
@interface WDAlertView : UIAlertView <UIAlertViewDelegate>
- (id)initWithTitle:(NSString *)title
message:(NSString *)message
dismissBlock:(WDAlertViewButtonClickBlock)block
cancelButtonTitle:(NSString *)cancelButtonTitle
otherButtonTitles:(NSString *)otherButtonTitles, ...NS_REQUIRES_NIL_TERMINATION;
+ (void)showAlertViewWithTitle:(NSString *)title
message:(NSString *)message
dismissBlock:(WDAlertViewButtonClickBlock)block
cancelButtonTitle:(NSString *)cancelButtonTitle
otherButtonTitles:(NSString *)otherButtonTitles, ...NS_REQUIRES_NIL_TERMINATION;
@end