简体   繁体   中英

Add a button to the Camera Toolbar on the iPhone

I am using a UIImagePickerController subclass to take photos in my app.

The toolbar for the camera has a cancel button and a photo button on it. I would also like to add another button on the right.

I have tried to add a UIBarButtonItem to the subclass's toolbar, but that doesn't work. I have also tried to make a UIToolbar that looks like the camera toolbar, so I can just overlay a toolbar with one button invisibly, but I can't seem to match the style of the camera toolbar.

Any ideas on how to add a button to the camera toolbar?

您不能像这样自定义UIImagePickerController工具栏,要做的是使用UIImagePickerController中的覆盖视图,它允许您指定用于选择器的视图,而不是默认视图,这是信息链接关于UIImagePickerController的这个overlayview属性

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM