forked from AliSoftware/OHAlertView-OHActionSheet
-
Notifications
You must be signed in to change notification settings - Fork 0
/
UIAlertViewEx.h
49 lines (38 loc) · 1.52 KB
/
UIAlertViewEx.h
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
39
40
41
42
43
44
45
46
47
48
49
//
// UIAlertViewEx.h
// FoodReporter
//
// Created by Olivier on 30/12/10.
// Copyright 2010 FoodReporter. All rights reserved.
//
#import <Foundation/Foundation.h>
@class UIAlertViewEx;
@interface UIAlertViewEx : UIAlertView<UIAlertViewDelegate> {
@private
NSDictionary* _userInfo;
#if NS_BLOCKS_AVAILABLE
void (^_completionBlock)(UIAlertViewEx*,NSInteger);
#endif
id<UIAlertViewDelegate> _finalDelegate;
SEL _finalSelector;
}
/////////////////////////////////////////////////////////////////////////////
#if NS_BLOCKS_AVAILABLE
+(void)showAlertWithTitle:(NSString *)title message:(NSString *)message
cancelButton:(NSString *)cancelButtonTitle
otherButtons:(NSArray *)otherButtonTitles
onButtonTapped:(void(^)(UIAlertViewEx* alert, NSInteger buttonIndex))completion;
// Commodity method
+(void)showAlertWithTitle:(NSString *)title message:(NSString *)message
cancelButton:(NSString *)cancelButtonTitle
okButton:(NSString *)okButton // same as using a 1-item array for otherButtons
onButtonTapped:(void(^)(UIAlertViewEx* alert, NSInteger buttonIndex))completion;
-(id)initWithTitle:(NSString *)title message:(NSString *)message
cancelButton:(NSString *)cancelButtonTitle
otherButtons:(NSArray *)otherButtonTitles
onButtonTapped:(void(^)(UIAlertViewEx* alert, NSInteger buttonIndex))completion;
#endif
-(void)setDelegate:(id)aDelegate didDismissSelector:(SEL)aSelector;
@property(nonatomic, retain) NSDictionary* userInfo;
/////////////////////////////////////////////////////////////////////////////
@end