Reputation: 439
I want to implement the following type of UI flow in my project
https://i.sstatic.net/eHwwk.jpg
So, basically the following option, I have to show in popover, and on the basis of user selection, I have to navigate to next view, and then can come back to my main view.
My approach so far is in my main view, i m creating a popover with a navigation controller. The navigation controller root view controller is a subclass of UITableView
controller. In UITableView
Controller, I am presenting the following two options, and when user selects the "Photo Roll" in table view delagate tableVIewDidSelectROw
, I am pushing like this
UIImagePickerController *imgPicker = [[UIImagePickerController alloc] init]]
impgPicker.source = // source type to camera roll
[self.navigationController pushViewController:imgPicker animation:YES]
but after this line I am getting the crash, I even tried using
[self prsentViewController]
but same result.
Any help will be greatly appreciated, and I am running on iOS 5 simulator.
Upvotes: 1
Views: 220
Reputation: 22701
UIImagePickerController is meant to be used as a modal view controller and displayed using the presentModalViewController:animated: method.
You will likely need to define your own view controllers to implement the interface as designed. You can get access to the albums and photos through the ALAssetsLibrary class.
Upvotes: 1