uipopovercontroller

Ipad UIImagePickerController and UIPopoverController error

廉价感情. 提交于 2019-12-10 13:50:03
问题 I am using this code to open a popover with imagepicker -(IBAction)photosAction:(id)sender { // dismiss any left over popovers here UIImagePickerController* picker = [[UIImagePickerController alloc] init]; picker.sourceType = UIImagePickerControllerSourceTypePhotoLibrary; picker.delegate = self; UIPopoverController *popover = [[UIPopoverController alloc] initWithContentViewController:picker]; self.popoverController = popover; popoverController.delegate = self; [popoverController

UIAlertController's popover is deformed

倖福魔咒の 提交于 2019-12-10 13:35:18
问题 I'm presenting a list of options to the user using an UIAlertController from a UIToolbar with a preferred style of action sheet. When presented, the popover's arrow is cut off and its corners are rounded with two different radii: The code I'm using to present it is straight from the documentation, as far as I see it: UIAlertController *alertController = [UIAlertController alertControllerWithTitle:@"" message:@"" preferredStyle:UIAlertControllerStyleActionSheet]; NSArray *actions = @[

position of UIPopoverController in iPad

那年仲夏 提交于 2019-12-10 12:17:46
问题 I have opened a pop up window on button click. I want to set x and y position of that view. I have tried a lot but can't set it properly. This is my code: -(IBAction)product2_click_h2 { //build our custom popover view UIViewController* popoverContent2 = [[UIViewController alloc] init]; UIView* popoverView2 = [[UIView alloc]initWithFrame:CGRectMake(100,100,200,200)]; popoverView2.backgroundColor = [UIColor greenColor]; UITextView *prod2_info = [[UITextView alloc]initWithFrame:CGRectMake(5,5

UIPopoverController presented modally doesn't work in iOS 5

一笑奈何 提交于 2019-12-10 11:22:06
问题 First of all, can we talk about iOS 5 here? Or is it still under NDA? If we can't talk about it, just ignore my question. By testing my app with an iPad with iOS 5 installed I discovered a problem with my "modal" popover: This can be closed by tapping outside of it, in other words, it's not modal! I have no idea what I'm doing wrong. A view controller opens the popover with this code: AddProjectViewController *addProjectViewController = [[AddProjectViewController alloc] initWithStyle

popoverControllerDidDismissPopover method is not called

孤者浪人 提交于 2019-12-10 10:41:41
问题 In my application I have a presentViewController , and inside it I have a button that opens a popover. In this popover I have a barButtonItem to save de data of this popover. I would like that when the user taps outside of the popover, the data could be saved too. I've tried to use the popoverControllerDidDismissPopover method in the presentViewController view. I have the delegate but when I tap outside of the popover this method is not called. What can I do? Thanks!! 回答1: Add this line of

iOS 6.0: UISplitViewController Popover broken or design changed by Apple?

♀尐吖头ヾ 提交于 2019-12-10 08:07:25
问题 I have created a project with master detail template in Xcode 4.5 and deployment target 5.1. Could someone please help me with following UISplitViewController issues please. In portrait mode, master view fade in from the left. It doesn't appear as Popover view as it used in iOS 5.0 in portrait mode. Please see attached images. How to get the master view as popover? Is there anyway I can hide master view in Landscap mode? Thanks. 回答1: This has been the default action since 5.1. From the iOS 6

UIPopoverController not moving to original position after keyboard slides back down

百般思念 提交于 2019-12-10 03:05:36
问题 I'm displaying a popover in iPad with a UINavigation bar. On the second view, I have a UISearchController that can display a keyboard. The keyboard pushes the popover up, which is fine, however if I now push the 'back' button on the UINavigation bar it dismisses the keyboard which is fine, but the popover doesn't slide back down to its original position. Anyone know how to fix that? Thanks! 回答1: Ok so I actually figured out (I believe) what your question was asking...and just in case anyone

UIPopoverController dealloc getting called—ARC environment

浪尽此生 提交于 2019-12-09 08:21:50
问题 While displaying a popover controller for a second time (after dismissing it and then re-displaying it), I get the following error: Terminating app due to uncaught exception 'NSGenericException', reason: '-[UIPopoverController dealloc] reached while popover is still visible.' The stack trace is only a bunch of hex and the SIGABRT happens at UIApplicationMain every time. Here's the code that the button triggers: - (IBAction)createNewScore:(id)sender { if (self.pc) if (self.pc.popoverVisible)

Present UIPopoverController in same position with changing just arrow offset

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-08 23:11:12
问题 My goal is to keep same coordinates for a UIPopoverController with just changing arrow offset. So basically i have three buttons touching each of them shows up a popover. When presenting this popover it changes position on the screen, but i do not want that. To be more clear look at screenoshots: 回答1: For my popover I wanted the arrow to be top-left instead of top-center (which is default). I've managed to get the result below (screenshot) by setting the popoverLayoutMargins property of the

How to disable darker transparent effect in UIPopoverController in iOS7?

我是研究僧i 提交于 2019-12-08 19:14:04
问题 I use UIPopoverController to popup an view in iPad iOS7 like this: if (!self.popover) { UIViewController *popupVC = [[UIViewController alloc] init]; [popupVC.view addSubview:thePopupView]; popupVC.preferredContentSize = CGSizeMake(240, 140); self.popover = [[UIPopoverController alloc] initWithContentViewController:popupVC]; self.popover.delegate = self; } [self.popover presentPopoverFromBarButtonItem:barButton permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES]; But when popover