Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make it easier to handle screen orientation change #21

Closed
mmcdole opened this issue Dec 28, 2014 · 2 comments
Closed

Make it easier to handle screen orientation change #21

mmcdole opened this issue Dec 28, 2014 · 2 comments

Comments

@mmcdole
Copy link

mmcdole commented Dec 28, 2014

We are using AMPopTip in an app that supports both Portrait and Landscape. When a user rotates their device while a tooltip is visible, it obviously will now point at an incorrect location.

I know that AMPopTip is just a UIView that I'm free to position myself. However, all the calculation for how to position the tooltip correctly is internal to AMPopTip and I'd rather not recreate this myself.

Would it be possible to expose a method that lets me update the "fromFrame" such that pop-tip will re-do it's setup method with that new frame? That way on rotate I can check for any AMPopTip's where isVisible is YES and I'll send a new fromFrame to them?

@andreamazz
Copy link
Owner

Hi @mmcdole
I've exposed the fromFrame property with a setter that calls setup, so you can update it at your will. Checkout commit 721b7f5.

Cheers

@andreamazz
Copy link
Owner

Closing this one. Feel free to reopen if needed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants