A better workflow would be:
- Dismiss actionsheet when a rotation occurs
- Calculate the new rectangle where it should be presented from
- Present a new actionsheet from the new rectangle
Question
I have a UIActionSheet
which appears as a UIPopoverController
on the iPad. I am trying to show it from a UIButton
by using:
[self.exampleActionSheet showFromRect:self.exampleButton.frame inView:self.view animated:YES];
What I am trying to do now is to reposition this UIActionSheet
on orientation change. But when I use the above code to reposition after the screen has rotated, it doesn't do so. Can anyone tell me how to do this properly?
Solution
A better workflow would be: