-
Notifications
You must be signed in to change notification settings - Fork 0
/
MAConfirmButton.h
executable file
·40 lines (31 loc) · 1.04 KB
/
MAConfirmButton.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
//
// MAConfirmButton.h
//
// Created by Mike on 11-03-28.
// Copyright 2011 Mike Ahmarani. All rights reserved.
//
#import <UIKit/UIKit.h>
#import <QuartzCore/QuartzCore.h>
@class MAConfirmButtonOverlay;
typedef enum {
MAConfirmButtonToggleAnimationLeft = 0,
MAConfirmButtonToggleAnimationRight = 1,
MAConfirmButtonToggleAnimationCenter =2
} MAConfirmButtonToggleAnimation;
@interface MAConfirmButton : UIButton {
@private
BOOL selected;
BOOL confirmed;
CALayer *colorLayer;
CALayer *darkenLayer;
UIButton *cancelOverlay;
}
@property (nonatomic, assign) MAConfirmButtonToggleAnimation toggleAnimation;
+ (MAConfirmButton *)buttonWithTitle:(NSString *)titleString confirm:(NSString *)confirmString;
+ (MAConfirmButton *)buttonWithDisabledTitle:(NSString *)disabledString;
- (id)initWithTitle:(NSString *)titleString confirm:(NSString *)confirmString;
- (id)initWithDisabledTitle:(NSString *)disabledString;
- (void)disableWithTitle:(NSString *)disabledString;
- (void)setAnchor:(CGPoint)anchor;
- (void)setTintColor:(UIColor *)color;
@end