Translate

2016年1月8日 星期五

Objective-C - Changing Inactive UITabBarItem Image Colour

Objective-C - Changing Inactive UITabBar Image Colour

UIImage *img = [UIImage imageNamed:@"tab1.png"];
self.tabBarItem.image = [img imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal];
UIImage *selectimg =[UIImage imageNamed:@"tabselect1.png"];
self.tabBarItem.selectedImage = [selectimg imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal];

沒有留言:

張貼留言