I have a UIScrollView where the content size is larger than the frame. I am displaying a UIPopoverController and want to use the frame of a UIImageView for the call to set where the popover will be placed:
[popoverController presentPopoverFromRect: imageView.frame inView: self.view permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES];
This works fine If I have not scrolled at all. But as soon as I start scrolling, the frame of the imageview is outside of the frame of the scrollview so the popover always displays on the incorrect y axis.
Is there a way to map this position to display in the proper location?