RT,就是3个手指同时敲2下就可以缩放的zoom效果,在不改变系统设置那里的开关前提下,只在app游戏中不让出现这个效果  退出游戏了则恢复zoom效果,请问怎么做呢?

解决方案 »

  1.   


    嗯?  请问怎么做呢  在uiview里
      

  2.   

    - (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event {
          
    }
    - (void)touchesCancelled:(NSSet *)touches withEvent:(UIEvent *)event{
       }
    - (void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event {
       }
    - (void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event {
           
    }
    用这三个方法,截获“3个手指同时敲2下”操作。然后自己处理下NSUInteger numTaps = [[touches anyObject] tapCount];//点了几下
        NSString *tapsMessage = [[NSString alloc]
                                 initWithFormat:@"%d taps detected", numTaps];
        tapsLabel.text = tapsMessage;
        [tapsMessage release];
        
        NSUInteger numTouches = [touches count];//几个触摸点
        NSString *touchMsg = [[NSString alloc] initWithFormat:
                              @"%d touches detected", numTouches];
        touchesLabel.text = touchMsg;
        [touchMsg release];
      

  3.   


    - (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event {}
    - (void)touchesCancelled:(NSSet *)touches withEvent:(UIEvent *)event{
    }
    - (void)touchesEnded:(NSSet *)touches withE……
    监听你对View的手指操作,比如几个手指,点了几下,都可以获取的。
      

  4.   


    没有吧?
    放在UIScrollView 或者实现UIScrollViewDelegate才会缩放吧。
      

  5.   


    NSUInteger numTaps = [[touches anyObject] tapCount];//点了几下
    NSUInteger numTouches = [touches count];//几个触摸点这2句要写在哪里呢,我把这2句写在 touchesBegan里面  然后用if来判断,如果是缩放就return,貌似没有效果呢
      

  6.   

    貌似  NSUInteger numTouches = [touches count];//几个触摸点   总是得到1   什么情况呢
      

  7.   

    不行呢,看了developer.app.com  里面说上面那套API只是捕捉单个手指触屏的  3个手指就不行  所以能捕捉到连续拍了几下  但是捕捉不到是几个手指拍的……求高人指点