2014-09-01 58 views
0

我有一个iPad应用程序只支持风景方向,但是当我尝试在UIPopoverController内显示UIImagePickerController时,它总是以纵向模式显示。即从UI的其余部分旋转90度。有谁知道我可以如何使它与我在展示它的ViewController以相同的方向出现?只有风景iPad应用程序以纵向显示UIImagePicker

我显示imagePicker这样的:

self.picker = [[FFSImagePicker alloc] init]; 

picker.mediaTypes = [NSArray arrayWithObject:(NSString *)kUTTypeImage]; 
picker.delegate = self; 
picker.toolbarHidden = YES; 
picker.sourceType = UIImagePickerControllerSourceTypeCamera; 
picker.allowsEditing = NO; 
picker.showsCameraControls = YES; 

UIPopoverController *popover = [[UIPopoverController alloc] initWithContentViewController:picker]; 
self.photoPickerPopover = popover; 

[self.photoPickerPopover presentPopoverFromRect:photoButton.bounds inView:photoButton permittedArrowDirections:UIPopoverArrowDirectionRight animated:YES]; 

FFSImagePicker仅仅是一个的UIImagePickerController的子类,我试图以确保支撑取向只是风景,但没有任何效果。

感谢您的帮助......

+0

试试这个:HTTP://stackoverflow.com/questions/20468335/ios7-ipad-landscape-only-app-using-uiimagepickercontroller 它确实帮助我 – John 2014-09-01 01:25:22

+0

谢谢,这确实指向了我正确的方向,虽然它没有解决问题。 – SeanT 2014-09-01 19:46:13

回答

1

OK,我解决了这个,问题是,我是在UIPopover苹果公司说,当源类型是相机不能做呈现UIImagePickerController,而不是目前它全屏就像你会任何其他视图控制器。

希望这有助于别人太...

相关问题