Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Display a bottom menu

How can display a menu in the bottom of the screen? I have an UIImagePickerController and I want to let user select the source type. I want 3 buttons: "Take from photo library", "Take from camera", "Cancel".

Here is a screenshot of what I want: http://i.stack.imgur.com/e3JoQ.jpg

How can I do that

like image 470
mathieu_b Avatar asked Mar 14 '23 03:03

mathieu_b


1 Answers

If you are supporting iOS 8 and above, Use UIAlertController with a preferredStyle of UIAlertControllerStyleActionSheet. And if you are supporting below that, use UIActionSheet. For more details on how to use UIAlertController, look at this blog.

like image 149
dispatchMain Avatar answered Mar 25 '23 02:03

dispatchMain