<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[195722] trunk/Source</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/195722">195722</a></dd>
<dt>Author</dt> <dd>enrica@apple.com</dd>
<dt>Date</dt> <dd>2016-01-27 17:36:06 -0800 (Wed, 27 Jan 2016)</dd>
</dl>

<h3>Log Message</h3>
<pre>Cache results of data detection in the UI process when load completes.
https://bugs.webkit.org/show_bug.cgi?id=153560

Reviewed by Tim Horton.

Source/WebCore:

Adding new FrameLoaderClient method to notify that data
detection is complete and provide the results.

* loader/EmptyClients.h:
* loader/FrameLoader.cpp:
(WebCore::FrameLoader::checkLoadCompleteForThisFrame):
* loader/FrameLoaderClient.h:

Source/WebKit/mac:

Adding empty implementation for WK1.

* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchDidFinishDataDetection):

Source/WebKit2:

This patch changes when the results of data detections are sent to the
UIProcess. Before this change, they were only provided as part of
InteractionInformationAtPosition, which is populated when long press
gesture is triggered.
We need to have the results available if the client wants to allow navigation
to a data detector link, in order to allow them to retrieve the full url.
With this change, we now send the results as soon as they are computed
and keep them in the WebPageProxy object so that they can be fetched when
necessary from a WKWebView private interface.

* Shared/Cocoa/DataDetectionResult.h: Added.
* Shared/Cocoa/DataDetectionResult.mm: Added.
(WebKit::DataDetectionResult::encode):
(WebKit::DataDetectionResult::decode):
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _snapshotLayerContentsForBackForwardListItem:]):
(-[WKWebView _dataDetectionResults]):
(-[WKWebView _didRelaunchProcess]):
* UIProcess/API/Cocoa/WKWebViewPrivate.h:
* UIProcess/Cocoa/WebPageProxyCocoa.mm:
(WebKit::WebPageProxy::setDataDetectionResult):
(WebKit::WebPageProxy::saveRecentSearches):
* UIProcess/WebPageProxy.h:
(WebKit::WebPageProxy::websiteDataStore):
(WebKit::WebPageProxy::dataDetectionResults):
(WebKit::WebPageProxy::scrollingCoordinatorProxy):
* UIProcess/WebPageProxy.messages.in:
* UIProcess/ios/WKContentViewInteraction.h:
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView ensurePositionInformationIsUpToDate:]):
(-[WKContentView _dataDetectionResults]):
(-[WKContentView gestureRecognizerShouldBegin:]):
* WebKit2.xcodeproj/project.pbxproj:
* WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::dispatchDidReceiveContentLength):
(WebKit::WebFrameLoaderClient::dispatchDidFinishDataDetection):
(WebKit::WebFrameLoaderClient::dispatchDidFinishLoading):
* WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::updatePreferences):
(WebKit::WebPage::setDataDetectionResults):
(WebKit::WebPage::willCommitLayerTree):
* WebProcess/WebPage/WebPage.h:
(WebKit::WebPage::shouldExtendIncrementalRenderingSuppression):</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreloaderEmptyClientsh">trunk/Source/WebCore/loader/EmptyClients.h</a></li>
<li><a href="#trunkSourceWebCoreloaderFrameLoadercpp">trunk/Source/WebCore/loader/FrameLoader.cpp</a></li>
<li><a href="#trunkSourceWebCoreloaderFrameLoaderClienth">trunk/Source/WebCore/loader/FrameLoaderClient.h</a></li>
<li><a href="#trunkSourceWebKitmacChangeLog">trunk/Source/WebKit/mac/ChangeLog</a></li>
<li><a href="#trunkSourceWebKitmacWebCoreSupportWebFrameLoaderClienth">trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.h</a></li>
<li><a href="#trunkSourceWebKitmacWebCoreSupportWebFrameLoaderClientmm">trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.mm</a></li>
<li><a href="#trunkSourceWebKit2ChangeLog">trunk/Source/WebKit2/ChangeLog</a></li>
<li><a href="#trunkSourceWebKit2UIProcessAPICocoaWKWebViewmm">trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm</a></li>
<li><a href="#trunkSourceWebKit2UIProcessAPICocoaWKWebViewPrivateh">trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebViewPrivate.h</a></li>
<li><a href="#trunkSourceWebKit2UIProcessCocoaWebPageProxyCocoamm">trunk/Source/WebKit2/UIProcess/Cocoa/WebPageProxyCocoa.mm</a></li>
<li><a href="#trunkSourceWebKit2UIProcessWebPageProxyh">trunk/Source/WebKit2/UIProcess/WebPageProxy.h</a></li>
<li><a href="#trunkSourceWebKit2UIProcessWebPageProxymessagesin">trunk/Source/WebKit2/UIProcess/WebPageProxy.messages.in</a></li>
<li><a href="#trunkSourceWebKit2UIProcessiosWKContentViewInteractionh">trunk/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.h</a></li>
<li><a href="#trunkSourceWebKit2UIProcessiosWKContentViewInteractionmm">trunk/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm</a></li>
<li><a href="#trunkSourceWebKit2WebKit2xcodeprojprojectpbxproj">trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebCoreSupportWebFrameLoaderClientcpp">trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebCoreSupportWebFrameLoaderClienth">trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.h</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebPageWebPagecpp">trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebPageWebPageh">trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkSourceWebKit2SharedCocoaDataDetectionResulth">trunk/Source/WebKit2/Shared/Cocoa/DataDetectionResult.h</a></li>
<li><a href="#trunkSourceWebKit2SharedCocoaDataDetectionResultmm">trunk/Source/WebKit2/Shared/Cocoa/DataDetectionResult.mm</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebCore/ChangeLog        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -1,3 +1,18 @@
</span><ins>+2016-01-27  Enrica Casucci  &lt;enrica@apple.com&gt;
+
+        Cache results of data detection in the UI process when load completes.
+        https://bugs.webkit.org/show_bug.cgi?id=153560
+
+        Reviewed by Tim Horton.
+
+        Adding new FrameLoaderClient method to notify that data
+        detection is complete and provide the results.
+
+        * loader/EmptyClients.h:
+        * loader/FrameLoader.cpp:
+        (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
+        * loader/FrameLoaderClient.h:
+
</ins><span class="cx"> 2016-01-27  Daniel Bates  &lt;dabates@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Move ContentSecurityPolicy.{cpp, h} to its own directory
</span></span></pre></div>
<a id="trunkSourceWebCoreloaderEmptyClientsh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/loader/EmptyClients.h (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/loader/EmptyClients.h        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebCore/loader/EmptyClients.h        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -268,6 +268,9 @@
</span><span class="cx">     virtual void dispatchDidReceiveResponse(DocumentLoader*, unsigned long, const ResourceResponse&amp;) override { }
</span><span class="cx">     virtual void dispatchDidReceiveContentLength(DocumentLoader*, unsigned long, int) override { }
</span><span class="cx">     virtual void dispatchDidFinishLoading(DocumentLoader*, unsigned long) override { }
</span><ins>+#if ENABLE(DATA_DETECTION)
+    virtual void dispatchDidFinishDataDetection(NSArray *) override { }
+#endif
</ins><span class="cx">     virtual void dispatchDidFailLoading(DocumentLoader*, unsigned long, const ResourceError&amp;) override { }
</span><span class="cx">     virtual bool dispatchDidLoadResourceFromMemoryCache(DocumentLoader*, const ResourceRequest&amp;, const ResourceResponse&amp;, int) override { return false; }
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCoreloaderFrameLoadercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/loader/FrameLoader.cpp (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/loader/FrameLoader.cpp        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebCore/loader/FrameLoader.cpp        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -2283,6 +2283,8 @@
</span><span class="cx">                 if (m_frame.settings().dataDetectorTypes() != DataDetectorTypeNone) {
</span><span class="cx">                     RefPtr&lt;Range&gt; documentRange = makeRange(firstPositionInNode(m_frame.document()-&gt;documentElement()), lastPositionInNode(m_frame.document()-&gt;documentElement()));
</span><span class="cx">                     m_frame.setDataDetectionResults(DataDetection::detectContentInRange(documentRange, m_frame.settings().dataDetectorTypes()));
</span><ins>+                    if (m_frame.isMainFrame())
+                        m_client.dispatchDidFinishDataDetection(m_frame.dataDetectionResults());
</ins><span class="cx">                 }
</span><span class="cx"> #endif
</span><span class="cx">                 m_client.dispatchDidFinishLoad();
</span></span></pre></div>
<a id="trunkSourceWebCoreloaderFrameLoaderClienth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/loader/FrameLoaderClient.h (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/loader/FrameLoaderClient.h        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebCore/loader/FrameLoaderClient.h        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -55,6 +55,7 @@
</span><span class="cx"> typedef class _jobject* jobject;
</span><span class="cx"> 
</span><span class="cx"> #if PLATFORM(COCOA)
</span><ins>+OBJC_CLASS NSArray;
</ins><span class="cx"> OBJC_CLASS NSCachedURLResponse;
</span><span class="cx"> OBJC_CLASS NSView;
</span><span class="cx"> #endif
</span><span class="lines">@@ -173,6 +174,9 @@
</span><span class="cx">         virtual void dispatchDidFailLoad(const ResourceError&amp;) = 0;
</span><span class="cx">         virtual void dispatchDidFinishDocumentLoad() = 0;
</span><span class="cx">         virtual void dispatchDidFinishLoad() = 0;
</span><ins>+#if ENABLE(DATA_DETECTION)
+        virtual void dispatchDidFinishDataDetection(NSArray *detectionResults) = 0;
+#endif
</ins><span class="cx"> 
</span><span class="cx">         virtual void dispatchDidLayout() { }
</span><span class="cx">         virtual void dispatchDidLayout(LayoutMilestones) { }
</span></span></pre></div>
<a id="trunkSourceWebKitmacChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/mac/ChangeLog (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/mac/ChangeLog        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit/mac/ChangeLog        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -1,3 +1,16 @@
</span><ins>+2016-01-27  Enrica Casucci  &lt;enrica@apple.com&gt;
+
+        Cache results of data detection in the UI process when load completes.
+        https://bugs.webkit.org/show_bug.cgi?id=153560
+
+        Reviewed by Tim Horton.
+
+        Adding empty implementation for WK1.
+
+        * WebCoreSupport/WebFrameLoaderClient.h:
+        * WebCoreSupport/WebFrameLoaderClient.mm:
+        (WebFrameLoaderClient::dispatchDidFinishDataDetection):
+
</ins><span class="cx"> 2016-01-27  Anders Carlsson  &lt;andersca@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Add WebKitAdditions extension points to WebCore, WebKit and WebKitLegacy
</span></span></pre></div>
<a id="trunkSourceWebKitmacWebCoreSupportWebFrameLoaderClienth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.h (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.h        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.h        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -92,6 +92,9 @@
</span><span class="cx">     virtual void dispatchDidReceiveResponse(WebCore::DocumentLoader*, unsigned long identifier, const WebCore::ResourceResponse&amp;) override;
</span><span class="cx">     virtual void dispatchDidReceiveContentLength(WebCore::DocumentLoader*, unsigned long identifier, int dataLength) override;
</span><span class="cx">     virtual void dispatchDidFinishLoading(WebCore::DocumentLoader*, unsigned long identifier) override;
</span><ins>+#if ENABLE(DATA_DETECTION)
+    virtual void dispatchDidFinishDataDetection(NSArray *detectionResults) override;
+#endif
</ins><span class="cx">     virtual void dispatchDidFailLoading(WebCore::DocumentLoader*, unsigned long identifier, const WebCore::ResourceError&amp;) override;
</span><span class="cx"> 
</span><span class="cx">     virtual NSCachedURLResponse* willCacheResponse(WebCore::DocumentLoader*, unsigned long identifier, NSCachedURLResponse*) const override;
</span></span></pre></div>
<a id="trunkSourceWebKitmacWebCoreSupportWebFrameLoaderClientmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.mm (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.mm        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.mm        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -528,6 +528,10 @@
</span><span class="cx">     }
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+void WebFrameLoaderClient::dispatchDidFinishDataDetection(NSArray *)
+{
+}
+
</ins><span class="cx"> void WebFrameLoaderClient::dispatchDidFinishLoading(DocumentLoader* loader, unsigned long identifier)
</span><span class="cx"> {
</span><span class="cx">     WebView *webView = getWebView(m_webFrame.get());
</span></span></pre></div>
<a id="trunkSourceWebKit2ChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/ChangeLog (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/ChangeLog        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit2/ChangeLog        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -1,3 +1,55 @@
</span><ins>+2016-01-27  Enrica Casucci  &lt;enrica@apple.com&gt;
+
+        Cache results of data detection in the UI process when load completes.
+        https://bugs.webkit.org/show_bug.cgi?id=153560
+
+        Reviewed by Tim Horton.
+
+        This patch changes when the results of data detections are sent to the
+        UIProcess. Before this change, they were only provided as part of
+        InteractionInformationAtPosition, which is populated when long press
+        gesture is triggered.
+        We need to have the results available if the client wants to allow navigation
+        to a data detector link, in order to allow them to retrieve the full url.
+        With this change, we now send the results as soon as they are computed
+        and keep them in the WebPageProxy object so that they can be fetched when
+        necessary from a WKWebView private interface.
+
+        * Shared/Cocoa/DataDetectionResult.h: Added.
+        * Shared/Cocoa/DataDetectionResult.mm: Added.
+        (WebKit::DataDetectionResult::encode):
+        (WebKit::DataDetectionResult::decode):
+        * UIProcess/API/Cocoa/WKWebView.mm:
+        (-[WKWebView _snapshotLayerContentsForBackForwardListItem:]):
+        (-[WKWebView _dataDetectionResults]):
+        (-[WKWebView _didRelaunchProcess]):
+        * UIProcess/API/Cocoa/WKWebViewPrivate.h:
+        * UIProcess/Cocoa/WebPageProxyCocoa.mm:
+        (WebKit::WebPageProxy::setDataDetectionResult):
+        (WebKit::WebPageProxy::saveRecentSearches):
+        * UIProcess/WebPageProxy.h:
+        (WebKit::WebPageProxy::websiteDataStore):
+        (WebKit::WebPageProxy::dataDetectionResults):
+        (WebKit::WebPageProxy::scrollingCoordinatorProxy):
+        * UIProcess/WebPageProxy.messages.in:
+        * UIProcess/ios/WKContentViewInteraction.h:
+        * UIProcess/ios/WKContentViewInteraction.mm:
+        (-[WKContentView ensurePositionInformationIsUpToDate:]):
+        (-[WKContentView _dataDetectionResults]):
+        (-[WKContentView gestureRecognizerShouldBegin:]):
+        * WebKit2.xcodeproj/project.pbxproj:
+        * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
+        (WebKit::WebFrameLoaderClient::dispatchDidReceiveContentLength):
+        (WebKit::WebFrameLoaderClient::dispatchDidFinishDataDetection):
+        (WebKit::WebFrameLoaderClient::dispatchDidFinishLoading):
+        * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
+        * WebProcess/WebPage/WebPage.cpp:
+        (WebKit::WebPage::updatePreferences):
+        (WebKit::WebPage::setDataDetectionResults):
+        (WebKit::WebPage::willCommitLayerTree):
+        * WebProcess/WebPage/WebPage.h:
+        (WebKit::WebPage::shouldExtendIncrementalRenderingSuppression):
+
</ins><span class="cx"> 2016-01-27  Anders Carlsson  &lt;andersca@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Include the right WebKitAdditions files
</span></span></pre></div>
<a id="trunkSourceWebKit2SharedCocoaDataDetectionResulth"></a>
<div class="addfile"><h4>Added: trunk/Source/WebKit2/Shared/Cocoa/DataDetectionResult.h (0 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/Shared/Cocoa/DataDetectionResult.h                                (rev 0)
+++ trunk/Source/WebKit2/Shared/Cocoa/DataDetectionResult.h        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -0,0 +1,48 @@
</span><ins>+/*
+ * Copyright (C) 2016 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef DataDetectionResult_h
+#define DataDetectionResult_h
+
+#if ENABLE(DATA_DETECTION)
+
+#import &quot;ArgumentCoders.h&quot;
+
+#import &lt;wtf/RetainPtr.h&gt;
+
+namespace WebKit {
+
+struct DataDetectionResult {
+    RetainPtr&lt;NSArray&gt; results;
+
+    void encode(IPC::ArgumentEncoder&amp;) const;
+    static bool decode(IPC::ArgumentDecoder&amp;, DataDetectionResult&amp;);
+};
+
+}
+
+#endif // ENABLE(DATA_DETECTION)
+
+#endif // DataDetectionResult_h
</ins></span></pre></div>
<a id="trunkSourceWebKit2SharedCocoaDataDetectionResultmm"></a>
<div class="addfile"><h4>Added: trunk/Source/WebKit2/Shared/Cocoa/DataDetectionResult.mm (0 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/Shared/Cocoa/DataDetectionResult.mm                                (rev 0)
+++ trunk/Source/WebKit2/Shared/Cocoa/DataDetectionResult.mm        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -0,0 +1,73 @@
</span><ins>+/*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import &quot;config.h&quot;
+#import &quot;DataDetectionResult.h&quot;
+
+#import &quot;ArgumentCodersCF.h&quot;
+#import &quot;Arguments.h&quot;
+#import &quot;WebCoreArgumentCoders.h&quot;
+#import &lt;WebCore/DataDetectorsCoreSPI.h&gt;
+#import &lt;WebCore/SoftLinking.h&gt;
+
+SOFT_LINK_PRIVATE_FRAMEWORK(DataDetectorsCore)
+SOFT_LINK_CLASS(DataDetectorsCore, DDScannerResult)
+
+namespace WebKit {
+
+#if ENABLE(DATA_DETECTION)
+
+void DataDetectionResult::encode(IPC::ArgumentEncoder&amp; encoder) const
+{
+    RetainPtr&lt;NSMutableData&gt; data = adoptNS([[NSMutableData alloc] init]);
+    RetainPtr&lt;NSKeyedArchiver&gt; archiver = adoptNS([[NSKeyedArchiver alloc] initForWritingWithMutableData:data.get()]);
+    [archiver setRequiresSecureCoding:YES];
+    [archiver encodeObject:results.get() forKey:@&quot;dataDetectorResults&quot;];
+    [archiver finishEncoding];
+    
+    IPC::encode(encoder, reinterpret_cast&lt;CFDataRef&gt;(data.get()));        
+}
+
+bool DataDetectionResult::decode(IPC::ArgumentDecoder&amp; decoder, DataDetectionResult&amp; result)
+{
+    RetainPtr&lt;CFDataRef&gt; data;
+    if (!IPC::decode(decoder, data))
+        return false;
+    
+    RetainPtr&lt;NSKeyedUnarchiver&gt; unarchiver = adoptNS([[NSKeyedUnarchiver alloc] initForReadingWithData:(NSData *)data.get()]);
+    [unarchiver setRequiresSecureCoding:YES];
+    @try {
+        result.results = [unarchiver decodeObjectOfClasses:[NSSet setWithArray:@[ [NSArray class], getDDScannerResultClass()] ] forKey:@&quot;dataDetectorResults&quot;];
+    } @catch (NSException *exception) {
+        LOG_ERROR(&quot;Failed to decode NSArray of DDScanResult: %@&quot;, exception);
+        return false;
+    }
+    
+    [unarchiver finishDecoding];
+    return true;
+}
+#endif
+
+}
</ins></span></pre></div>
<a id="trunkSourceWebKit2UIProcessAPICocoaWKWebViewmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -3122,6 +3122,10 @@
</span><span class="cx">     return nil;
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+- (NSArray *)_dataDetectionResults
+{
+    return [_contentView _dataDetectionResults];
+}
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><span class="cx"> - (void)_didRelaunchProcess
</span></span></pre></div>
<a id="trunkSourceWebKit2UIProcessAPICocoaWKWebViewPrivateh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebViewPrivate.h (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebViewPrivate.h        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebViewPrivate.h        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -170,6 +170,7 @@
</span><span class="cx"> - (void)_becomeFirstResponderWithSelectionMovingForward:(BOOL)selectingForward completionHandler:(void (^)(BOOL didBecomeFirstResponder))completionHandler WK_AVAILABLE(NA, 9_0);
</span><span class="cx"> 
</span><span class="cx"> - (id)_snapshotLayerContentsForBackForwardListItem:(WKBackForwardListItem *)item WK_AVAILABLE(NA, 9_0);
</span><ins>+- (NSArray *)_dataDetectionResults;
</ins><span class="cx"> 
</span><span class="cx"> #else
</span><span class="cx"> @property (readonly) NSColor *_pageExtendedBackgroundColor;
</span></span></pre></div>
<a id="trunkSourceWebKit2UIProcessCocoaWebPageProxyCocoamm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/UIProcess/Cocoa/WebPageProxyCocoa.mm (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/Cocoa/WebPageProxyCocoa.mm        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit2/UIProcess/Cocoa/WebPageProxyCocoa.mm        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -26,11 +26,20 @@
</span><span class="cx"> #import &quot;config.h&quot;
</span><span class="cx"> #import &quot;WebProcessProxy.h&quot;
</span><span class="cx"> 
</span><ins>+#import &quot;DataDetectionResult.h&quot;
+
</ins><span class="cx"> #import &lt;WebCore/SearchPopupMenuCocoa.h&gt;
</span><span class="cx"> #import &lt;wtf/cf/TypeCastsCF.h&gt;
</span><span class="cx"> 
</span><span class="cx"> namespace WebKit {
</span><span class="cx"> 
</span><ins>+#if ENABLE(DATA_DETECTION)
+void WebPageProxy::setDataDetectionResult(const DataDetectionResult&amp; dataDetectionResult)
+{
+    m_dataDetectionResults = dataDetectionResult.results;
+}
+#endif
+
</ins><span class="cx"> void WebPageProxy::saveRecentSearches(const String&amp; name, const Vector&lt;WebCore::RecentSearch&gt;&amp; searchItems)
</span><span class="cx"> {
</span><span class="cx">     if (!name) {
</span></span></pre></div>
<a id="trunkSourceWebKit2UIProcessWebPageProxyh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/UIProcess/WebPageProxy.h (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/WebPageProxy.h        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit2/UIProcess/WebPageProxy.h        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -296,6 +296,10 @@
</span><span class="cx"> 
</span><span class="cx">     WebsiteDataStore&amp; websiteDataStore() { return m_websiteDataStore; }
</span><span class="cx"> 
</span><ins>+#if ENABLE(DATA_DETECTION)
+    NSArray *dataDetectionResults() { return m_dataDetectionResults.get(); }
+#endif
+        
</ins><span class="cx"> #if ENABLE(ASYNC_SCROLLING)
</span><span class="cx">     RemoteScrollingCoordinatorProxy* scrollingCoordinatorProxy() const { return m_scrollingCoordinatorProxy.get(); }
</span><span class="cx"> #endif
</span><span class="lines">@@ -517,7 +521,9 @@
</span><span class="cx">     void contentSizeCategoryDidChange(const String&amp; contentSizeCategory);
</span><span class="cx">     void getLookupContextAtPoint(const WebCore::IntPoint&amp;, std::function&lt;void(const String&amp;, CallbackBase::Error)&gt;);
</span><span class="cx"> #endif
</span><del>-
</del><ins>+#if ENABLE(DATA_DETECTION)
+    void setDataDetectionResult(const DataDetectionResult&amp;);
+#endif
</ins><span class="cx">     void didCommitLayerTree(const WebKit::RemoteLayerTreeTransaction&amp;);
</span><span class="cx"> 
</span><span class="cx"> #if USE(COORDINATED_GRAPHICS_MULTIPROCESS)
</span><span class="lines">@@ -1408,6 +1414,10 @@
</span><span class="cx">     void disableInspectorNodeSearch();
</span><span class="cx"> #endif // PLATFORM(IOS)
</span><span class="cx"> 
</span><ins>+#if ENABLE(DATA_DETECTION)
+    RetainPtr&lt;NSArray&gt; m_dataDetectionResults;
+#endif
+
</ins><span class="cx">     void clearLoadDependentCallbacks();
</span><span class="cx"> 
</span><span class="cx">     void performDragControllerAction(DragControllerAction, WebCore::DragData&amp;, const String&amp; dragStorageName, const SandboxExtension::Handle&amp;, const SandboxExtension::HandleArray&amp;);
</span></span></pre></div>
<a id="trunkSourceWebKit2UIProcessWebPageProxymessagesin"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/UIProcess/WebPageProxy.messages.in (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/WebPageProxy.messages.in        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit2/UIProcess/WebPageProxy.messages.in        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -186,6 +186,9 @@
</span><span class="cx">     DisableDoubleTapGesturesDuringTapIfNecessary(uint64_t requestID)
</span><span class="cx">     DidFinishDrawingPagesToPDF(IPC::DataReference pdfData)
</span><span class="cx"> #endif
</span><ins>+#if ENABLE(DATA_DETECTION)
+    SetDataDetectionResult(struct WebKit::DataDetectionResult dataDetectionResult)
+#endif
</ins><span class="cx"> #if PLATFORM(GTK)
</span><span class="cx">     PrintFinishedCallback(WebCore::ResourceError error, uint64_t callbackID)
</span><span class="cx"> #endif
</span></span></pre></div>
<a id="trunkSourceWebKit2UIProcessiosWKContentViewInteractionh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.h (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.h        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.h        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -211,6 +211,7 @@
</span><span class="cx"> - (void)_disableInspectorNodeSearch;
</span><span class="cx"> - (void)_becomeFirstResponderWithSelectionMovingForward:(BOOL)selectingForward completionHandler:(void (^)(BOOL didBecomeFirstResponder))completionHandler;
</span><span class="cx"> - (void)_setDoubleTapGesturesEnabled:(BOOL)enabled;
</span><ins>+- (NSArray *)_dataDetectionResults;
</ins><span class="cx"> @end
</span><span class="cx"> 
</span><span class="cx"> #if HAVE(LINK_PREVIEW)
</span></span></pre></div>
<a id="trunkSourceWebKit2UIProcessiosWKContentViewInteractionmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -1100,6 +1100,13 @@
</span><span class="cx">     }
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+#if ENABLE(DATA_DETECTION)
+- (NSArray *)_dataDetectionResults
+{
+    return _page-&gt;dataDetectionResults();
+}
+#endif
+
</ins><span class="cx"> - (BOOL)gestureRecognizerShouldBegin:(UIGestureRecognizer *)gestureRecognizer
</span><span class="cx"> {
</span><span class="cx">     CGPoint point = [gestureRecognizer locationInView:self];
</span></span></pre></div>
<a id="trunkSourceWebKit2WebKit2xcodeprojprojectpbxproj"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -1692,6 +1692,8 @@
</span><span class="cx">                 C54256BA18BEC18C00DE4179 /* WKFormSelectControl.h in Headers */ = {isa = PBXBuildFile; fileRef = C54256B418BEC18C00DE4179 /* WKFormSelectControl.h */; };
</span><span class="cx">                 C55CB5B718C269CF00CA81E1 /* WKFormSelectPopover.mm in Sources */ = {isa = PBXBuildFile; fileRef = C57193BA18C149D0002D0F12 /* WKFormSelectPopover.mm */; };
</span><span class="cx">                 C55CB5B818C2A5D600CA81E1 /* WKFormSelectPicker.mm in Sources */ = {isa = PBXBuildFile; fileRef = C57193B918C149D0002D0F12 /* WKFormSelectPicker.mm */; };
</span><ins>+                C55F91701C595F630029E92D /* DataDetectionResult.mm in Sources */ = {isa = PBXBuildFile; fileRef = C55F916D1C595E440029E92D /* DataDetectionResult.mm */; };
+                C55F91711C59676E0029E92D /* DataDetectionResult.h in Headers */ = {isa = PBXBuildFile; fileRef = C55F916C1C595E440029E92D /* DataDetectionResult.h */; };
</ins><span class="cx">                 C57193BE18C14A44002D0F12 /* WKFormSelectControl.mm in Sources */ = {isa = PBXBuildFile; fileRef = C57193BD18C14A43002D0F12 /* WKFormSelectControl.mm */; };
</span><span class="cx">                 C574A37712E6099D002DFE98 /* WebDragClientMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = C554FFA212E4E8EA002F22C0 /* WebDragClientMac.mm */; };
</span><span class="cx">                 C574A58112E66681002DFE98 /* PasteboardTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = C574A57F12E66681002DFE98 /* PasteboardTypes.h */; };
</span><span class="lines">@@ -3935,6 +3937,8 @@
</span><span class="cx">                 C54256B318BEC18B00DE4179 /* WKFormPopover.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = WKFormPopover.mm; path = ios/forms/WKFormPopover.mm; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 C54256B418BEC18C00DE4179 /* WKFormSelectControl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = WKFormSelectControl.h; path = ios/forms/WKFormSelectControl.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 C554FFA212E4E8EA002F22C0 /* WebDragClientMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebDragClientMac.mm; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><ins>+                C55F916C1C595E440029E92D /* DataDetectionResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DataDetectionResult.h; sourceTree = &quot;&lt;group&gt;&quot;; };
+                C55F916D1C595E440029E92D /* DataDetectionResult.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = DataDetectionResult.mm; sourceTree = &quot;&lt;group&gt;&quot;; };
</ins><span class="cx">                 C57193B918C149D0002D0F12 /* WKFormSelectPicker.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = WKFormSelectPicker.mm; path = ios/forms/WKFormSelectPicker.mm; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 C57193BA18C149D0002D0F12 /* WKFormSelectPopover.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = WKFormSelectPopover.mm; path = ios/forms/WKFormSelectPopover.mm; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 C57193BD18C14A43002D0F12 /* WKFormSelectControl.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = WKFormSelectControl.mm; path = ios/forms/WKFormSelectControl.mm; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="lines">@@ -5418,6 +5422,8 @@
</span><span class="cx">                                 378E1A3B181ED6FF0031007A /* APIObject.mm */,
</span><span class="cx">                                 37BEC4DF19491486008B4286 /* CompletionHandlerCallChecker.h */,
</span><span class="cx">                                 37BEC4DE19491486008B4286 /* CompletionHandlerCallChecker.mm */,
</span><ins>+                                C55F916C1C595E440029E92D /* DataDetectionResult.h */,
+                                C55F916D1C595E440029E92D /* DataDetectionResult.mm */,
</ins><span class="cx">                                 1A781AE51C5714DA00FB96DD /* WebKitAdditions.mm */,
</span><span class="cx">                                 37C4C0921814B3AF003688B9 /* WKNSArray.h */,
</span><span class="cx">                                 37C4C0911814B3AF003688B9 /* WKNSArray.mm */,
</span><span class="lines">@@ -8101,6 +8107,7 @@
</span><span class="cx">                                 BC5744F012638FB3006F0F12 /* WebPopupItem.h in Headers */,
</span><span class="cx">                                 D3B9484711FF4B6500032B39 /* WebPopupMenu.h in Headers */,
</span><span class="cx">                                 BC574E631267D080006F0F12 /* WebPopupMenuProxy.h in Headers */,
</span><ins>+                                C55F91711C59676E0029E92D /* DataDetectionResult.h in Headers */,
</ins><span class="cx">                                 BC5750971268F3C6006F0F12 /* WebPopupMenuProxyMac.h in Headers */,
</span><span class="cx">                                 BCD597FF112B57BE00EC8C23 /* WebPreferences.h in Headers */,
</span><span class="cx">                                 7C85FD7C193415A8000177C4 /* WebPreferencesDefinitions.h in Headers */,
</span><span class="lines">@@ -9637,6 +9644,7 @@
</span><span class="cx">                                 37716A5A195B910500EE8B1B /* ProcessAssertion.cpp in Sources */,
</span><span class="cx">                                 86F9536418FF583C001DB2EF /* ProcessAssertionIOS.mm in Sources */,
</span><span class="cx">                                 9395E68C1BF2C35200F49BCE /* _WKPreviewElementInfo.mm in Sources */,
</span><ins>+                                C55F91701C595F630029E92D /* DataDetectionResult.mm in Sources */,
</ins><span class="cx">                                 1AE117F611DBB30900981615 /* ProcessLauncher.cpp in Sources */,
</span><span class="cx">                                 BC111B1D112F5FE600337BAB /* ProcessLauncherMac.mm in Sources */,
</span><span class="cx">                                 86E67A261910B9D900004AB7 /* ProcessThrottler.cpp in Sources */,
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebCoreSupportWebFrameLoaderClientcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -236,6 +236,16 @@
</span><span class="cx">     webPage-&gt;injectedBundleResourceLoadClient().didReceiveContentLengthForResource(webPage, m_frame, identifier, dataLength);
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+#if ENABLE(DATA_DETECTION)
+void WebFrameLoaderClient::dispatchDidFinishDataDetection(NSArray *detectionResults)
+{
+    WebPage* webPage = m_frame-&gt;page();
+    if (!webPage)
+        return;
+    webPage-&gt;setDataDetectionResults(detectionResults);
+}
+#endif
+
</ins><span class="cx"> void WebFrameLoaderClient::dispatchDidFinishLoading(DocumentLoader*, unsigned long identifier)
</span><span class="cx"> {
</span><span class="cx">     WebPage* webPage = m_frame-&gt;page();
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebCoreSupportWebFrameLoaderClienth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.h (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.h        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.h        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -81,6 +81,9 @@
</span><span class="cx">     virtual void dispatchDidFinishLoading(WebCore::DocumentLoader*, unsigned long identifier) override;
</span><span class="cx">     virtual void dispatchDidFailLoading(WebCore::DocumentLoader*, unsigned long identifier, const WebCore::ResourceError&amp;) override;
</span><span class="cx">     virtual bool dispatchDidLoadResourceFromMemoryCache(WebCore::DocumentLoader*, const WebCore::ResourceRequest&amp;, const WebCore::ResourceResponse&amp;, int length) override;
</span><ins>+#if ENABLE(DATA_DETECTION)
+    virtual void dispatchDidFinishDataDetection(NSArray *detectionResults) override;
+#endif
</ins><span class="cx">     
</span><span class="cx">     virtual void dispatchDidDispatchOnloadEvents() override;
</span><span class="cx">     virtual void dispatchDidReceiveServerRedirectForProvisionalLoad() override;
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebPageWebPagecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -170,6 +170,10 @@
</span><span class="cx"> #include &lt;wtf/RunLoop.h&gt;
</span><span class="cx"> #include &lt;wtf/TemporaryChange.h&gt;
</span><span class="cx"> 
</span><ins>+#if ENABLE(DATA_DETECTION)
+#include &quot;DataDetectionResult.h&quot;
+#endif
+
</ins><span class="cx"> #if ENABLE(MHTML)
</span><span class="cx"> #include &lt;WebCore/MHTMLArchive.h&gt;
</span><span class="cx"> #endif
</span><span class="lines">@@ -2977,6 +2981,15 @@
</span><span class="cx"> #endif
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+#if ENABLE(DATA_DETECTION)
+void WebPage::setDataDetectionResults(NSArray *detectionResults)
+{
+    DataDetectionResult dataDetectionResult;
+    dataDetectionResult.results = detectionResults;
+    send(Messages::WebPageProxy::SetDataDetectionResult(dataDetectionResult));
+}
+#endif
+
</ins><span class="cx"> #if PLATFORM(COCOA)
</span><span class="cx"> void WebPage::willCommitLayerTree(RemoteLayerTreeTransaction&amp; layerTransaction)
</span><span class="cx"> {
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebPageWebPageh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h (195721 => 195722)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h        2016-01-28 01:34:33 UTC (rev 195721)
+++ trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h        2016-01-28 01:36:06 UTC (rev 195722)
</span><span class="lines">@@ -109,6 +109,7 @@
</span><span class="cx"> #include &quot;ViewGestureGeometryCollector.h&quot;
</span><span class="cx"> #include &lt;wtf/RetainPtr.h&gt;
</span><span class="cx"> OBJC_CLASS CALayer;
</span><ins>+OBJC_CLASS NSArray;
</ins><span class="cx"> OBJC_CLASS NSDictionary;
</span><span class="cx"> OBJC_CLASS NSObject;
</span><span class="cx"> OBJC_CLASS WKAccessibilityWebPageObject;
</span><span class="lines">@@ -866,6 +867,10 @@
</span><span class="cx">     bool plugInIsPrimarySize(WebCore::HTMLPlugInImageElement&amp; pluginImageElement, unsigned &amp;pluginArea);
</span><span class="cx"> #endif
</span><span class="cx"> 
</span><ins>+#if ENABLE(DATA_DETECTION)
+    void setDataDetectionResults(NSArray *);
+#endif
+
</ins><span class="cx">     unsigned extendIncrementalRenderingSuppression();
</span><span class="cx">     void stopExtendingIncrementalRenderingSuppression(unsigned token);
</span><span class="cx">     bool shouldExtendIncrementalRenderingSuppression() { return !m_activeRenderingSuppressionTokens.isEmpty(); }
</span></span></pre>
</div>
</div>

</body>
</html>