ios - 如何隐藏底部工具栏
问题描述
我在向相册显示带有以下按钮的工具栏时遇到问题,上一个和新的出现在底部视图中。你怎么能隐藏这个工具栏?
提前致谢。
UIImagePickerController *controller = [[UIImagePickerController alloc] init];
controller.sourceType = UIImagePickerControllerSourceTypePhotoLibrary;
controller.allowsEditing = YES;
controller.mediaTypes = [UIImagePickerController availableMediaTypesForSourceType: UIImagePickerControllerSourceTypePhotoLibrary];
controller.delegate = self;
[self.navigationController presentViewController: controller animated: YES completion: nil];
解决方案
如果要隐藏工具栏,可以使用以下代码。这里的 toolBarName 是工具栏的名称。
toolBarName.hidden=YES;
推荐阅读
- typescript - 泛型类的构造函数中可选字段的默认值
- google-play - 从许可证 apk 迁移到应用内购买 - 如何迁移现有许可证所有者?
- amazon-web-services - 如何获取 .net core lambda 的 event.action?
- java - 如何使用约束布局将回收器视图项设置为屏幕宽度的一半?
- azure - azure 服务主体:在 jenkins 管道中的访问被拒绝在命令行中很好(是否使用插件)
- batch-file - 如何将路径与字符串批量组合?
- sql - SQL 按两列的组合值分组
- android - 为什么在Android中的viewmodel观察者之前首先调用apply?
- arduino - LORA ESP32 深度睡眠时间
- excel - 复制下一个单元格并粘贴到同一个单元格上