Enlarge image on YouTube?

In Safair mobile, you can increase double entry if you have the html page that you are showing. But if you use uiwebview and display an image or pdf file, you need to open it to enlarge.

My question is: what do I need to do to get a double click in order to work when displaying an image or pdf file i uiwebview?

Can you make uiwebview an extra view under uiscrollview, can you use zoom twice? And how would you do that?

+3
source share
2 answers

Mobile Safari , . div -, , , . " ".

+1

UIWebview, UIWindow ,

- (void)sendEvent:(UIEvent *)event {
    NSLog(@"tap detect");
    NSArray *allTouches = [[event allTouches] allObjects];
    UITouch *touch = [[event allTouches] anyObject];
    UIView *touchView = [touch view];

    if (touchView && [touchView isDescendantOfView:urWebview]) {
        //
        // touchesBegan
        //
               if(touch.tapCount==2){
                     //
                // doubletap
                //
               }
       }
}
0

Source: https://habr.com/ru/post/1747187/


All Articles