Reputation: 4134
UIPopoverController
instances can be restyled in iOS5 using the UIPopoverBackgroundView
class. However this customisation technique cannot be applied to UIActionSheets
(presented as popovers in iPad). I'd like my popovers to appear consistent so UIPopoverBackgroundView
isn't an option for me.
Poking through the iOS artwork (using extractor) I notice that alongside the _UIPopoverViewBlue*
PNGs (presumably used to draw the default blue-ish UIPopoverController
borders) is a _UIPopoverViewBlack*
set of PNGs. How do I get UIPopoverController
to use the black images instead of the blue ones?
Upvotes: 5
Views: 642
Reputation: 479
It appears there’s no way to achieve this officially. I doubt it will pass the App Store review process, but this works for me on iOS 6:
[popoverController setValue:@3 forKey:@"_popoverBackgroundStyle"];
It’s a shame Apple didn’t just expose this publicly.
Upvotes: 11