如何在导航栏的两侧加多个Button
2015-11-02 21:17
169 查看
1.Just Follow ME
2.如图所示
UIBarButtonItem *anotherButton =[[UIBarButtonItem alloc]initWithImage:[UIImage imageNamed:@"CollectIcon"] style:UIBarButtonItemStylePlain target:self action:@selector(Like:)]; UIBarButtonItem *anotherButton2 = [[UIBarButtonItem alloc]initWithImage:[UIImage imageNamed:@"detailpage_sharebutton_up"] style:UIBarButtonItemStylePlain target:self action:@selector(dealShare:)]; UIBarButtonItem *anotherButton3 = [[UIBarButtonItem alloc]initWithImage:[UIImage imageNamed:@"TextIcon"] style:UIBarButtonItemStylePlain target:self action:@selector(changeFont:)]; [self.navigationItem setRightBarButtonItems:[NSArray arrayWithObjects: anotherButton,anotherButton2,anotherButton3,nil]];
2.如图所示
相关文章推荐
- 开源框架spring AOP的深刻理解
- Spring AOP代理模式
- 避免用char类型作为数组小标
- Objective-C:copy的用法解释
- iOS动画 UIView动画
- 基于MeanShift的视频目标跟踪算法及代码实现
- PowerShell 在hyper-v中创建虚拟机
- Dell笔记本安装win10无法调出cmd
- ADB server didn't ACK fail to start daemon解决方案
- ACE中同步线程方法
- malloc、calloc、realloc的区别
- Linux 的文件权限与目录配置
- Lesson 9 Array multiplication
- Linux常用命令总结及常用快捷键
- python爬虫入门
- 编译原理(词法分析)
- Fragment基础点滴学习---动态加载加载
- 正则化方法:L1和L2 regularization、数据集扩增、dropout
- 数据库三范式
- (OC)基础第二讲:实例变量可见度、方法