iOS show UIImage full screen with zooming (pinch and double tap) enabled

前端 未结 2 1031
走了就别回头了
走了就别回头了 2021-02-03 16:17

I have an UIImage captured from the camera with UIImagePickerController.

Now after the user clicks on it, I\'d like it to show full screen and

2条回答
  •  太阳男子
    2021-02-03 16:43

    This is very easy to implement:

    - (IBAction)handlePinch:(UIPinchGestureRecognizer *)recognizer;
    

    and then:

    - (IBAction)handlePinch:(UIPinchGestureRecognizer *)recognizer {    
    recognizer.view.transform = CGAffineTransformScale(recognizer.view.transform, recognizer.scale, recognizer.scale);
    recognizer.scale = 1;    
    } 
    

提交回复
热议问题