Question

What's the best way to control orientation changes when they happen too rapidly and overlap in time? In my application, I display a PDF document and scale it according to the current aspect ratio. It works OK if the new orientation changes occurs after the previous one completed. Otherwise, I seem to get an inconsistent state (e.g. portrait aspect ratio display in landscape mode).

Thank you,

Sam

Was it helpful?

Solution

I don't know which event you are using your code in. If you are using -didRotateFromInterfaceOrientation or -willRotateToInterfaceOrientation it should work correctly. But if you are using the deviceoriention notification for this it can cause a lot of trouble.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top