开发者

didAccelerate doesn't fire?

开发者 https://www.devze.com 2022-12-11 07:46 出处:网络
I can\'t get didAccelerate to trigger开发者_运维百科.I have the delegate implemented in my header file.I\'ve set a breakpoint in the method:

I can't get didAccelerate to trigger开发者_运维百科. I have the delegate implemented in my header file. I've set a breakpoint in the method:

- (void) accelerometer: (UIAccelerometer *)accelerometer didAccelerate: (UIAcceleration *)acceleration {
    int i = 0;
}

I've tried it with two different apps but still nothing. Any ideas on what I'm doing wrong?


try to set accelerometer's delegate to self. BTW, did you try to check it on a real device?

0

精彩评论

暂无评论...
验证码 换一张
取 消