[Development issues] ipad development to solve the problem (Urgent): animation is not done the user to rotate the screen appears bug
Ladies and gentlemen, ipad development in solving a problem, the problem is this: My project support horizontal and vertical screen, the application made when entering an animation effect, because the same animation, horizontal and vertical screen coordinate dimensions are different when the ipad is in horizontal screen animation state when the user rotates the screen in portrait mode, this time remains to do is cross-screen animation, which is a big bug, do not know if I have encountered such a situation, seek guidance. My personal idea is, can during the animation, to screen lock screen controller sends a message, such as animation done recurrence after news of a rotating support, but the problem is that as far as I know, the program calls the loading shouldAutorotateToInterfaceOrientation function returns YES when it has been determined whether to support horizontal and vertical screen, the parties to solve, first thanked! Reply: [[UIApplication sharedApplication] setStatusBarOrientation: UIInterfaceOrientationLandscapeRight animated: NO]; One can not choose to start the setup screen. After the animation is done using the above methods can be rotated to set back Reply:
This trick feasible it, test Reply:
But the problem is, if I start the setup screen can not choose, that only horizontal screen animation program defaults or only vertical screen animation, the animation does not know what to do, and I do need to determine which animation based on ipad position, then lock screen, and then set back after the movie finished. Seeking deep solution! Reply:
But the problem is, if I start the setup screen can not choose, that only horizontal screen animation program defaults or only vertical screen animation, the animation does not know what to do, and I do need to determine which animation based on ipad position, then lock screen, and then set back after the movie finished. Seeking deep solution! Reply:
But the problem is, if I start the setup screen can not choose, that only horizontal screen animation program defaults or only vertical screen animation, the animation does not know what to do, and I do need to determine which animation based on ipad position, then lock screen, and then set back after the movie finished. Seeking deep solution! Reply:
Your animation where it needs to be rotated by a thread, and does not rotate with just a way to set yourself Reply: Before playing the animation first obtain UIInterfaceOrientation orientation = [[UIApplication sharedApplication] statusBarOrientation;. According to the direction of orientation is to be broadcast to determine the horizontal screen or vertical screen; then play when finished playing to unlock locked rotation rotation ~ ~ Reply:
The reply was deleted at the moderator 2011-10-20 16:52:47
Reply: Using variables do not get a thing?
In the shouldAutorotateToInterfaceOrientationif (state == welcome) { if (vertical) return YES; }
else if (state == normal) { return YES; } Reply: He meant to do animation when the screen rotation lock, done after then you can rotate
Reply: Be animation events, depending on the orientation to handle animations that animation events which start initialization, including frame, timer, etc., thus ensuring the real-time requirements of the user
No comments:
Post a Comment