Created
August 19, 2011 18:10
-
-
Save darkseed/1157542 to your computer and use it in GitHub Desktop.
UITabBarController+CCAdditions.h
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
#import "UITabBarController+CCAdditions.h" | |
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions | |
{ | |
[tabBarController setBackgroundImage:[UIImage imageNamed:@"CustomTabBarBackground.png"]]; | |
[tabBarController.view setNeedsDisplay]; | |
return YES; | |
} |
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
@interface UITabBarController (CCAdditions) | |
- (void) setBackgroundImage:(UIImage *)image; | |
@end |
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
#import "UITabBarController+CCAdditions.h" | |
@implementation UITabBarController (CCAdditions) | |
- (void) setBackgroundImage:(UIImage *)image | |
{ | |
UIImageView *imageView = [[UIImageView alloc] initWithFrame:CGRectMake(0,0,320,480)]; | |
imageView.backgroundColor = [UIColor colorWithPatternImage:i]; | |
[[self view] addSubview:imageView]; | |
[[self view] sendSubviewToBack:imageView]; | |
[[self view] setOpaque:NO]; | |
[[self view] setBackgroundColor:[UIColor clearColor]]; | |
[imageView release]; | |
} | |
@end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
i believe it is yes https://github.com/jameswomack/CCAdditions