完全定制UITabBarViewController 效果 源码https://github.com/YouXianMing/iOS-Project-Examples 中的 TotalCustomTabBarController//// CustomTabB ...
完全定制UITabBarViewController
效果
源码
https://github.com/YouXianMing/iOS-Project-Examples 中的 TotalCustomTabBarController
//// CustomTabBarViewController.h// TotalCustomTabBarController//// Created by YouXianMing on 16/6/2.// Copyright © 2016年 YouXianMing. All rights reserved.//#import "CustomViewController.h"@class CustomTabBarViewController;@protocol CustomTabBarViewControllerDelegate <NSObject>@optional- (BOOL)customTabBarController:(CustomTabBarViewController *)tabBarController shouldSelectViewController:(UIViewController *)viewController selectedIndex:(NSInteger)index;- (void)customTabBarController:(CustomTabBarViewController *)tabBarController didSelectViewController:(UIViewController *)viewController selectedIndex:(NSInteger)index;@end@interface CustomTabBarViewController : CustomViewController/** * CustomTabBarViewController's delegate. */@property (nonatomic, weak) id <CustomTabBarViewControllerDelegate> delegate;/** * TabBar's height, default is 49.f. */@property (nonatomic) CGFloat tabBarHeight;/** * The controller's index that loaded and show by CustomTabBarViewController at the first time. */@property (nonatomic) NSInteger firstLoadIndex;/** * ViewControllers. */@property(nonatomic, strong) NSArray <__kindof CustomViewController *> *viewControllers;/** * Hide TabBarView or not. * * @param hide Hide or not. * @param animated Animated or not. */- (void)hideTabBarView:(BOOL)hide animated:(BOOL)animated;#pragma mark - Used by subClass./** * TabBarView, you should add view on it. */@property (nonatomic, strong, readonly) UIView *tabBarView;/** * Will select index, used by subClass. * * @param index Index. * * @return Will selected or not. */- (BOOL)willSelectIndex:(NSInteger)index;/** * Did selected index, used by subClass. * * @param index Index. */- (void)didSelectedIndex:(NSInteger)index;/** * Build items in the tabBarView. */- (void)buildItems;@end
原标题:完全定制UITabBarViewController
关键词:ie
*特别声明:以上内容来自于网络收集,著作权属原作者所有,如有侵权,请联系我们:
admin#shaoqun.com
(#换成@)。