某些iOS 7 UIPopoverController发生了奇怪的事情:边框出现在弹出窗口的一侧。这是一个截图:
http://img11.hostingpics.net/pics/440274Capturedcran20140414224144.png
这是打开弹出窗口的代码。
// .h
@property(nonatomic, retain) InAppPurchaseViewController *inAppPurchaseViewController;
@property(nonatomic, retain) UIPopoverController* inappPurchasePopover;
// .m
if (!self.inappPurchasePopover) {
self.inAppPurchaseViewController = [[InAppPurchaseViewController alloc] initWithNibName:@"InAppPurchaseViewController" bundle:nil];
self.inAppPurchaseViewController.settingsViewController = self;
self.inAppPurchaseViewController.contentSizeForViewInPopover = self.inAppPurchaseViewController.view.frame.size;
self.inappPurchasePopover = [[UIPopoverController alloc] initWithContentViewController:self.inAppPurchaseViewController];
self.inappPurchasePopover.delegate = self;
self.inappPurchasePopover.passthroughViews = [NSArray arrayWithArray:self.view.subviews];
}
// On affiche
[self.inappPurchasePopover presentPopoverFromRect:delegateAppli.principalNavigationController.topViewController.view.frame inView:delegateAppli.principalNavigationController.topViewController.view permittedArrowDirections:0 animated:YES];
iOS 6中一切正常。