<!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>[194117] trunk</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/194117">194117</a></dd>
<dt>Author</dt> <dd>timothy_horton@apple.com</dd>
<dt>Date</dt> <dd>2015-12-15 14:46:02 -0800 (Tue, 15 Dec 2015)</dd>
</dl>

<h3>Log Message</h3>
<pre>REGRESSION (<a href="http://trac.webkit.org/projects/webkit/changeset/191849">r191849</a>): There's no yellow bouncy highlight when using Find on Page on iOS
https://bugs.webkit.org/show_bug.cgi?id=152241
&lt;rdar://problem/23642574&gt;

Reviewed by Simon Fraser.

Tests: pageoverlay/overlay-small-frame-mouse-events.html
       pageoverlay/overlay-small-frame-paints.html

* page/PageOverlay.cpp:
(WebCore::PageOverlay::bounds):
Revert <a href="http://trac.webkit.org/projects/webkit/changeset/191849">r191849</a>'s change that made bounds() actually return the frame()
if we frame is manually overriden.

(WebCore::PageOverlay::mouseEvent):
Convert the mouse event the rest of the way into overlay coordinates (by
applying the overlay's frame origin) before deciding whether to handle
the event.

* page/PageOverlay.h:

* DerivedSources.make:
* WebCore.xcodeproj/project.pbxproj:
* testing/Internals.cpp:
(WebCore::Internals::installMockPageOverlay):
* testing/Internals.h:
* testing/Internals.idl:
* testing/MockPageOverlay.cpp: Added.
(WebCore::MockPageOverlay::create):
(WebCore::MockPageOverlay::MockPageOverlay):
(WebCore::MockPageOverlay::setFrame):
* testing/MockPageOverlay.h: Added.
(WebCore::MockPageOverlay::overlay):
* testing/MockPageOverlay.idl: Added.
* testing/MockPageOverlayClient.cpp:
(WebCore::MockPageOverlayClient::installOverlay):
(WebCore::MockPageOverlayClient::uninstallAllOverlays):
(WebCore::MockPageOverlayClient::pageOverlayDestroyed):
(WebCore::MockPageOverlayClient::drawRect):
(WebCore::MockPageOverlayClient::mouseEvent):
* testing/MockPageOverlayClient.h:
Make internals.installMockPageOverlay return a MockPageOverlay object so
tests can manipulate their overlay. For now, expose setFrame.
Also, log when MockPageOverlayClient gets asked to paint or receives a mouse event,
which will show up in test output. Slightly unconventional, but very convenient.

* pageoverlay/overlay-small-frame-mouse-events-expected.txt: Added.
* pageoverlay/overlay-small-frame-mouse-events.html: Added.
Add a test ensuring that small-frame overlays get mouse events.

* pageoverlay/overlay-small-frame-paints-expected.txt: Added.
* pageoverlay/overlay-small-frame-paints.html: Added.
Add a test ensuring that small-frame overlays get paint callbacks.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsChangeLog">trunk/LayoutTests/ChangeLog</a></li>
<li><a href="#trunkLayoutTestspageoverlayoverlayinstallationexpectedtxt">trunk/LayoutTests/pageoverlay/overlay-installation-expected.txt</a></li>
<li><a href="#trunkLayoutTestspageoverlayoverlaylargedocumentexpectedtxt">trunk/LayoutTests/pageoverlay/overlay-large-document-expected.txt</a></li>
<li><a href="#trunkLayoutTestspageoverlayoverlaylargedocumentscrolledexpectedtxt">trunk/LayoutTests/pageoverlay/overlay-large-document-scrolled-expected.txt</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreDerivedSourcesmake">trunk/Source/WebCore/DerivedSources.make</a></li>
<li><a href="#trunkSourceWebCoreWebCorexcodeprojprojectpbxproj">trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj</a></li>
<li><a href="#trunkSourceWebCorepagePageOverlaycpp">trunk/Source/WebCore/page/PageOverlay.cpp</a></li>
<li><a href="#trunkSourceWebCorepagePageOverlayh">trunk/Source/WebCore/page/PageOverlay.h</a></li>
<li><a href="#trunkSourceWebCoretestingInternalscpp">trunk/Source/WebCore/testing/Internals.cpp</a></li>
<li><a href="#trunkSourceWebCoretestingInternalsh">trunk/Source/WebCore/testing/Internals.h</a></li>
<li><a href="#trunkSourceWebCoretestingInternalsidl">trunk/Source/WebCore/testing/Internals.idl</a></li>
<li><a href="#trunkSourceWebCoretestingMockPageOverlayClientcpp">trunk/Source/WebCore/testing/MockPageOverlayClient.cpp</a></li>
<li><a href="#trunkSourceWebCoretestingMockPageOverlayClienth">trunk/Source/WebCore/testing/MockPageOverlayClient.h</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkLayoutTestspageoverlayoverlaysmallframemouseeventsexpectedtxt">trunk/LayoutTests/pageoverlay/overlay-small-frame-mouse-events-expected.txt</a></li>
<li><a href="#trunkLayoutTestspageoverlayoverlaysmallframemouseeventshtml">trunk/LayoutTests/pageoverlay/overlay-small-frame-mouse-events.html</a></li>
<li><a href="#trunkLayoutTestspageoverlayoverlaysmallframepaintsexpectedtxt">trunk/LayoutTests/pageoverlay/overlay-small-frame-paints-expected.txt</a></li>
<li><a href="#trunkLayoutTestspageoverlayoverlaysmallframepaintshtml">trunk/LayoutTests/pageoverlay/overlay-small-frame-paints.html</a></li>
<li><a href="#trunkSourceWebCoretestingMockPageOverlaycpp">trunk/Source/WebCore/testing/MockPageOverlay.cpp</a></li>
<li><a href="#trunkSourceWebCoretestingMockPageOverlayh">trunk/Source/WebCore/testing/MockPageOverlay.h</a></li>
<li><a href="#trunkSourceWebCoretestingMockPageOverlayidl">trunk/Source/WebCore/testing/MockPageOverlay.idl</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/ChangeLog (194116 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/ChangeLog        2015-12-15 22:33:55 UTC (rev 194116)
+++ trunk/LayoutTests/ChangeLog        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -1,3 +1,19 @@
</span><ins>+2015-12-15  Tim Horton  &lt;timothy_horton@apple.com&gt;
+
+        REGRESSION (r191849): There's no yellow bouncy highlight when using Find on Page on iOS
+        https://bugs.webkit.org/show_bug.cgi?id=152241
+        &lt;rdar://problem/23642574&gt;
+
+        Reviewed by Simon Fraser.
+
+        * pageoverlay/overlay-small-frame-mouse-events-expected.txt: Added.
+        * pageoverlay/overlay-small-frame-mouse-events.html: Added.
+        Add a test ensuring that small-frame overlays get mouse events.
+
+        * pageoverlay/overlay-small-frame-paints-expected.txt: Added.
+        * pageoverlay/overlay-small-frame-paints.html: Added.
+        Add a test ensuring that small-frame overlays get paint callbacks.
+
</ins><span class="cx"> 2015-12-15  Myles C. Maxfield  &lt;mmaxfield@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         [Font Features] TrueType fonts trigger real features even when synthesis is applied
</span></span></pre></div>
<a id="trunkLayoutTestspageoverlayoverlayinstallationexpectedtxt"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/pageoverlay/overlay-installation-expected.txt (194116 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/pageoverlay/overlay-installation-expected.txt        2015-12-15 22:33:55 UTC (rev 194116)
+++ trunk/LayoutTests/pageoverlay/overlay-installation-expected.txt        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -1,3 +1,5 @@
</span><ins>+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 0, 800, 600)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 0, 800, 600)
</ins><span class="cx"> View-relative:
</span><span class="cx"> (GraphicsLayer
</span><span class="cx">   (children 1
</span></span></pre></div>
<a id="trunkLayoutTestspageoverlayoverlaylargedocumentexpectedtxt"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/pageoverlay/overlay-large-document-expected.txt (194116 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/pageoverlay/overlay-large-document-expected.txt        2015-12-15 22:33:55 UTC (rev 194116)
+++ trunk/LayoutTests/pageoverlay/overlay-large-document-expected.txt        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -1,3 +1,8 @@
</span><ins>+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 0, 785, 585)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (512, 512, 512, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 512, 512, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (512, 0, 512, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 0, 512, 512)
</ins><span class="cx"> View-relative:
</span><span class="cx"> (GraphicsLayer
</span><span class="cx">   (children 1
</span></span></pre></div>
<a id="trunkLayoutTestspageoverlayoverlaylargedocumentscrolledexpectedtxt"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/pageoverlay/overlay-large-document-scrolled-expected.txt (194116 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/pageoverlay/overlay-large-document-scrolled-expected.txt        2015-12-15 22:33:55 UTC (rev 194116)
+++ trunk/LayoutTests/pageoverlay/overlay-large-document-scrolled-expected.txt        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -1,3 +1,8 @@
</span><ins>+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 0, 785, 585)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (4608, 4608, 400, 408)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (4096, 4608, 512, 408)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (4608, 4096, 400, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (4096, 4096, 512, 512)
</ins><span class="cx"> View-relative:
</span><span class="cx"> (GraphicsLayer
</span><span class="cx">   (children 1
</span></span></pre></div>
<a id="trunkLayoutTestspageoverlayoverlaysmallframemouseeventsexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/pageoverlay/overlay-small-frame-mouse-events-expected.txt (0 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/pageoverlay/overlay-small-frame-mouse-events-expected.txt                                (rev 0)
+++ trunk/LayoutTests/pageoverlay/overlay-small-frame-mouse-events-expected.txt        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -0,0 +1,22 @@
</span><ins>+CONSOLE MESSAGE: line 16: MockPageOverlayClient::mouseEvent location (105, 105)
+CONSOLE MESSAGE: line 17: MockPageOverlayClient::mouseEvent location (105, 105)
+CONSOLE MESSAGE: line 18: MockPageOverlayClient::mouseEvent location (105, 105)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 0, 10, 10)
+View-relative:
+(GraphicsLayer
+)
+
+
+Document-relative:
+(GraphicsLayer
+  (children 1
+    (GraphicsLayer
+      (position 100.00 100.00)
+      (anchor 0.00 0.00)
+      (bounds 10.00 10.00)
+      (drawsContent 1)
+      (backgroundColor #00000000)
+    )
+  )
+)
+
</ins></span></pre></div>
<a id="trunkLayoutTestspageoverlayoverlaysmallframemouseeventshtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/pageoverlay/overlay-small-frame-mouse-events.html (0 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/pageoverlay/overlay-small-frame-mouse-events.html                                (rev 0)
+++ trunk/LayoutTests/pageoverlay/overlay-small-frame-mouse-events.html        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -0,0 +1,28 @@
</span><ins>+&lt;html&gt;
+&lt;style&gt;
+body {
+    height: 5000px;
+    width: 5000px;
+}
+&lt;/style&gt;
+&lt;script&gt;
+window.onload = function () {
+    if (window.testRunner &amp;&amp; window.internals) {
+        testRunner.dumpAsText(true);
+        var overlay = internals.installMockPageOverlay(&quot;document&quot;);
+
+        overlay.setFrame(100, 100, 10, 10);
+
+        eventSender.mouseMoveTo(105, 105);
+        eventSender.mouseDown();
+        eventSender.mouseUp();
+
+        var layersResult = document.getElementById('layers');
+        layersResult.innerText = window.internals.pageOverlayLayerTreeAsText();
+    }
+}
+&lt;/script&gt;
+&lt;body&gt;
+    &lt;pre id=&quot;layers&quot; style=&quot;position: absolute; height: 1px; width: 1px; overflow: hidden;&quot;&gt;&lt;/pre&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkLayoutTestspageoverlayoverlaysmallframepaintsexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/pageoverlay/overlay-small-frame-paints-expected.txt (0 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/pageoverlay/overlay-small-frame-paints-expected.txt                                (rev 0)
+++ trunk/LayoutTests/pageoverlay/overlay-small-frame-paints-expected.txt        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -0,0 +1,19 @@
</span><ins>+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 0, 10, 10)
+View-relative:
+(GraphicsLayer
+)
+
+
+Document-relative:
+(GraphicsLayer
+  (children 1
+    (GraphicsLayer
+      (position 100.00 100.00)
+      (anchor 0.00 0.00)
+      (bounds 10.00 10.00)
+      (drawsContent 1)
+      (backgroundColor #00000000)
+    )
+  )
+)
+
</ins></span></pre></div>
<a id="trunkLayoutTestspageoverlayoverlaysmallframepaintshtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/pageoverlay/overlay-small-frame-paints.html (0 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/pageoverlay/overlay-small-frame-paints.html                                (rev 0)
+++ trunk/LayoutTests/pageoverlay/overlay-small-frame-paints.html        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -0,0 +1,24 @@
</span><ins>+&lt;html&gt;
+&lt;style&gt;
+body {
+    height: 5000px;
+    width: 5000px;
+}
+&lt;/style&gt;
+&lt;script&gt;
+window.onload = function () {
+    if (window.testRunner &amp;&amp; window.internals) {
+        testRunner.dumpAsText(true);
+        var overlay = internals.installMockPageOverlay(&quot;document&quot;);
+
+        overlay.setFrame(100, 100, 10, 10);
+
+        var layersResult = document.getElementById('layers');
+        layersResult.innerText = window.internals.pageOverlayLayerTreeAsText();
+    }
+}
+&lt;/script&gt;
+&lt;body&gt;
+    &lt;pre id=&quot;layers&quot; style=&quot;position: absolute; height: 1px; width: 1px; overflow: hidden;&quot;&gt;&lt;/pre&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (194116 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2015-12-15 22:33:55 UTC (rev 194116)
+++ trunk/Source/WebCore/ChangeLog        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -1,3 +1,51 @@
</span><ins>+2015-12-15  Tim Horton  &lt;timothy_horton@apple.com&gt;
+
+        REGRESSION (r191849): There's no yellow bouncy highlight when using Find on Page on iOS
+        https://bugs.webkit.org/show_bug.cgi?id=152241
+        &lt;rdar://problem/23642574&gt;
+
+        Reviewed by Simon Fraser.
+
+        Tests: pageoverlay/overlay-small-frame-mouse-events.html
+               pageoverlay/overlay-small-frame-paints.html
+
+        * page/PageOverlay.cpp:
+        (WebCore::PageOverlay::bounds):
+        Revert r191849's change that made bounds() actually return the frame()
+        if we frame is manually overriden.
+
+        (WebCore::PageOverlay::mouseEvent):
+        Convert the mouse event the rest of the way into overlay coordinates (by
+        applying the overlay's frame origin) before deciding whether to handle
+        the event.
+
+        * page/PageOverlay.h:
+
+        * DerivedSources.make:
+        * WebCore.xcodeproj/project.pbxproj:
+        * testing/Internals.cpp:
+        (WebCore::Internals::installMockPageOverlay):
+        * testing/Internals.h:
+        * testing/Internals.idl:
+        * testing/MockPageOverlay.cpp: Added.
+        (WebCore::MockPageOverlay::create):
+        (WebCore::MockPageOverlay::MockPageOverlay):
+        (WebCore::MockPageOverlay::setFrame):
+        * testing/MockPageOverlay.h: Added.
+        (WebCore::MockPageOverlay::overlay):
+        * testing/MockPageOverlay.idl: Added.
+        * testing/MockPageOverlayClient.cpp:
+        (WebCore::MockPageOverlayClient::installOverlay):
+        (WebCore::MockPageOverlayClient::uninstallAllOverlays):
+        (WebCore::MockPageOverlayClient::pageOverlayDestroyed):
+        (WebCore::MockPageOverlayClient::drawRect):
+        (WebCore::MockPageOverlayClient::mouseEvent):
+        * testing/MockPageOverlayClient.h:
+        Make internals.installMockPageOverlay return a MockPageOverlay object so
+        tests can manipulate their overlay. For now, expose setFrame.
+        Also, log when MockPageOverlayClient gets asked to paint or receives a mouse event,
+        which will show up in test output. Slightly unconventional, but very convenient.
+
</ins><span class="cx"> 2015-12-15  Myles C. Maxfield  &lt;mmaxfield@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         [Font Features] TrueType fonts trigger real features even when synthesis is applied
</span></span></pre></div>
<a id="trunkSourceWebCoreDerivedSourcesmake"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/DerivedSources.make (194116 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/DerivedSources.make        2015-12-15 22:33:55 UTC (rev 194116)
+++ trunk/Source/WebCore/DerivedSources.make        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -525,6 +525,7 @@
</span><span class="cx">     $(WebCore)/testing/MallocStatistics.idl \
</span><span class="cx">     $(WebCore)/testing/MemoryInfo.idl \
</span><span class="cx">     $(WebCore)/testing/MockContentFilterSettings.idl \
</span><ins>+        $(WebCore)/testing/MockPageOverlay.idl \
</ins><span class="cx">     $(WebCore)/testing/TypeConversions.idl \
</span><span class="cx">     $(WebCore)/workers/AbstractWorker.idl \
</span><span class="cx">     $(WebCore)/workers/DedicatedWorkerGlobalScope.idl \
</span></span></pre></div>
<a id="trunkSourceWebCoreWebCorexcodeprojprojectpbxproj"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj (194116 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj        2015-12-15 22:33:55 UTC (rev 194116)
+++ trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -130,7 +130,7 @@
</span><span class="cx">                 07277E5317D018CC0015534D /* JSMediaStreamTrack.h in Headers */ = {isa = PBXBuildFile; fileRef = 07277E4717D018CC0015534D /* JSMediaStreamTrack.h */; };
</span><span class="cx">                 07277E5417D018CC0015534D /* JSMediaStreamTrackEvent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 07277E4817D018CC0015534D /* JSMediaStreamTrackEvent.cpp */; };
</span><span class="cx">                 07277E5517D018CC0015534D /* JSMediaStreamTrackEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 07277E4917D018CC0015534D /* JSMediaStreamTrackEvent.h */; };
</span><del>-                07297FA71C1881C5003F0735 /* UserMediaPermissionCheck.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 07297FA51C1881C5003F0735 /* UserMediaPermissionCheck.cpp */; settings = {ASSET_TAGS = (); }; };
</del><ins>+                07297FA71C1881C5003F0735 /* UserMediaPermissionCheck.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 07297FA51C1881C5003F0735 /* UserMediaPermissionCheck.cpp */; };
</ins><span class="cx">                 07297FA81C1881C5003F0735 /* UserMediaPermissionCheck.h in Headers */ = {isa = PBXBuildFile; fileRef = 07297FA61C1881C5003F0735 /* UserMediaPermissionCheck.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="cx">                 072AE1E5183C0741000A5988 /* PluginReplacement.h in Headers */ = {isa = PBXBuildFile; fileRef = 072AE1DF183C0741000A5988 /* PluginReplacement.h */; };
</span><span class="cx">                 072AE1E6183C0741000A5988 /* QuickTimePluginReplacement.mm in Sources */ = {isa = PBXBuildFile; fileRef = 072AE1E0183C0741000A5988 /* QuickTimePluginReplacement.mm */; };
</span><span class="lines">@@ -1113,6 +1113,7 @@
</span><span class="cx">                 2D3EF44A1917915C00034184 /* WebCoreCALayerExtras.h in Headers */ = {isa = PBXBuildFile; fileRef = 2D3EF4461917915C00034184 /* WebCoreCALayerExtras.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="cx">                 2D3EF44B1917915C00034184 /* WebCoreCALayerExtras.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2D3EF4471917915C00034184 /* WebCoreCALayerExtras.mm */; };
</span><span class="cx">                 2D413F611A187A3F0041A521 /* LookupSPI.h in Headers */ = {isa = PBXBuildFile; fileRef = 2D413F601A187A3F0041A521 /* LookupSPI.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><ins>+                2D4150DE1C1F868C000A3BA2 /* JSMockPageOverlay.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2D6F3E921C1F85550061DBD4 /* JSMockPageOverlay.cpp */; };
</ins><span class="cx">                 2D46F04E17B96FBD005647F0 /* IntPoint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2D46F04D17B96FBD005647F0 /* IntPoint.cpp */; };
</span><span class="cx">                 2D46F05017B96FD2005647F0 /* IntSize.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2D46F04F17B96FD2005647F0 /* IntSize.cpp */; };
</span><span class="cx">                 2D481F00146B5C4C00AA7834 /* CrossfadeGeneratedImage.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2D2FC0541460CD6F00263633 /* CrossfadeGeneratedImage.cpp */; };
</span><span class="lines">@@ -1139,6 +1140,9 @@
</span><span class="cx">                 2D5C9D0119C7B52E00B3C5C1 /* PageOverlayController.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2D5C9CFD19C7B52E00B3C5C1 /* PageOverlayController.cpp */; };
</span><span class="cx">                 2D5C9D0219C7B52E00B3C5C1 /* PageOverlayController.h in Headers */ = {isa = PBXBuildFile; fileRef = 2D5C9CFE19C7B52E00B3C5C1 /* PageOverlayController.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="cx">                 2D6E468417D660F500ECF8BB /* PDFDocumentImageMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2D6E468217D660F500ECF8BB /* PDFDocumentImageMac.mm */; };
</span><ins>+                2D6F3E901C1ECB270061DBD4 /* MockPageOverlay.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2D6F3E8A1C1ECB1C0061DBD4 /* MockPageOverlay.cpp */; };
+                2D6F3E911C1ECB2F0061DBD4 /* MockPageOverlay.h in Headers */ = {isa = PBXBuildFile; fileRef = 2D6F3E8B1C1ECB1C0061DBD4 /* MockPageOverlay.h */; };
+                2D6F3E951C1F85550061DBD4 /* JSMockPageOverlay.h in Headers */ = {isa = PBXBuildFile; fileRef = 2D6F3E931C1F85550061DBD4 /* JSMockPageOverlay.h */; };
</ins><span class="cx">                 2D70BA1318074DDF0001908A /* PlatformCALayerCocoa.h in Headers */ = {isa = PBXBuildFile; fileRef = 2D70BA1218074DDF0001908A /* PlatformCALayerCocoa.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="cx">                 2D70BA1518074F860001908A /* PlatformCALayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2D70BA1418074F850001908A /* PlatformCALayer.cpp */; };
</span><span class="cx">                 2D76BB821945632400CFD29A /* RunLoopObserver.h in Headers */ = {isa = PBXBuildFile; fileRef = 2D76BB801945632400CFD29A /* RunLoopObserver.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="lines">@@ -8490,6 +8494,11 @@
</span><span class="cx">                 2D5C9CFD19C7B52E00B3C5C1 /* PageOverlayController.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = PageOverlayController.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 2D5C9CFE19C7B52E00B3C5C1 /* PageOverlayController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PageOverlayController.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 2D6E468217D660F500ECF8BB /* PDFDocumentImageMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PDFDocumentImageMac.mm; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><ins>+                2D6F3E8A1C1ECB1C0061DBD4 /* MockPageOverlay.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MockPageOverlay.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
+                2D6F3E8B1C1ECB1C0061DBD4 /* MockPageOverlay.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MockPageOverlay.h; sourceTree = &quot;&lt;group&gt;&quot;; };
+                2D6F3E8C1C1ECB1C0061DBD4 /* MockPageOverlay.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = MockPageOverlay.idl; sourceTree = &quot;&lt;group&gt;&quot;; };
+                2D6F3E921C1F85550061DBD4 /* JSMockPageOverlay.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSMockPageOverlay.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
+                2D6F3E931C1F85550061DBD4 /* JSMockPageOverlay.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSMockPageOverlay.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</ins><span class="cx">                 2D70BA1218074DDF0001908A /* PlatformCALayerCocoa.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PlatformCALayerCocoa.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 2D70BA1418074F850001908A /* PlatformCALayer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = PlatformCALayer.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 2D76BB801945632400CFD29A /* RunLoopObserver.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RunLoopObserver.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="lines">@@ -16401,6 +16410,9 @@
</span><span class="cx">                                 A1B5B29C1AAA846E008B6042 /* MockContentFilterSettings.cpp */,
</span><span class="cx">                                 A1B5B29D1AAA846E008B6042 /* MockContentFilterSettings.h */,
</span><span class="cx">                                 A19AEA1C1AAA7C4900B52B25 /* MockContentFilterSettings.idl */,
</span><ins>+                                2D6F3E8A1C1ECB1C0061DBD4 /* MockPageOverlay.cpp */,
+                                2D6F3E8B1C1ECB1C0061DBD4 /* MockPageOverlay.h */,
+                                2D6F3E8C1C1ECB1C0061DBD4 /* MockPageOverlay.idl */,
</ins><span class="cx">                                 2DAAE32C19DCAF6000E002D2 /* MockPageOverlayClient.cpp */,
</span><span class="cx">                                 2DAAE32D19DCAF6000E002D2 /* MockPageOverlayClient.h */,
</span><span class="cx">                                 EB081CD81696084400553730 /* TypeConversions.h */,
</span><span class="lines">@@ -16425,6 +16437,8 @@
</span><span class="cx">                                 CD5393D2175E018600C07123 /* JSMemoryInfo.h */,
</span><span class="cx">                                 A19AEA1D1AAA806E00B52B25 /* JSMockContentFilterSettings.cpp */,
</span><span class="cx">                                 A19AEA1E1AAA806E00B52B25 /* JSMockContentFilterSettings.h */,
</span><ins>+                                2D6F3E921C1F85550061DBD4 /* JSMockPageOverlay.cpp */,
+                                2D6F3E931C1F85550061DBD4 /* JSMockPageOverlay.h */,
</ins><span class="cx">                                 EBF5121A1696496C0056BD25 /* JSTypeConversions.cpp */,
</span><span class="cx">                                 EBF5121B1696496C0056BD25 /* JSTypeConversions.h */,
</span><span class="cx">                         );
</span><span class="lines">@@ -24486,6 +24500,7 @@
</span><span class="cx">                                 417DA71E13735DFA007C57FB /* JSInternals.h in Headers */,
</span><span class="cx">                                 A740B5A514C935AB00A77FA4 /* JSInternalSettings.h in Headers */,
</span><span class="cx">                                 53ED3FDF167A88E7006762E6 /* JSInternalSettingsGenerated.h in Headers */,
</span><ins>+                                2D6F3E911C1ECB2F0061DBD4 /* MockPageOverlay.h in Headers */,
</ins><span class="cx">                                 A740B59514C935AB00A77FA4 /* JSMallocStatistics.h in Headers */,
</span><span class="cx">                                 CD5393D4175E018600C07123 /* JSMemoryInfo.h in Headers */,
</span><span class="cx">                                 A19AEA211AAA808600B52B25 /* JSMockContentFilterSettings.h in Headers */,
</span><span class="lines">@@ -27563,6 +27578,7 @@
</span><span class="cx">                                 B22279CE0D00BF220071B782 /* SVGFEComponentTransferElement.h in Headers */,
</span><span class="cx">                                 B22279D10D00BF220071B782 /* SVGFECompositeElement.h in Headers */,
</span><span class="cx">                                 1921327511C0E6BB00456238 /* SVGFEConvolveMatrixElement.h in Headers */,
</span><ins>+                                2D6F3E951C1F85550061DBD4 /* JSMockPageOverlay.h in Headers */,
</ins><span class="cx">                                 B22279D40D00BF220071B782 /* SVGFEDiffuseLightingElement.h in Headers */,
</span><span class="cx">                                 B22279D70D00BF220071B782 /* SVGFEDisplacementMapElement.h in Headers */,
</span><span class="cx">                                 B22279DA0D00BF220071B782 /* SVGFEDistantLightElement.h in Headers */,
</span><span class="lines">@@ -28402,6 +28418,7 @@
</span><span class="cx">                         isa = PBXSourcesBuildPhase;
</span><span class="cx">                         buildActionMask = 2147483647;
</span><span class="cx">                         files = (
</span><ins>+                                2D4150DE1C1F868C000A3BA2 /* JSMockPageOverlay.cpp in Sources */,
</ins><span class="cx">                                 417DA6D913734E6E007C57FB /* Internals.cpp in Sources */,
</span><span class="cx">                                 E179F0DA1B9774FE00ED0A27 /* Internals.mm in Sources */,
</span><span class="cx">                                 A7BF7EDF14C9175A0014489D /* InternalSettings.cpp in Sources */,
</span><span class="lines">@@ -28413,6 +28430,7 @@
</span><span class="cx">                                 CD5393D3175E018600C07123 /* JSMemoryInfo.cpp in Sources */,
</span><span class="cx">                                 A19AEA221AAA808A00B52B25 /* JSMockContentFilterSettings.cpp in Sources */,
</span><span class="cx">                                 A1E5B31F1AAD1DA4006EBEFB /* JSMockContentFilterSettingsCustom.cpp in Sources */,
</span><ins>+                                2D6F3E901C1ECB270061DBD4 /* MockPageOverlay.cpp in Sources */,
</ins><span class="cx">                                 EBF5121C1696496C0056BD25 /* JSTypeConversions.cpp in Sources */,
</span><span class="cx">                                 CDC26B40160A8CC60026757B /* MockCDM.cpp in Sources */,
</span><span class="cx">                                 A1BF6B821AA96C7D00AF4A8A /* MockContentFilter.cpp in Sources */,
</span></span></pre></div>
<a id="trunkSourceWebCorepagePageOverlaycpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/page/PageOverlay.cpp (194116 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/page/PageOverlay.cpp        2015-12-15 22:33:55 UTC (rev 194116)
+++ trunk/Source/WebCore/page/PageOverlay.cpp        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -75,7 +75,7 @@
</span><span class="cx"> IntRect PageOverlay::bounds() const
</span><span class="cx"> {
</span><span class="cx">     if (!m_overrideFrame.isEmpty())
</span><del>-        return m_overrideFrame;
</del><ins>+        return { { }, m_overrideFrame.size() };
</ins><span class="cx"> 
</span><span class="cx">     FrameView* frameView = m_page-&gt;mainFrame().view();
</span><span class="cx"> 
</span><span class="lines">@@ -187,6 +187,7 @@
</span><span class="cx"> 
</span><span class="cx">     if (m_overlayType == PageOverlay::OverlayType::Document)
</span><span class="cx">         mousePositionInOverlayCoordinates = m_page-&gt;mainFrame().view()-&gt;windowToContents(mousePositionInOverlayCoordinates);
</span><ins>+    mousePositionInOverlayCoordinates.moveBy(-frame().location());
</ins><span class="cx"> 
</span><span class="cx">     // Ignore events outside the bounds.
</span><span class="cx">     if (m_shouldIgnoreMouseEventsOutsideBounds &amp;&amp; !bounds().contains(mousePositionInOverlayCoordinates))
</span></span></pre></div>
<a id="trunkSourceWebCorepagePageOverlayh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/page/PageOverlay.h (194116 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/page/PageOverlay.h        2015-12-15 22:33:55 UTC (rev 194116)
+++ trunk/Source/WebCore/page/PageOverlay.h        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -78,6 +78,7 @@
</span><span class="cx">     virtual PageOverlayID pageOverlayID() const { return m_pageOverlayID; }
</span><span class="cx"> 
</span><span class="cx">     void setPage(Page*);
</span><ins>+    Page* page() const { return m_page; }
</ins><span class="cx">     WEBCORE_EXPORT void setNeedsDisplay(const IntRect&amp; dirtyRect);
</span><span class="cx">     WEBCORE_EXPORT void setNeedsDisplay();
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCoretestingInternalscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/testing/Internals.cpp (194116 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/testing/Internals.cpp        2015-12-15 22:33:55 UTC (rev 194116)
+++ trunk/Source/WebCore/testing/Internals.cpp        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -82,6 +82,7 @@
</span><span class="cx"> #include &quot;MediaPlayer.h&quot;
</span><span class="cx"> #include &quot;MemoryCache.h&quot;
</span><span class="cx"> #include &quot;MemoryInfo.h&quot;
</span><ins>+#include &quot;MockPageOverlay.h&quot;
</ins><span class="cx"> #include &quot;MockPageOverlayClient.h&quot;
</span><span class="cx"> #include &quot;Page.h&quot;
</span><span class="cx"> #include &quot;PageCache.h&quot;
</span><span class="lines">@@ -2990,16 +2991,15 @@
</span><span class="cx"> }
</span><span class="cx"> #endif
</span><span class="cx"> 
</span><del>-
-void Internals::installMockPageOverlay(const String&amp; overlayType, ExceptionCode&amp; ec)
</del><ins>+RefPtr&lt;MockPageOverlay&gt; Internals::installMockPageOverlay(const String&amp; overlayType, ExceptionCode&amp; ec)
</ins><span class="cx"> {
</span><span class="cx">     Document* document = contextDocument();
</span><span class="cx">     if (!document || !document-&gt;frame()) {
</span><span class="cx">         ec = INVALID_ACCESS_ERR;
</span><del>-        return;
</del><ins>+        return nullptr;
</ins><span class="cx">     }
</span><span class="cx"> 
</span><del>-    MockPageOverlayClient::singleton().installOverlay(document-&gt;frame()-&gt;mainFrame(), overlayType == &quot;view&quot; ? PageOverlay::OverlayType::View : PageOverlay::OverlayType::Document);
</del><ins>+    return MockPageOverlayClient::singleton().installOverlay(document-&gt;frame()-&gt;mainFrame(), overlayType == &quot;view&quot; ? PageOverlay::OverlayType::View : PageOverlay::OverlayType::Document);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> String Internals::pageOverlayLayerTreeAsText(ExceptionCode&amp; ec) const
</span></span></pre></div>
<a id="trunkSourceWebCoretestingInternalsh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/testing/Internals.h (194116 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/testing/Internals.h        2015-12-15 22:33:55 UTC (rev 194116)
+++ trunk/Source/WebCore/testing/Internals.h        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -58,6 +58,7 @@
</span><span class="cx"> class MallocStatistics;
</span><span class="cx"> class MediaSession;
</span><span class="cx"> class MemoryInfo;
</span><ins>+class MockPageOverlay;
</ins><span class="cx"> class Node;
</span><span class="cx"> class Page;
</span><span class="cx"> class Range;
</span><span class="lines">@@ -417,7 +418,7 @@
</span><span class="cx">     void simulateSystemSleep() const;
</span><span class="cx">     void simulateSystemWake() const;
</span><span class="cx"> 
</span><del>-    void installMockPageOverlay(const String&amp; overlayType, ExceptionCode&amp;);
</del><ins>+    RefPtr&lt;MockPageOverlay&gt; installMockPageOverlay(const String&amp; overlayType, ExceptionCode&amp;);
</ins><span class="cx">     String pageOverlayLayerTreeAsText(ExceptionCode&amp;) const;
</span><span class="cx"> 
</span><span class="cx">     void setPageMuted(bool);
</span></span></pre></div>
<a id="trunkSourceWebCoretestingInternalsidl"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/testing/Internals.idl (194116 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/testing/Internals.idl        2015-12-15 22:33:55 UTC (rev 194116)
+++ trunk/Source/WebCore/testing/Internals.idl        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -385,7 +385,7 @@
</span><span class="cx">     [Conditional=VIDEO] void simulateSystemWake();
</span><span class="cx">     [Conditional=VIDEO] boolean elementIsBlockingDisplaySleep(Element element);
</span><span class="cx"> 
</span><del>-    [RaisesException] void installMockPageOverlay(PageOverlayType type);
</del><ins>+    [RaisesException] MockPageOverlay installMockPageOverlay(PageOverlayType type);
</ins><span class="cx">     [RaisesException] DOMString pageOverlayLayerTreeAsText();
</span><span class="cx"> 
</span><span class="cx">     void setPageMuted(boolean muted);
</span></span></pre></div>
<a id="trunkSourceWebCoretestingMockPageOverlaycpp"></a>
<div class="addfile"><h4>Added: trunk/Source/WebCore/testing/MockPageOverlay.cpp (0 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/testing/MockPageOverlay.cpp                                (rev 0)
+++ trunk/Source/WebCore/testing/MockPageOverlay.cpp        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -0,0 +1,55 @@
</span><ins>+/*
+ * Copyright (C) 2015 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.
+ */
+
+#include &quot;config.h&quot;
+#include &quot;MockPageOverlay.h&quot;
+
+#include &quot;Document.h&quot;
+#include &quot;GraphicsContext.h&quot;
+#include &quot;GraphicsLayer.h&quot;
+#include &quot;MainFrame.h&quot;
+#include &quot;PageOverlayController.h&quot;
+#include &quot;PlatformMouseEvent.h&quot;
+#include &lt;wtf/NeverDestroyed.h&gt;
+#include &lt;wtf/text/StringBuilder.h&gt;
+
+namespace WebCore {
+
+Ref&lt;MockPageOverlay&gt; MockPageOverlay::create(PageOverlay* overlay)
+{
+    return adoptRef(*new MockPageOverlay(overlay));
+}
+
+MockPageOverlay::MockPageOverlay(PageOverlay* overlay)
+    : m_overlay(overlay)
+{
+}
+
+void MockPageOverlay::setFrame(double x, double y, double width, double height)
+{
+    m_overlay-&gt;setFrame(IntRect(x, y, width, height));
+}
+
+}
</ins></span></pre></div>
<a id="trunkSourceWebCoretestingMockPageOverlayh"></a>
<div class="addfile"><h4>Added: trunk/Source/WebCore/testing/MockPageOverlay.h (0 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/testing/MockPageOverlay.h                                (rev 0)
+++ trunk/Source/WebCore/testing/MockPageOverlay.h        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -0,0 +1,51 @@
</span><ins>+/*
+ * Copyright (C) 2015 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 MockPageOverlay_h
+#define MockPageOverlay_h
+
+#include &quot;PageOverlay.h&quot;
+
+namespace WebCore {
+
+class MainFrame;
+
+class MockPageOverlay : public RefCounted&lt;MockPageOverlay&gt; {
+public:
+    static Ref&lt;MockPageOverlay&gt; create(PageOverlay*);
+
+    void setFrame(double x, double y, double width, double height);
+
+    PageOverlay* overlay() const { return m_overlay.get(); }
+
+private:
+    explicit MockPageOverlay(PageOverlay*);
+
+    RefPtr&lt;PageOverlay&gt; m_overlay;
+};
+
+}
+
+#endif // MockPageOverlay_h
</ins></span></pre></div>
<a id="trunkSourceWebCoretestingMockPageOverlayidl"></a>
<div class="addfile"><h4>Added: trunk/Source/WebCore/testing/MockPageOverlay.idl (0 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/testing/MockPageOverlay.idl                                (rev 0)
+++ trunk/Source/WebCore/testing/MockPageOverlay.idl        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -0,0 +1,31 @@
</span><ins>+/*
+ * Copyright (C) 2015 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.
+ */
+
+[
+    NoInterfaceObject,
+    ImplementationLacksVTable
+] interface MockPageOverlay {
+    void setFrame(double x, double y, double width, double height);
+};
</ins></span></pre></div>
<a id="trunkSourceWebCoretestingMockPageOverlayClientcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/testing/MockPageOverlayClient.cpp (194116 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/testing/MockPageOverlayClient.cpp        2015-12-15 22:33:55 UTC (rev 194116)
+++ trunk/Source/WebCore/testing/MockPageOverlayClient.cpp        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -26,11 +26,14 @@
</span><span class="cx"> #include &quot;config.h&quot;
</span><span class="cx"> #include &quot;MockPageOverlayClient.h&quot;
</span><span class="cx"> 
</span><ins>+#include &quot;Document.h&quot;
</ins><span class="cx"> #include &quot;GraphicsContext.h&quot;
</span><span class="cx"> #include &quot;GraphicsLayer.h&quot;
</span><span class="cx"> #include &quot;MainFrame.h&quot;
</span><span class="cx"> #include &quot;PageOverlayController.h&quot;
</span><ins>+#include &quot;PlatformMouseEvent.h&quot;
</ins><span class="cx"> #include &lt;wtf/NeverDestroyed.h&gt;
</span><ins>+#include &lt;wtf/text/StringBuilder.h&gt;
</ins><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><span class="lines">@@ -44,19 +47,24 @@
</span><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void MockPageOverlayClient::installOverlay(MainFrame&amp; mainFrame, PageOverlay::OverlayType overlayType)
</del><ins>+Ref&lt;MockPageOverlay&gt; MockPageOverlayClient::installOverlay(MainFrame&amp; mainFrame, PageOverlay::OverlayType overlayType)
</ins><span class="cx"> {
</span><del>-    RefPtr&lt;PageOverlay&gt; overlay = PageOverlay::create(*this, overlayType);
-    mainFrame.pageOverlayController().installPageOverlay(overlay, PageOverlay::FadeMode::DoNotFade);
-    m_overlays.add(overlay.get());
</del><ins>+    auto overlay = PageOverlay::create(*this, overlayType);
+    mainFrame.pageOverlayController().installPageOverlay(overlay.ptr(), PageOverlay::FadeMode::DoNotFade);
+
+    auto mockOverlay = MockPageOverlay::create(overlay.ptr());
+    m_overlays.add(mockOverlay.ptr());
+
+    return mockOverlay;
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> void MockPageOverlayClient::uninstallAllOverlays()
</span><span class="cx"> {
</span><span class="cx">     while (!m_overlays.isEmpty()) {
</span><del>-        PageOverlay* overlay = m_overlays.takeAny();
-        ASSERT(overlay-&gt;controller());
-        overlay-&gt;controller()-&gt;uninstallPageOverlay(overlay, PageOverlay::FadeMode::DoNotFade);
</del><ins>+        MockPageOverlay* mockOverlay = m_overlays.takeAny();
+        PageOverlayController* overlayController = mockOverlay-&gt;overlay()-&gt;controller();
+        ASSERT(overlayController);
+        overlayController-&gt;uninstallPageOverlay(mockOverlay-&gt;overlay(), PageOverlay::FadeMode::DoNotFade);
</ins><span class="cx">     }
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -67,7 +75,12 @@
</span><span class="cx"> 
</span><span class="cx"> void MockPageOverlayClient::pageOverlayDestroyed(PageOverlay&amp; overlay)
</span><span class="cx"> {
</span><del>-    m_overlays.remove(&amp;overlay);
</del><ins>+    for (auto&amp; mockOverlay : m_overlays) {
+        if (mockOverlay-&gt;overlay() == &amp;overlay) {
+            m_overlays.remove(mockOverlay);
+            return;
+        }
+    }
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> void MockPageOverlayClient::willMoveToPage(PageOverlay&amp;, Page*)
</span><span class="lines">@@ -80,8 +93,20 @@
</span><span class="cx">         overlay.setNeedsDisplay();
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void MockPageOverlayClient::drawRect(PageOverlay&amp; overlay, GraphicsContext&amp; context, const IntRect&amp;)
</del><ins>+void MockPageOverlayClient::drawRect(PageOverlay&amp; overlay, GraphicsContext&amp; context, const IntRect&amp; dirtyRect)
</ins><span class="cx"> {
</span><ins>+    StringBuilder message;
+    message.appendLiteral(&quot;MockPageOverlayClient::drawRect dirtyRect (&quot;);
+    message.appendNumber(dirtyRect.x());
+    message.appendLiteral(&quot;, &quot;);
+    message.appendNumber(dirtyRect.y());
+    message.appendLiteral(&quot;, &quot;);
+    message.appendNumber(dirtyRect.width());
+    message.appendLiteral(&quot;, &quot;);
+    message.appendNumber(dirtyRect.height());
+    message.appendLiteral(&quot;)&quot;);
+    overlay.page()-&gt;mainFrame().document()-&gt;addConsoleMessage(MessageSource::Other, MessageLevel::Debug, message.toString());
+
</ins><span class="cx">     GraphicsContextStateSaver stateSaver(context);
</span><span class="cx"> 
</span><span class="cx">     FloatRect insetRect = overlay.bounds();
</span><span class="lines">@@ -97,8 +122,16 @@
</span><span class="cx">     context.strokeRect(insetRect, 20);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-bool MockPageOverlayClient::mouseEvent(PageOverlay&amp;, const PlatformMouseEvent&amp;)
</del><ins>+bool MockPageOverlayClient::mouseEvent(PageOverlay&amp; overlay, const PlatformMouseEvent&amp; event)
</ins><span class="cx"> {
</span><ins>+    StringBuilder message;
+    message.appendLiteral(&quot;MockPageOverlayClient::mouseEvent location (&quot;);
+    message.appendNumber(event.position().x());
+    message.appendLiteral(&quot;, &quot;);
+    message.appendNumber(event.position().y());
+    message.appendLiteral(&quot;)&quot;);
+    overlay.page()-&gt;mainFrame().document()-&gt;addConsoleMessage(MessageSource::Other, MessageLevel::Debug, message.toString());
+
</ins><span class="cx">     return false;
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCoretestingMockPageOverlayClienth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/testing/MockPageOverlayClient.h (194116 => 194117)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/testing/MockPageOverlayClient.h        2015-12-15 22:33:55 UTC (rev 194116)
+++ trunk/Source/WebCore/testing/MockPageOverlayClient.h        2015-12-15 22:46:02 UTC (rev 194117)
</span><span class="lines">@@ -26,6 +26,7 @@
</span><span class="cx"> #ifndef MockPageOverlayClient_h
</span><span class="cx"> #define MockPageOverlayClient_h
</span><span class="cx"> 
</span><ins>+#include &quot;MockPageOverlay.h&quot;
</ins><span class="cx"> #include &quot;PageOverlay.h&quot;
</span><span class="cx"> #include &lt;wtf/HashSet.h&gt;
</span><span class="cx"> 
</span><span class="lines">@@ -40,7 +41,7 @@
</span><span class="cx"> 
</span><span class="cx">     explicit MockPageOverlayClient();
</span><span class="cx"> 
</span><del>-    void installOverlay(MainFrame&amp;, PageOverlay::OverlayType);
</del><ins>+    Ref&lt;MockPageOverlay&gt; installOverlay(MainFrame&amp;, PageOverlay::OverlayType);
</ins><span class="cx">     void uninstallAllOverlays();
</span><span class="cx"> 
</span><span class="cx">     String layerTreeAsText(MainFrame&amp;);
</span><span class="lines">@@ -59,7 +60,7 @@
</span><span class="cx">     virtual bool copyAccessibilityAttributeBoolValueForPoint(PageOverlay&amp;, String /* attribute */, FloatPoint, bool&amp;) override;
</span><span class="cx">     virtual Vector&lt;String&gt; copyAccessibilityAttributeNames(PageOverlay&amp;, bool /* parameterizedNames */) override;
</span><span class="cx"> 
</span><del>-    HashSet&lt;PageOverlay*&gt; m_overlays;
</del><ins>+    HashSet&lt;MockPageOverlay*&gt; m_overlays;
</ins><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> }
</span></span></pre>
</div>
</div>

</body>
</html>