-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathEAbstarctActionSheetPicker.h
executable file
·39 lines (30 loc) · 1.5 KB
/
EAbstarctActionSheetPicker.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
//
// EAbstarctActionSheetPicker.h
// eHealth
//
// Created by god on 13-4-21.
// Copyright (c) 2013年 god. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface EAbstarctActionSheetPicker : NSObject
@property (nonatomic, copy) NSString *title;
@property (nonatomic, retain) UIView *pickerView;
@property (nonatomic, readonly) CGSize viewSize;
@property (nonatomic, retain) NSMutableArray *customButtons;
@property (nonatomic, assign) BOOL hideCancel;
@property (nonatomic, assign) CGRect presentFromRect;
// For subclasses.
- (id)initWithTarget:(id)target successAction:(SEL)successAction cancelAction:(SEL)cancelActionOrNil origin:(id)origin;
// Present the ActionSheetPicker
- (void)showActionSheetPicker;
// For subclasses. This is used to send a message to the target upon a successful selection and dismissal of the picker (i.e. not canceled).
- (void)notifyTarget:(id)target didSucceedWithAction:(SEL)successAction origin:(id)origin;
// For subclasses. This is an optional message upon cancelation of the picker.
- (void)notifyTarget:(id)target didCancelWithAction:(SEL)cancelAction origin:(id)origin;
// For subclasses. This returns a configured picker view. Subclasses should autorelease.
- (UIPickerView *)configuredPickerView;
// Adds custom buttons to the left of the UIToolbar that select specified values
- (void)addCustomButtonWithTitle:(NSString *)title value:(id)value;
//For subclasses. This responds to a custom button being pressed.
- (IBAction)customButtonPressed:(id)sender;
@end