在我的 iPhone 应用程序中,我使用了摇动手势,它可以正常工作,但需要大量的努力才能摇动。
有什么办法让它更敏感吗?
这是代码
- (void)motionEnded:(UIEventSubtype)motion withEvent:(UIEvent *)event
{
if (motion == UIEventSubtypeMotionShake)
{
[self performSelector:@selector(startPressed:)];
}
}