Hello can someone help me with this pice of code. I have app with custom tab bar image an now in iOS5 the image is gone. I know that they have made changes on tab bar implementation and i’m not sure how to fix this.
- (void)applicationDidFinishLaunching:(UIApplication *)application {
[window makeKeyAndVisible];
CGRect frame = CGRectMake(0, 0, 400, 148);
UIView *viewa = [[UIView alloc] initWithFrame:frame];
UIImage *tabBarBackgroundImage = [UIImage imageNamed:@"fasha-down.png"];
UIColor *color = [[UIColor alloc] initWithPatternImage:tabBarBackgroundImage];
[viewa setBackgroundColor:color];
[[tabBarController tabBar] insertSubview:viewa atIndex:0];
[color release];
[viewa release];
[window addSubview:tabBarController.view];
}
Thank you for your help
Use this code to detect iOS version