首页 > 解决方案 > 如何隐藏底部工具栏

问题描述

我在向相册显示带有以下按钮的工具栏时遇到问题,上一个和新的出现在底部视图中。你怎么能隐藏这个工具栏?

提前致谢。

相册照片图片

 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];

标签: iosobjective-cnavigationuibarbuttonitemphoto-gallery

解决方案


如果要隐藏工具栏,可以使用以下代码。这里的 toolBarName 是工具栏的名称。

toolBarName.hidden=YES;

推荐阅读