I'm new to IOS programming, I don't know how to judge the swinging direction of a device.And I have searched a long time for this question, but I only find very little about this. Could someone help me? Thanks very much!

有帮助吗?

解决方案

Try this:

I have search some post for you, hope to help.

how to detect direction of shake in iphone

How to determine the direction of a iPhone shake

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top