-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathEHAlertView.h
More file actions
38 lines (32 loc) · 1.24 KB
/
EHAlertView.h
File metadata and controls
38 lines (32 loc) · 1.24 KB
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
31
32
33
34
35
36
37
38
//
// EHAlertView.h
//
// Created by Antoine Marcadet on 28/09/11.
// Copyright 2011 Antoine Marcadet. All rights reserved.
//
// Permission is given to use this source code file without charge in any
// project, commercial or otherwise, entirely at your risk, with the condition
// that any redistribution (in part or whole) of source code must retain
// this copyright and permission notice. Attribution in compiled projects is
// appreciated but not required.
//
#import <UIKit/UIKit.h>
#if NS_BLOCKS_AVAILABLE
typedef void (^EHAlertBasicBlock)(void);
typedef void (^EHAlertButtonBlock)(NSInteger buttonIndex);
#endif
@interface EHAlertView : UIAlertView <UIAlertViewDelegate>
{
#if NS_BLOCKS_AVAILABLE
EHAlertButtonBlock willDismissButtonBlock;
EHAlertButtonBlock clickedButtonBlock;
EHAlertButtonBlock didDismissButtonBlock;
#endif
}
- (id)initWithTitle:(NSString *)title message:(NSString *)message cancelButtonTitle:(NSString *)cancelButtonTitle otherButtonTitles:(NSString *)otherButtonTitles, ... NS_REQUIRES_NIL_TERMINATION;
#if NS_BLOCKS_AVAILABLE
- (void)setWillDismissButtonBlock:(EHAlertButtonBlock)block;
- (void)setClickedButtonBlock:(EHAlertButtonBlock)block;
- (void)setDidDismissButtonBlock:(EHAlertButtonBlock)block;
#endif
@end