Title: [184798] trunk/Source/WebKit2
Revision
184798
Author
[email protected]
Date
2015-05-22 15:52:20 -0700 (Fri, 22 May 2015)

Log Message

Image link doesn't create a preview view controller.
https://bugs.webkit.org/show_bug.cgi?id=145320

Also try to create the preview view controller if the hit-tested node
is a image link.

Patch by Yongjun Zhang <[email protected]> on 2015-05-22
Reviewed by Beth Dakin.

* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView gestureRecognizerShouldBegin:]):
(-[WKContentView previewViewControllerForPosition:inSourceView:]):

Modified Paths

Diff

Modified: trunk/Source/WebKit2/ChangeLog (184797 => 184798)


--- trunk/Source/WebKit2/ChangeLog	2015-05-22 21:48:53 UTC (rev 184797)
+++ trunk/Source/WebKit2/ChangeLog	2015-05-22 22:52:20 UTC (rev 184798)
@@ -1,3 +1,17 @@
+2015-05-22  Yongjun Zhang  <[email protected]>
+
+        Image link doesn't create a preview view controller.
+        https://bugs.webkit.org/show_bug.cgi?id=145320
+
+        Also try to create the preview view controller if the hit-tested node
+        is a image link.
+
+        Reviewed by Beth Dakin.
+
+        * UIProcess/ios/WKContentViewInteraction.mm:
+        (-[WKContentView gestureRecognizerShouldBegin:]):
+        (-[WKContentView previewViewControllerForPosition:inSourceView:]):
+
 2015-05-22  Tim Horton  <[email protected]>
 
         Avoid doing an extra layout in some cases while doing scale-to-fit

Modified: trunk/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm (184797 => 184798)


--- trunk/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm	2015-05-22 21:48:53 UTC (rev 184797)
+++ trunk/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm	2015-05-22 22:52:20 UTC (rev 184798)
@@ -953,7 +953,7 @@
 
     if (gestureRecognizer == _previewGestureRecognizer) {
         [self ensurePositionInformationIsUpToDate:point];
-        if (_positionInformation.clickableElementName != "A")
+        if (_positionInformation.clickableElementName != "A" && _positionInformation.clickableElementName != "IMG")
             return NO;
 
         String absoluteLinkURL = _positionInformation.url;
@@ -3117,7 +3117,7 @@
 {
     ASSERT(self == sourceView);
 
-    if (_positionInformation.clickableElementName != "A")
+    if (_positionInformation.clickableElementName != "A" && _positionInformation.clickableElementName != "IMG")
         return nil;
 
     String absoluteLinkURL = _positionInformation.url;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to