Created
July 5, 2009 17:24
-
-
Save Me1000/141043 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-(id)initWithFrame:(CGRect)aFrame | |
{ | |
self = [super initWithFrame:aFrame]; | |
if(self){ | |
_upButton = [[CPButton alloc] initWithFrame: CGRectMake(0.0, 0.0, 12.0, 10.0)]; | |
_bottomButtom = [[CPButton alloc] initWithFrame: CGRectMake(0.0, 11.0, 12.0, 12.0)]; | |
_splitter = [[CPView alloc] initWithFrame: CGRectMake(0.0, 10.0, 12.0, 1.0)]; | |
[_upButton setImage:[[CPImage alloc] initWithContentsOfFile:@"Resources/Stepper/stepper_up.png" size:CGSizeMake(12.0, 10.0)]]; | |
[_bottomButton setImage:[[CPImage alloc] initWithContentsOfFile:@"Resources/Stepper/stepper_down.png" size:CGSizeMake(12.0, 12.0)]]; | |
[_splitter setBackgroundColor:[[CPColor alloc] _initWithPatternImage:[[CPImage alloc] initWithContentsOfFile:@"Resources/Stepper/stepper_middle.png" size:CGSizeMake(12.0, 1.0)]]]; | |
[_upButton setAlternateImage:[[CPImage alloc] initWithContentsOfFile:@"Resources/Stepper/stepper_up_highlighted.png" size:CGSizeMake(12.0, 10.0)]]; | |
[_bottomButton setAlternateImage:[[CPImage alloc] initWithContentsOfFile:@"Resources/Stepper/stepper_down_highlighted.png" size:CGSizeMake(12.0, 12.0)]]; | |
[self addSubview:_upButton]; | |
[self addSubview:_bottomButtom]; | |
[self addSubview:_splitter]; | |
} | |
return self; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment