<!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>[208916] 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/208916">208916</a></dd>
<dt>Author</dt> <dd>simon.fraser@apple.com</dd>
<dt>Date</dt> <dd>2016-11-18 19:33:36 -0800 (Fri, 18 Nov 2016)</dd>
</dl>
<h3>Log Message</h3>
<pre>Remove use of std::chrono in WebPage and entrained code
https://bugs.webkit.org/show_bug.cgi?id=164967
Reviewed by Tim Horton.
Replace std::chrono with Seconds and Monotonic Time.
Use more C++11 initialization for WebPage data members.
Source/WebCore:
* page/ChromeClient.h:
* page/FrameView.cpp:
(WebCore::FrameView::scrollPositionChanged):
(WebCore::FrameView::setScrollVelocity):
* page/FrameView.h:
* platform/Timer.h:
(WebCore::TimerBase::startRepeating):
(WebCore::TimerBase::startOneShot):
(WebCore::TimerBase::augmentFireInterval):
(WebCore::TimerBase::augmentRepeatInterval):
* platform/graphics/TiledBacking.h:
(WebCore::VelocityData::VelocityData):
* platform/graphics/ca/TileController.cpp:
(WebCore::TileController::adjustTileCoverageRect):
Source/WebKit2:
* Shared/VisibleContentRectUpdateInfo.cpp:
(WebKit::operator<<):
* Shared/VisibleContentRectUpdateInfo.h:
(WebKit::VisibleContentRectUpdateInfo::VisibleContentRectUpdateInfo):
(WebKit::VisibleContentRectUpdateInfo::timestamp):
* Shared/WebCoreArgumentCoders.cpp:
(IPC::ArgumentCoder<MonotonicTime>::encode):
(IPC::ArgumentCoder<MonotonicTime>::decode):
(IPC::ArgumentCoder<Seconds>::encode):
(IPC::ArgumentCoder<Seconds>::decode):
* Shared/WebCoreArgumentCoders.h:
* UIProcess/ios/WKContentView.mm:
(WebKit::HistoricalVelocityData::HistoricalVelocityData):
(WebKit::HistoricalVelocityData::velocityForNewData):
(WebKit::HistoricalVelocityData::append):
(-[WKContentView didUpdateVisibleRect:unobscuredRect:unobscuredRectInScrollViewCoordinates:obscuredInset:scale:minimumScale:inStableState:isChangingObscuredInsetsInteractively:enclosedInScrollableAncestorView:]):
* WebProcess/WebCoreSupport/WebChromeClient.h:
* WebProcess/WebCoreSupport/ios/WebChromeClientIOS.mm:
(WebKit::WebChromeClient::eventThrottlingDelay):
* WebProcess/WebPage/ViewUpdateDispatcher.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::WebPage):
(WebKit::m_userActivityHysteresis):
(WebKit::WebPage::didFlushLayerTreeAtTime):
(WebKit::WebPage::didCommitLoad):
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::eventThrottlingDelay):
(WebKit::WebPage::updateVisibleContentRects):
* WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
(WebKit::RemoteLayerTreeDrawingArea::flushLayers):</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCorepageChromeClienth">trunk/Source/WebCore/page/ChromeClient.h</a></li>
<li><a href="#trunkSourceWebCorepageFrameViewcpp">trunk/Source/WebCore/page/FrameView.cpp</a></li>
<li><a href="#trunkSourceWebCorepageFrameViewh">trunk/Source/WebCore/page/FrameView.h</a></li>
<li><a href="#trunkSourceWebCoreplatformTimerh">trunk/Source/WebCore/platform/Timer.h</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicsTiledBackingh">trunk/Source/WebCore/platform/graphics/TiledBacking.h</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicscaTileControllercpp">trunk/Source/WebCore/platform/graphics/ca/TileController.cpp</a></li>
<li><a href="#trunkSourceWebKit2ChangeLog">trunk/Source/WebKit2/ChangeLog</a></li>
<li><a href="#trunkSourceWebKit2SharedVisibleContentRectUpdateInfocpp">trunk/Source/WebKit2/Shared/VisibleContentRectUpdateInfo.cpp</a></li>
<li><a href="#trunkSourceWebKit2SharedVisibleContentRectUpdateInfoh">trunk/Source/WebKit2/Shared/VisibleContentRectUpdateInfo.h</a></li>
<li><a href="#trunkSourceWebKit2SharedWebCoreArgumentCoderscpp">trunk/Source/WebKit2/Shared/WebCoreArgumentCoders.cpp</a></li>
<li><a href="#trunkSourceWebKit2SharedWebCoreArgumentCodersh">trunk/Source/WebKit2/Shared/WebCoreArgumentCoders.h</a></li>
<li><a href="#trunkSourceWebKit2UIProcessiosWKContentViewmm">trunk/Source/WebKit2/UIProcess/ios/WKContentView.mm</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebCoreSupportWebChromeClienth">trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.h</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebCoreSupportiosWebChromeClientIOSmm">trunk/Source/WebKit2/WebProcess/WebCoreSupport/ios/WebChromeClientIOS.mm</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebPageViewUpdateDispatcherh">trunk/Source/WebKit2/WebProcess/WebPage/ViewUpdateDispatcher.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>
<li><a href="#trunkSourceWebKit2WebProcessWebPageiosWebPageIOSmm">trunk/Source/WebKit2/WebProcess/WebPage/ios/WebPageIOS.mm</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebPagemacRemoteLayerTreeDrawingAreamm">trunk/Source/WebKit2/WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebCore/ChangeLog        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -1,3 +1,29 @@
</span><ins>+2016-11-18 Simon Fraser <simon.fraser@apple.com>
+
+ Remove use of std::chrono in WebPage and entrained code
+ https://bugs.webkit.org/show_bug.cgi?id=164967
+
+ Reviewed by Tim Horton.
+
+ Replace std::chrono with Seconds and Monotonic Time.
+
+ Use more C++11 initialization for WebPage data members.
+
+ * page/ChromeClient.h:
+ * page/FrameView.cpp:
+ (WebCore::FrameView::scrollPositionChanged):
+ (WebCore::FrameView::setScrollVelocity):
+ * page/FrameView.h:
+ * platform/Timer.h:
+ (WebCore::TimerBase::startRepeating):
+ (WebCore::TimerBase::startOneShot):
+ (WebCore::TimerBase::augmentFireInterval):
+ (WebCore::TimerBase::augmentRepeatInterval):
+ * platform/graphics/TiledBacking.h:
+ (WebCore::VelocityData::VelocityData):
+ * platform/graphics/ca/TileController.cpp:
+ (WebCore::TileController::adjustTileCoverageRect):
+
</ins><span class="cx"> 2016-11-18 Dean Jackson <dino@apple.com>
</span><span class="cx">
</span><span class="cx"> AX: "(inverted-colors)" media query only matches on page reload; should match on change
</span></span></pre></div>
<a id="trunkSourceWebCorepageChromeClienth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/page/ChromeClient.h (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/page/ChromeClient.h        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebCore/page/ChromeClient.h        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -41,6 +41,7 @@
</span><span class="cx"> #include "WebCoreKeyboardUIMode.h"
</span><span class="cx"> #include <runtime/ConsoleTypes.h>
</span><span class="cx"> #include <wtf/Forward.h>
</span><ins>+#include <wtf/Seconds.h>
</ins><span class="cx"> #include <wtf/Vector.h>
</span><span class="cx">
</span><span class="cx"> #if ENABLE(WIRELESS_PLAYBACK_TARGET)
</span><span class="lines">@@ -232,7 +233,7 @@
</span><span class="cx"> virtual void didPreventDefaultForEvent() = 0;
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>- virtual std::chrono::milliseconds eventThrottlingDelay() { return 0ms; };
</del><ins>+ virtual Seconds eventThrottlingDelay() { return Seconds(0); };
</ins><span class="cx">
</span><span class="cx"> #if PLATFORM(IOS)
</span><span class="cx"> virtual void didReceiveMobileDocType(bool) = 0;
</span></span></pre></div>
<a id="trunkSourceWebCorepageFrameViewcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/page/FrameView.cpp (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/page/FrameView.cpp        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebCore/page/FrameView.cpp        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -2438,13 +2438,13 @@
</span><span class="cx"> void FrameView::scrollPositionChanged(const ScrollPosition& oldPosition, const ScrollPosition& newPosition)
</span><span class="cx"> {
</span><span class="cx"> Page* page = frame().page();
</span><del>- auto throttlingDelay = page ? page->chrome().client().eventThrottlingDelay() : 0ms;
</del><ins>+ Seconds throttlingDelay = page ? page->chrome().client().eventThrottlingDelay() : Seconds(0);
</ins><span class="cx">
</span><del>- if (throttlingDelay == 0ms) {
</del><ins>+ if (throttlingDelay == Seconds(0)) {
</ins><span class="cx"> m_delayedScrollEventTimer.stop();
</span><span class="cx"> sendScrollEvent();
</span><span class="cx"> } else if (!m_delayedScrollEventTimer.isActive())
</span><del>- m_delayedScrollEventTimer.startOneShot(throttlingDelay);
</del><ins>+ m_delayedScrollEventTimer.startOneShot(throttlingDelay.value());
</ins><span class="cx">
</span><span class="cx"> if (Document* document = frame().document())
</span><span class="cx"> document->sendWillRevealEdgeEventsIfNeeded(oldPosition, newPosition, visibleContentRect(), contentsSize());
</span><span class="lines">@@ -4985,7 +4985,7 @@
</span><span class="cx"> sendResizeEventIfNeeded();
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void FrameView::setScrollVelocity(double horizontalVelocity, double verticalVelocity, double scaleChangeRate, double timestamp)
</del><ins>+void FrameView::setScrollVelocity(double horizontalVelocity, double verticalVelocity, double scaleChangeRate, MonotonicTime timestamp)
</ins><span class="cx"> {
</span><span class="cx"> if (TiledBacking* tiledBacking = this->tiledBacking())
</span><span class="cx"> tiledBacking->setVelocity(VelocityData(horizontalVelocity, verticalVelocity, scaleChangeRate, timestamp));
</span></span></pre></div>
<a id="trunkSourceWebCorepageFrameViewh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/page/FrameView.h (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/page/FrameView.h        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebCore/page/FrameView.h        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -143,7 +143,7 @@
</span><span class="cx"> IntSize customSizeForResizeEvent() const { return m_customSizeForResizeEvent; }
</span><span class="cx"> WEBCORE_EXPORT void setCustomSizeForResizeEvent(IntSize);
</span><span class="cx">
</span><del>- WEBCORE_EXPORT void setScrollVelocity(double horizontalVelocity, double verticalVelocity, double scaleChangeRate, double timestamp);
</del><ins>+ WEBCORE_EXPORT void setScrollVelocity(double horizontalVelocity, double verticalVelocity, double scaleChangeRate, MonotonicTime timestamp);
</ins><span class="cx"> #else
</span><span class="cx"> bool useCustomFixedPositionLayoutRect() const { return false; }
</span><span class="cx"> #endif
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformTimerh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/Timer.h (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/Timer.h        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebCore/platform/Timer.h        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -30,6 +30,7 @@
</span><span class="cx"> #include <functional>
</span><span class="cx"> #include <wtf/Noncopyable.h>
</span><span class="cx"> #include <wtf/Optional.h>
</span><ins>+#include <wtf/Seconds.h>
</ins><span class="cx"> #include <wtf/Threading.h>
</span><span class="cx"> #include <wtf/Vector.h>
</span><span class="cx">
</span><span class="lines">@@ -58,8 +59,11 @@
</span><span class="cx">
</span><span class="cx"> void startRepeating(double repeatInterval) { start(repeatInterval, repeatInterval); }
</span><span class="cx"> void startRepeating(std::chrono::milliseconds repeatInterval) { startRepeating(msToSeconds(repeatInterval)); }
</span><ins>+ void startRepeating(Seconds repeatInterval) { startRepeating(repeatInterval.value()); }
+
</ins><span class="cx"> void startOneShot(double interval) { start(interval, 0); }
</span><span class="cx"> void startOneShot(std::chrono::milliseconds interval) { startOneShot(msToSeconds(interval)); }
</span><ins>+ void startOneShot(Seconds interval) { start(interval.value(), 0); }
</ins><span class="cx">
</span><span class="cx"> WEBCORE_EXPORT void stop();
</span><span class="cx"> bool isActive() const;
</span><span class="lines">@@ -71,8 +75,11 @@
</span><span class="cx">
</span><span class="cx"> void augmentFireInterval(double delta) { setNextFireTime(m_nextFireTime + delta); }
</span><span class="cx"> void augmentFireInterval(std::chrono::milliseconds delta) { augmentFireInterval(msToSeconds(delta)); }
</span><ins>+ void augmentFireInterval(Seconds delta) { augmentFireInterval(delta.value()); }
+
</ins><span class="cx"> void augmentRepeatInterval(double delta) { augmentFireInterval(delta); m_repeatInterval += delta; }
</span><span class="cx"> void augmentRepeatInterval(std::chrono::milliseconds delta) { augmentRepeatInterval(msToSeconds(delta)); }
</span><ins>+ void augmentRepeatInterval(Seconds delta) { augmentRepeatInterval(delta.value()); }
</ins><span class="cx">
</span><span class="cx"> void didChangeAlignmentInterval();
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicsTiledBackingh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/TiledBacking.h (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/TiledBacking.h        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebCore/platform/graphics/TiledBacking.h        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -23,9 +23,9 @@
</span><span class="cx"> * THE POSSIBILITY OF SUCH DAMAGE.
</span><span class="cx"> */
</span><span class="cx">
</span><del>-#ifndef TiledBacking_h
-#define TiledBacking_h
</del><ins>+#pragma once
</ins><span class="cx">
</span><ins>+#include <wtf/MonotonicTime.h>
</ins><span class="cx"> #include <wtf/Optional.h>
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="lines">@@ -51,9 +51,9 @@
</span><span class="cx"> double horizontalVelocity;
</span><span class="cx"> double verticalVelocity;
</span><span class="cx"> double scaleChangeRate;
</span><del>- double lastUpdateTime;
</del><ins>+ MonotonicTime lastUpdateTime;
</ins><span class="cx">
</span><del>- VelocityData(double horizontal = 0, double vertical = 0, double scaleChange = 0, double updateTime = 0)
</del><ins>+ VelocityData(double horizontal = 0, double vertical = 0, double scaleChange = 0, MonotonicTime updateTime = MonotonicTime())
</ins><span class="cx"> : horizontalVelocity(horizontal)
</span><span class="cx"> , verticalVelocity(vertical)
</span><span class="cx"> , scaleChangeRate(scaleChange)
</span><span class="lines">@@ -156,5 +156,3 @@
</span><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span><del>-
-#endif // TiledBacking_h
</del></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicscaTileControllercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/ca/TileController.cpp (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/ca/TileController.cpp        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebCore/platform/graphics/ca/TileController.cpp        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -381,13 +381,13 @@
</span><span class="cx"> double horizontalMargin = kDefaultTileSize / contentsScale;
</span><span class="cx"> double verticalMargin = kDefaultTileSize / contentsScale;
</span><span class="cx">
</span><del>- double currentTime = monotonicallyIncreasingTime();
- double timeDelta = currentTime - m_velocity.lastUpdateTime;
</del><ins>+ MonotonicTime currentTime = MonotonicTime::now();
+ Seconds timeDelta = currentTime - m_velocity.lastUpdateTime;
</ins><span class="cx">
</span><span class="cx"> FloatRect futureRect = visibleRect;
</span><span class="cx"> futureRect.setLocation(FloatPoint(
</span><del>- futureRect.location().x() + timeDelta * m_velocity.horizontalVelocity,
- futureRect.location().y() + timeDelta * m_velocity.verticalVelocity));
</del><ins>+ futureRect.location().x() + timeDelta.value() * m_velocity.horizontalVelocity,
+ futureRect.location().y() + timeDelta.value() * m_velocity.verticalVelocity));
</ins><span class="cx">
</span><span class="cx"> if (m_velocity.horizontalVelocity) {
</span><span class="cx"> futureRect.setWidth(futureRect.width() + horizontalMargin);
</span></span></pre></div>
<a id="trunkSourceWebKit2ChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/ChangeLog (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/ChangeLog        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebKit2/ChangeLog        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -1,3 +1,46 @@
</span><ins>+2016-11-18 Simon Fraser <simon.fraser@apple.com>
+
+ Remove use of std::chrono in WebPage and entrained code
+ https://bugs.webkit.org/show_bug.cgi?id=164967
+
+ Reviewed by Tim Horton.
+
+ Replace std::chrono with Seconds and Monotonic Time.
+
+ Use more C++11 initialization for WebPage data members.
+
+ * Shared/VisibleContentRectUpdateInfo.cpp:
+ (WebKit::operator<<):
+ * Shared/VisibleContentRectUpdateInfo.h:
+ (WebKit::VisibleContentRectUpdateInfo::VisibleContentRectUpdateInfo):
+ (WebKit::VisibleContentRectUpdateInfo::timestamp):
+ * Shared/WebCoreArgumentCoders.cpp:
+ (IPC::ArgumentCoder<MonotonicTime>::encode):
+ (IPC::ArgumentCoder<MonotonicTime>::decode):
+ (IPC::ArgumentCoder<Seconds>::encode):
+ (IPC::ArgumentCoder<Seconds>::decode):
+ * Shared/WebCoreArgumentCoders.h:
+ * UIProcess/ios/WKContentView.mm:
+ (WebKit::HistoricalVelocityData::HistoricalVelocityData):
+ (WebKit::HistoricalVelocityData::velocityForNewData):
+ (WebKit::HistoricalVelocityData::append):
+ (-[WKContentView didUpdateVisibleRect:unobscuredRect:unobscuredRectInScrollViewCoordinates:obscuredInset:scale:minimumScale:inStableState:isChangingObscuredInsetsInteractively:enclosedInScrollableAncestorView:]):
+ * WebProcess/WebCoreSupport/WebChromeClient.h:
+ * WebProcess/WebCoreSupport/ios/WebChromeClientIOS.mm:
+ (WebKit::WebChromeClient::eventThrottlingDelay):
+ * WebProcess/WebPage/ViewUpdateDispatcher.h:
+ * WebProcess/WebPage/WebPage.cpp:
+ (WebKit::WebPage::WebPage):
+ (WebKit::m_userActivityHysteresis):
+ (WebKit::WebPage::didFlushLayerTreeAtTime):
+ (WebKit::WebPage::didCommitLoad):
+ * WebProcess/WebPage/WebPage.h:
+ * WebProcess/WebPage/ios/WebPageIOS.mm:
+ (WebKit::WebPage::eventThrottlingDelay):
+ (WebKit::WebPage::updateVisibleContentRects):
+ * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
+ (WebKit::RemoteLayerTreeDrawingArea::flushLayers):
+
</ins><span class="cx"> 2016-11-18 Dean Jackson <dino@apple.com>
</span><span class="cx">
</span><span class="cx"> AX: "(inverted-colors)" media query only matches on page reload; should match on change
</span></span></pre></div>
<a id="trunkSourceWebKit2SharedVisibleContentRectUpdateInfocpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/Shared/VisibleContentRectUpdateInfo.cpp (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/Shared/VisibleContentRectUpdateInfo.cpp        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebKit2/Shared/VisibleContentRectUpdateInfo.cpp        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -116,7 +116,7 @@
</span><span class="cx"> if (info.enclosedInScrollableAncestorView())
</span><span class="cx"> ts.dumpProperty("enclosedInScrollableAncestorView", info.enclosedInScrollableAncestorView());
</span><span class="cx">
</span><del>- ts.dumpProperty("timestamp", info.timestamp());
</del><ins>+ ts.dumpProperty("timestamp", info.timestamp().secondsSinceEpoch().value());
</ins><span class="cx"> if (info.horizontalVelocity())
</span><span class="cx"> ts.dumpProperty("horizontalVelocity", info.horizontalVelocity());
</span><span class="cx"> if (info.verticalVelocity())
</span></span></pre></div>
<a id="trunkSourceWebKit2SharedVisibleContentRectUpdateInfoh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/Shared/VisibleContentRectUpdateInfo.h (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/Shared/VisibleContentRectUpdateInfo.h        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebKit2/Shared/VisibleContentRectUpdateInfo.h        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -27,6 +27,7 @@
</span><span class="cx"> #define VisibleContentRectUpdateInfo_h
</span><span class="cx">
</span><span class="cx"> #include <WebCore/FloatRect.h>
</span><ins>+#include <wtf/MonotonicTime.h>
</ins><span class="cx"> #include <wtf/text/WTFString.h>
</span><span class="cx">
</span><span class="cx"> namespace IPC {
</span><span class="lines">@@ -47,7 +48,7 @@
</span><span class="cx"> VisibleContentRectUpdateInfo(const WebCore::FloatRect& exposedContentRect, const WebCore::FloatRect& unobscuredContentRect,
</span><span class="cx"> const WebCore::FloatRect& unobscuredRectInScrollViewCoordinates, const WebCore::FloatRect& customFixedPositionRect,
</span><span class="cx"> const WebCore::FloatSize& obscuredInset, double scale, bool inStableState, bool isChangingObscuredInsetsInteractively, bool allowShrinkToFit, bool enclosedInScrollableAncestorView,
</span><del>- double timestamp, double horizontalVelocity, double verticalVelocity, double scaleChangeRate, uint64_t lastLayerTreeTransactionId)
</del><ins>+ MonotonicTime timestamp, double horizontalVelocity, double verticalVelocity, double scaleChangeRate, uint64_t lastLayerTreeTransactionId)
</ins><span class="cx"> : m_exposedContentRect(exposedContentRect)
</span><span class="cx"> , m_unobscuredContentRect(unobscuredContentRect)
</span><span class="cx"> , m_unobscuredRectInScrollViewCoordinates(unobscuredRectInScrollViewCoordinates)
</span><span class="lines">@@ -78,7 +79,7 @@
</span><span class="cx"> bool allowShrinkToFit() const { return m_allowShrinkToFit; }
</span><span class="cx"> bool enclosedInScrollableAncestorView() const { return m_enclosedInScrollableAncestorView; }
</span><span class="cx">
</span><del>- double timestamp() const { return m_timestamp; }
</del><ins>+ MonotonicTime timestamp() const { return m_timestamp; }
</ins><span class="cx"> double horizontalVelocity() const { return m_horizontalVelocity; }
</span><span class="cx"> double verticalVelocity() const { return m_verticalVelocity; }
</span><span class="cx"> double scaleChangeRate() const { return m_scaleChangeRate; }
</span><span class="lines">@@ -98,7 +99,7 @@
</span><span class="cx"> WebCore::FloatSize m_obscuredInset;
</span><span class="cx"> uint64_t m_lastLayerTreeTransactionID { 0 };
</span><span class="cx"> double m_scale { -1 };
</span><del>- double m_timestamp { 0 };
</del><ins>+ MonotonicTime m_timestamp;
</ins><span class="cx"> double m_horizontalVelocity { 0 };
</span><span class="cx"> double m_verticalVelocity { 0 };
</span><span class="cx"> double m_scaleChangeRate { 0 };
</span></span></pre></div>
<a id="trunkSourceWebKit2SharedWebCoreArgumentCoderscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/Shared/WebCoreArgumentCoders.cpp (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/Shared/WebCoreArgumentCoders.cpp        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebKit2/Shared/WebCoreArgumentCoders.cpp        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -70,6 +70,8 @@
</span><span class="cx"> #include <WebCore/UserStyleSheet.h>
</span><span class="cx"> #include <WebCore/ViewportArguments.h>
</span><span class="cx"> #include <WebCore/WindowFeatures.h>
</span><ins>+#include <wtf/MonotonicTime.h>
+#include <wtf/Seconds.h>
</ins><span class="cx"> #include <wtf/text/CString.h>
</span><span class="cx"> #include <wtf/text/StringHash.h>
</span><span class="cx">
</span><span class="lines">@@ -104,6 +106,36 @@
</span><span class="cx">
</span><span class="cx"> namespace IPC {
</span><span class="cx">
</span><ins>+void ArgumentCoder<MonotonicTime>::encode(Encoder& encoder, const MonotonicTime& time)
+{
+ encoder << time.secondsSinceEpoch().value();
+}
+
+bool ArgumentCoder<MonotonicTime>::decode(Decoder& decoder, MonotonicTime& time)
+{
+ double value;
+ if (!decoder.decode(value))
+ return false;
+
+ time = MonotonicTime::fromRawSeconds(value);
+ return true;
+}
+
+void ArgumentCoder<Seconds>::encode(Encoder& encoder, const Seconds& seconds)
+{
+ encoder << seconds.value();
+}
+
+bool ArgumentCoder<Seconds>::decode(Decoder& decoder, Seconds& seconds)
+{
+ double value;
+ if (!decoder.decode(value))
+ return false;
+
+ seconds = Seconds(value);
+ return true;
+}
+
</ins><span class="cx"> void ArgumentCoder<AffineTransform>::encode(Encoder& encoder, const AffineTransform& affineTransform)
</span><span class="cx"> {
</span><span class="cx"> SimpleArgumentCoder<AffineTransform>::encode(encoder, affineTransform);
</span></span></pre></div>
<a id="trunkSourceWebKit2SharedWebCoreArgumentCodersh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/Shared/WebCoreArgumentCoders.h (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/Shared/WebCoreArgumentCoders.h        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebKit2/Shared/WebCoreArgumentCoders.h        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -31,6 +31,11 @@
</span><span class="cx"> #include <WebCore/IndexedDB.h>
</span><span class="cx"> #include <WebCore/PaymentHeaders.h>
</span><span class="cx">
</span><ins>+namespace WTF {
+class MonotonicTime;
+class Seconds;
+}
+
</ins><span class="cx"> namespace WebCore {
</span><span class="cx"> class AffineTransform;
</span><span class="cx"> class AuthenticationChallenge;
</span><span class="lines">@@ -147,6 +152,16 @@
</span><span class="cx">
</span><span class="cx"> namespace IPC {
</span><span class="cx">
</span><ins>+template<> struct ArgumentCoder<WTF::MonotonicTime> {
+ static void encode(Encoder&, const WTF::MonotonicTime&);
+ static bool decode(Decoder&, WTF::MonotonicTime&);
+};
+
+template<> struct ArgumentCoder<WTF::Seconds> {
+ static void encode(Encoder&, const WTF::Seconds&);
+ static bool decode(Decoder&, WTF::Seconds&);
+};
+
</ins><span class="cx"> template<> struct ArgumentCoder<WebCore::AffineTransform> {
</span><span class="cx"> static void encode(Encoder&, const WebCore::AffineTransform&);
</span><span class="cx"> static bool decode(Decoder&, WebCore::AffineTransform&);
</span></span></pre></div>
<a id="trunkSourceWebKit2UIProcessiosWKContentViewmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/UIProcess/ios/WKContentView.mm (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/ios/WKContentView.mm        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebKit2/UIProcess/ios/WKContentView.mm        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -92,15 +92,14 @@
</span><span class="cx"> HistoricalVelocityData()
</span><span class="cx"> : m_historySize(0)
</span><span class="cx"> , m_latestDataIndex(0)
</span><del>- , m_lastAppendTimestamp(0)
</del><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx">
</span><del>- VelocityData velocityForNewData(CGPoint newPosition, double scale, double timestamp)
</del><ins>+ VelocityData velocityForNewData(CGPoint newPosition, double scale, MonotonicTime timestamp)
</ins><span class="cx"> {
</span><span class="cx"> // Due to all the source of rect update, the input is very noisy. To smooth the output, we accumulate all changes
</span><span class="cx"> // within 1 frame as a single update. No speed computation is ever done on data within the same frame.
</span><del>- const double filteringThreshold = 1 / 60.;
</del><ins>+ const Seconds filteringThreshold(1.0 / 60);
</ins><span class="cx">
</span><span class="cx"> VelocityData velocityData;
</span><span class="cx"> if (m_historySize > 0) {
</span><span class="lines">@@ -111,14 +110,14 @@
</span><span class="cx"> else
</span><span class="cx"> oldestDataIndex = m_historySize - (distanceToLastHistoricalData - m_latestDataIndex);
</span><span class="cx">
</span><del>- double timeDelta = timestamp - m_history[oldestDataIndex].timestamp;
</del><ins>+ Seconds timeDelta = timestamp - m_history[oldestDataIndex].timestamp;
</ins><span class="cx"> if (timeDelta > filteringThreshold) {
</span><span class="cx"> Data& oldestData = m_history[oldestDataIndex];
</span><del>- velocityData = VelocityData((newPosition.x - oldestData.position.x) / timeDelta, (newPosition.y - oldestData.position.y) / timeDelta, (scale - oldestData.scale) / timeDelta);
</del><ins>+ velocityData = VelocityData((newPosition.x - oldestData.position.x) / timeDelta.seconds(), (newPosition.y - oldestData.position.y) / timeDelta.seconds(), (scale - oldestData.scale) / timeDelta.seconds());
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span><del>- double timeSinceLastAppend = timestamp - m_lastAppendTimestamp;
</del><ins>+ Seconds timeSinceLastAppend = timestamp - m_lastAppendTimestamp;
</ins><span class="cx"> if (timeSinceLastAppend > filteringThreshold)
</span><span class="cx"> append(newPosition, scale, timestamp);
</span><span class="cx"> else
</span><span class="lines">@@ -129,7 +128,7 @@
</span><span class="cx"> void clear() { m_historySize = 0; }
</span><span class="cx">
</span><span class="cx"> private:
</span><del>- void append(CGPoint newPosition, double scale, double timestamp)
</del><ins>+ void append(CGPoint newPosition, double scale, MonotonicTime timestamp)
</ins><span class="cx"> {
</span><span class="cx"> m_latestDataIndex = (m_latestDataIndex + 1) % maxHistoryDepth;
</span><span class="cx"> m_history[m_latestDataIndex] = { timestamp, newPosition, scale };
</span><span class="lines">@@ -146,10 +145,10 @@
</span><span class="cx">
</span><span class="cx"> unsigned m_historySize;
</span><span class="cx"> unsigned m_latestDataIndex;
</span><del>- double m_lastAppendTimestamp;
</del><ins>+ MonotonicTime m_lastAppendTimestamp;
</ins><span class="cx">
</span><span class="cx"> struct Data {
</span><del>- double timestamp;
</del><ins>+ MonotonicTime timestamp;
</ins><span class="cx"> CGPoint position;
</span><span class="cx"> double scale;
</span><span class="cx"> } m_history[maxHistoryDepth];
</span><span class="lines">@@ -370,7 +369,7 @@
</span><span class="cx"> if (!drawingArea)
</span><span class="cx"> return;
</span><span class="cx">
</span><del>- double timestamp = monotonicallyIncreasingTime();
</del><ins>+ MonotonicTime timestamp = MonotonicTime::now();
</ins><span class="cx"> HistoricalVelocityData::VelocityData velocityData;
</span><span class="cx"> if (!isStableState)
</span><span class="cx"> velocityData = _historicalKinematicData.velocityForNewData(visibleRect.origin, zoomScale, timestamp);
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebCoreSupportWebChromeClienth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.h (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.h        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.h        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -174,7 +174,7 @@
</span><span class="cx"> void webAppOrientationsUpdated() override;
</span><span class="cx"> void showPlaybackTargetPicker(bool hasVideo) override;
</span><span class="cx">
</span><del>- std::chrono::milliseconds eventThrottlingDelay() override;
</del><ins>+ Seconds eventThrottlingDelay() override;
</ins><span class="cx"> #endif
</span><span class="cx">
</span><span class="cx"> #if ENABLE(ORIENTATION_EVENTS)
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebCoreSupportiosWebChromeClientIOSmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/ios/WebChromeClientIOS.mm (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/ios/WebChromeClientIOS.mm        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/ios/WebChromeClientIOS.mm        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -131,7 +131,7 @@
</span><span class="cx"> m_page->send(Messages::WebPageProxy::ShowPlaybackTargetPicker(hasVideo, m_page->rectForElementAtInteractionLocation()));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-std::chrono::milliseconds WebChromeClient::eventThrottlingDelay()
</del><ins>+Seconds WebChromeClient::eventThrottlingDelay()
</ins><span class="cx"> {
</span><span class="cx"> return m_page->eventThrottlingDelay();
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebPageViewUpdateDispatcherh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebPage/ViewUpdateDispatcher.h (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebPage/ViewUpdateDispatcher.h        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebKit2/WebProcess/WebPage/ViewUpdateDispatcher.h        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -53,7 +53,7 @@
</span><span class="cx">
</span><span class="cx"> struct UpdateData {
</span><span class="cx"> VisibleContentRectUpdateInfo visibleContentRectUpdateInfo;
</span><del>- double oldestTimestamp;
</del><ins>+ MonotonicTime oldestTimestamp;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> Ref<WorkQueue> m_queue;
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebPageWebPagecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -291,27 +291,11 @@
</span><span class="cx"> WebPage::WebPage(uint64_t pageID, const WebPageCreationParameters& parameters)
</span><span class="cx"> : m_pageID(pageID)
</span><span class="cx"> , m_viewSize(parameters.viewSize)
</span><del>- , m_hasSeenPlugin(false)
- , m_useFixedLayout(false)
- , m_drawsBackground(true)
- , m_isInRedo(false)
- , m_isClosed(false)
- , m_tabToLinks(false)
- , m_asynchronousPluginInitializationEnabled(false)
- , m_asynchronousPluginInitializationEnabledForAllPlugins(false)
- , m_artificialPluginInitializationDelayEnabled(false)
- , m_scrollingPerformanceLoggingEnabled(false)
- , m_mainFrameIsScrollable(true)
</del><span class="cx"> #if ENABLE(PRIMARY_SNAPSHOTTED_PLUGIN_HEURISTIC)
</span><del>- , m_readyToFindPrimarySnapshottedPlugin(false)
- , m_didFindPrimarySnapshottedPlugin(false)
- , m_numberOfPrimarySnapshotDetectionAttempts(0)
</del><span class="cx"> , m_determinePrimarySnapshottedPlugInTimer(RunLoop::main(), this, &WebPage::determinePrimarySnapshottedPlugInTimerFired)
</span><span class="cx"> #endif
</span><span class="cx"> , m_layerHostingMode(parameters.layerHostingMode)
</span><span class="cx"> #if PLATFORM(COCOA)
</span><del>- , m_pdfPluginEnabled(false)
- , m_hasCachedWindowFrame(false)
</del><span class="cx"> , m_viewGestureGeometryCollector(*this)
</span><span class="cx"> #elif HAVE(ACCESSIBILITY) && (PLATFORM(GTK) || PLATFORM(EFL))
</span><span class="cx"> , m_accessibilityObject(nullptr)
</span><span class="lines">@@ -323,9 +307,6 @@
</span><span class="cx"> , m_formClient(std::make_unique<API::InjectedBundle::FormClient>())
</span><span class="cx"> , m_uiClient(std::make_unique<API::InjectedBundle::PageUIClient>())
</span><span class="cx"> , m_findController(this)
</span><del>-#if ENABLE(INPUT_TYPE_COLOR)
- , m_activeColorChooser(0)
-#endif
</del><span class="cx"> , m_userContentController(WebUserContentController::getOrCreate(parameters.userContentControllerID))
</span><span class="cx"> #if ENABLE(GEOLOCATION)
</span><span class="cx"> , m_geolocationPermissionRequestManager(this)
</span><span class="lines">@@ -336,53 +317,15 @@
</span><span class="cx"> , m_pageScrolledHysteresis([this](HysteresisState state) { if (state == HysteresisState::Stopped) pageStoppedScrolling(); }, pageScrollHysteresisSeconds)
</span><span class="cx"> , m_canRunBeforeUnloadConfirmPanel(parameters.canRunBeforeUnloadConfirmPanel)
</span><span class="cx"> , m_canRunModal(parameters.canRunModal)
</span><del>- , m_isRunningModal(false)
-#if ENABLE(DRAG_SUPPORT)
- , m_isStartingDrag(false)
-#endif
- , m_cachedMainFrameIsPinnedToLeftSide(true)
- , m_cachedMainFrameIsPinnedToRightSide(true)
- , m_cachedMainFrameIsPinnedToTopSide(true)
- , m_cachedMainFrameIsPinnedToBottomSide(true)
- , m_canShortCircuitHorizontalWheelEvents(false)
- , m_hasWheelEventHandlers(false)
- , m_cachedPageCount(0)
- , m_autoSizingShouldExpandToViewHeight(false)
- , m_userIsInteracting(false)
-#if ENABLE(CONTEXT_MENUS)
- , m_isShowingContextMenu(false)
-#endif
- , m_hasPendingBlurNotification(false)
</del><span class="cx"> #if PLATFORM(IOS)
</span><del>- , m_selectionAnchor(Start)
- , m_hasReceivedVisibleContentRectsAfterDidCommitLoad(false)
- , m_scaleWasSetByUIProcess(false)
- , m_userHasChangedPageScaleFactor(false)
- , m_hasStablePageScaleFactor(true)
- , m_useTestingViewportConfiguration(false)
- , m_isInStableState(true)
</del><span class="cx"> , m_forceAlwaysUserScalable(parameters.ignoresViewportScaleLimits)
</span><del>- , m_oldestNonStableUpdateVisibleContentRectsTimestamp(std::chrono::milliseconds::zero())
- , m_estimatedLatency(std::chrono::milliseconds::zero())
</del><span class="cx"> , m_screenSize(parameters.screenSize)
</span><span class="cx"> , m_availableScreenSize(parameters.availableScreenSize)
</span><del>- , m_deviceOrientation(0)
- , m_inDynamicSizeUpdate(false)
</del><span class="cx"> #endif
</span><span class="cx"> , m_layerVolatilityTimer(*this, &WebPage::layerVolatilityTimerFired)
</span><del>- , m_backgroundColor(Color::white)
- , m_maximumRenderingSuppressionToken(0)
- , m_scrollPinningBehavior(DoNotPin)
- , m_useAsyncScrolling(false)
</del><span class="cx"> , m_activityState(parameters.activityState)
</span><span class="cx"> , m_userActivity("Process suppression disabled for page.")
</span><span class="cx"> , m_userActivityHysteresis([this](HysteresisState) { updateUserActivity(); })
</span><del>- , m_pendingNavigationID(0)
-#if ENABLE(WEBGL)
- , m_systemWebGLPolicy(WebGLAllowCreation)
-#endif
- , m_mainFrameProgressCompleted(false)
- , m_shouldDispatchFakeMouseMoveEvents(true)
</del><span class="cx"> , m_userInterfaceLayoutDirection(parameters.userInterfaceLayoutDirection)
</span><span class="cx"> {
</span><span class="cx"> ASSERT(m_pageID);
</span><span class="lines">@@ -3299,14 +3242,14 @@
</span><span class="cx"> #endif
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void WebPage::didFlushLayerTreeAtTime(std::chrono::milliseconds timestamp)
</del><ins>+void WebPage::didFlushLayerTreeAtTime(MonotonicTime timestamp)
</ins><span class="cx"> {
</span><span class="cx"> #if PLATFORM(IOS)
</span><del>- if (m_oldestNonStableUpdateVisibleContentRectsTimestamp != std::chrono::milliseconds::zero()) {
- std::chrono::milliseconds elapsed = timestamp - m_oldestNonStableUpdateVisibleContentRectsTimestamp;
- m_oldestNonStableUpdateVisibleContentRectsTimestamp = std::chrono::milliseconds::zero();
</del><ins>+ if (m_oldestNonStableUpdateVisibleContentRectsTimestamp != MonotonicTime()) {
+ Seconds elapsed = timestamp - m_oldestNonStableUpdateVisibleContentRectsTimestamp;
+ m_oldestNonStableUpdateVisibleContentRectsTimestamp = MonotonicTime();
</ins><span class="cx">
</span><del>- m_estimatedLatency = std::chrono::milliseconds(static_cast<std::chrono::milliseconds::rep>(m_estimatedLatency.count() * 0.80 + elapsed.count() * 0.20));
</del><ins>+ m_estimatedLatency = m_estimatedLatency * 0.80 + elapsed * 0.20;
</ins><span class="cx"> }
</span><span class="cx"> #else
</span><span class="cx"> UNUSED_PARAM(timestamp);
</span><span class="lines">@@ -5171,7 +5114,7 @@
</span><span class="cx"> m_hasReceivedVisibleContentRectsAfterDidCommitLoad = false;
</span><span class="cx"> m_scaleWasSetByUIProcess = false;
</span><span class="cx"> m_userHasChangedPageScaleFactor = false;
</span><del>- m_estimatedLatency = std::chrono::milliseconds(1000 / 60);
</del><ins>+ m_estimatedLatency = Seconds(1.0 / 60);
</ins><span class="cx">
</span><span class="cx"> #if ENABLE(IOS_TOUCH_EVENTS)
</span><span class="cx"> WebProcess::singleton().eventDispatcher().clearQueuedTouchEventsForPage(*this);
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebPageWebPageh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -73,9 +73,11 @@
</span><span class="cx"> #include <WebCore/WebCoreKeyboardUIMode.h>
</span><span class="cx"> #include <memory>
</span><span class="cx"> #include <wtf/HashMap.h>
</span><ins>+#include <wtf/MonotonicTime.h>
</ins><span class="cx"> #include <wtf/PassRefPtr.h>
</span><span class="cx"> #include <wtf/RefPtr.h>
</span><span class="cx"> #include <wtf/RunLoop.h>
</span><ins>+#include <wtf/Seconds.h>
</ins><span class="cx"> #include <wtf/text/WTFString.h>
</span><span class="cx">
</span><span class="cx"> #if HAVE(ACCESSIBILITY) && (PLATFORM(GTK) || PLATFORM(EFL))
</span><span class="lines">@@ -247,7 +249,7 @@
</span><span class="cx">
</span><span class="cx"> #if PLATFORM(COCOA)
</span><span class="cx"> void willCommitLayerTree(RemoteLayerTreeTransaction&);
</span><del>- void didFlushLayerTreeAtTime(std::chrono::milliseconds);
</del><ins>+ void didFlushLayerTreeAtTime(MonotonicTime);
</ins><span class="cx"> #endif
</span><span class="cx">
</span><span class="cx"> enum class LazyCreationPolicy { UseExistingOnly, CreateIfNeeded };
</span><span class="lines">@@ -579,7 +581,7 @@
</span><span class="cx"> void contentSizeCategoryDidChange(const String&);
</span><span class="cx"> void executeEditCommandWithCallback(const String&, uint64_t callbackID);
</span><span class="cx">
</span><del>- std::chrono::milliseconds eventThrottlingDelay() const;
</del><ins>+ Seconds eventThrottlingDelay() const;
</ins><span class="cx">
</span><span class="cx"> void showInspectorHighlight(const WebCore::Highlight&);
</span><span class="cx"> void hideInspectorHighlight();
</span><span class="lines">@@ -827,7 +829,7 @@
</span><span class="cx"> void setDeviceOrientation(int32_t);
</span><span class="cx"> void dynamicViewportSizeUpdate(const WebCore::FloatSize& minimumLayoutSize, const WebCore::FloatSize& maximumUnobscuredSize, const WebCore::FloatRect& targetExposedContentRect, const WebCore::FloatRect& targetUnobscuredRect, const WebCore::FloatRect& targetUnobscuredRectInScrollViewCoordinates, double scale, int32_t deviceOrientation, uint64_t dynamicViewportSizeUpdateID);
</span><span class="cx"> void synchronizeDynamicViewportUpdate(double& newTargetScale, WebCore::FloatPoint& newScrollPosition, uint64_t& nextValidLayerTreeTransactionID);
</span><del>- void updateVisibleContentRects(const VisibleContentRectUpdateInfo&, double oldestTimestamp);
</del><ins>+ void updateVisibleContentRects(const VisibleContentRectUpdateInfo&, MonotonicTime oldestTimestamp);
</ins><span class="cx"> bool scaleWasSetByUIProcess() const { return m_scaleWasSetByUIProcess; }
</span><span class="cx"> void willStartUserTriggeredZooming();
</span><span class="cx"> void applicationWillResignActive();
</span><span class="lines">@@ -1256,37 +1258,33 @@
</span><span class="cx"> std::unique_ptr<DrawingArea> m_drawingArea;
</span><span class="cx">
</span><span class="cx"> HashSet<PluginView*> m_pluginViews;
</span><del>- bool m_hasSeenPlugin;
</del><ins>+ bool m_hasSeenPlugin { false };
</ins><span class="cx">
</span><span class="cx"> HashMap<uint64_t, RefPtr<WebCore::TextCheckingRequest>> m_pendingTextCheckingRequestMap;
</span><span class="cx">
</span><del>- bool m_useFixedLayout;
</del><ins>+ bool m_useFixedLayout { false };
+ bool m_drawsBackground { true };
</ins><span class="cx">
</span><del>- bool m_drawsBackground;
-
</del><span class="cx"> WebCore::Color m_underlayColor;
</span><span class="cx">
</span><del>- bool m_isInRedo;
- bool m_isClosed;
-
- bool m_tabToLinks;
</del><ins>+ bool m_isInRedo { false };
+ bool m_isClosed { false };
+ bool m_tabToLinks { false };
</ins><span class="cx">
</span><del>- bool m_asynchronousPluginInitializationEnabled;
- bool m_asynchronousPluginInitializationEnabledForAllPlugins;
- bool m_artificialPluginInitializationDelayEnabled;
</del><ins>+ bool m_asynchronousPluginInitializationEnabled { false };
+ bool m_asynchronousPluginInitializationEnabledForAllPlugins { false };
+ bool m_artificialPluginInitializationDelayEnabled { false };
+ bool m_scrollingPerformanceLoggingEnabled { false };
+ bool m_mainFrameIsScrollable { true };
</ins><span class="cx">
</span><del>- bool m_scrollingPerformanceLoggingEnabled;
-
- bool m_mainFrameIsScrollable;
-
</del><span class="cx"> #if PLATFORM(IOS)
</span><span class="cx"> bool m_ignoreViewportScalingConstraints { false };
</span><span class="cx"> #endif
</span><span class="cx">
</span><span class="cx"> #if ENABLE(PRIMARY_SNAPSHOTTED_PLUGIN_HEURISTIC)
</span><del>- bool m_readyToFindPrimarySnapshottedPlugin;
- bool m_didFindPrimarySnapshottedPlugin;
- unsigned m_numberOfPrimarySnapshotDetectionAttempts;
</del><ins>+ bool m_readyToFindPrimarySnapshottedPlugin { false };
+ bool m_didFindPrimarySnapshottedPlugin { false };
+ unsigned m_numberOfPrimarySnapshotDetectionAttempts { 0 };
</ins><span class="cx"> String m_primaryPlugInPageOrigin;
</span><span class="cx"> String m_primaryPlugInOrigin;
</span><span class="cx"> String m_primaryPlugInMimeType;
</span><span class="lines">@@ -1297,10 +1295,9 @@
</span><span class="cx"> LayerHostingMode m_layerHostingMode;
</span><span class="cx">
</span><span class="cx"> #if PLATFORM(COCOA)
</span><del>- bool m_pdfPluginEnabled;
</del><ins>+ bool m_pdfPluginEnabled { false };
+ bool m_hasCachedWindowFrame { false };
</ins><span class="cx">
</span><del>- bool m_hasCachedWindowFrame;
-
</del><span class="cx"> // The frame of the containing window in screen coordinates.
</span><span class="cx"> WebCore::FloatRect m_windowFrameInScreenCoordinates;
</span><span class="cx">
</span><span class="lines">@@ -1325,7 +1322,7 @@
</span><span class="cx">
</span><span class="cx"> #if PLATFORM(GTK) && USE(TEXTURE_MAPPER_GL)
</span><span class="cx"> // Our view's window in the UI process.
</span><del>- uint64_t m_nativeWindowHandle;
</del><ins>+ uint64_t m_nativeWindowHandle { 0 };
</ins><span class="cx"> #endif
</span><span class="cx">
</span><span class="cx"> #if !PLATFORM(IOS)
</span><span class="lines">@@ -1334,7 +1331,7 @@
</span><span class="cx"> #endif // !PLATFORM(IOS)
</span><span class="cx">
</span><span class="cx"> RunLoop::Timer<WebPage> m_setCanStartMediaTimer;
</span><del>- bool m_mayStartMediaWhenInWindow;
</del><ins>+ bool m_mayStartMediaWhenInWindow { false };
</ins><span class="cx">
</span><span class="cx"> HashMap<uint64_t, RefPtr<WebUndoStep>> m_undoStepMap;
</span><span class="cx">
</span><span class="lines">@@ -1373,7 +1370,7 @@
</span><span class="cx"> RefPtr<WebContextMenu> m_contextMenu;
</span><span class="cx"> #endif
</span><span class="cx"> #if ENABLE(INPUT_TYPE_COLOR)
</span><del>- WebColorChooser* m_activeColorChooser;
</del><ins>+ WebColorChooser* m_activeColorChooser { nullptr };
</ins><span class="cx"> #endif
</span><span class="cx"> RefPtr<WebOpenPanelResultListener> m_activeOpenPanelResultListener;
</span><span class="cx"> RefPtr<NotificationPermissionRequestManager> m_notificationPermissionRequestManager;
</span><span class="lines">@@ -1400,30 +1397,30 @@
</span><span class="cx">
</span><span class="cx"> WebCore::HysteresisActivity m_pageScrolledHysteresis;
</span><span class="cx">
</span><del>- bool m_canRunBeforeUnloadConfirmPanel;
</del><ins>+ bool m_canRunBeforeUnloadConfirmPanel { false };
</ins><span class="cx">
</span><del>- bool m_canRunModal;
- bool m_isRunningModal;
</del><ins>+ bool m_canRunModal { false };
+ bool m_isRunningModal { false };
</ins><span class="cx">
</span><span class="cx"> #if ENABLE(DRAG_SUPPORT)
</span><del>- bool m_isStartingDrag;
</del><ins>+ bool m_isStartingDrag { false };
</ins><span class="cx"> #endif
</span><span class="cx">
</span><del>- bool m_cachedMainFrameIsPinnedToLeftSide;
- bool m_cachedMainFrameIsPinnedToRightSide;
- bool m_cachedMainFrameIsPinnedToTopSide;
- bool m_cachedMainFrameIsPinnedToBottomSide;
- bool m_canShortCircuitHorizontalWheelEvents;
- bool m_hasWheelEventHandlers;
</del><ins>+ bool m_cachedMainFrameIsPinnedToLeftSide { true };
+ bool m_cachedMainFrameIsPinnedToRightSide { true };
+ bool m_cachedMainFrameIsPinnedToTopSide { true };
+ bool m_cachedMainFrameIsPinnedToBottomSide { true };
+ bool m_canShortCircuitHorizontalWheelEvents { false };
+ bool m_hasWheelEventHandlers { false };
</ins><span class="cx">
</span><del>- unsigned m_cachedPageCount;
</del><ins>+ unsigned m_cachedPageCount { 0 };
</ins><span class="cx">
</span><span class="cx"> HashSet<unsigned long> m_trackedNetworkResourceRequestIdentifiers;
</span><span class="cx">
</span><span class="cx"> WebCore::IntSize m_minimumLayoutSize;
</span><del>- bool m_autoSizingShouldExpandToViewHeight;
</del><ins>+ bool m_autoSizingShouldExpandToViewHeight { false };
</ins><span class="cx">
</span><del>- bool m_userIsInteracting;
</del><ins>+ bool m_userIsInteracting { false };
</ins><span class="cx"> bool m_isAssistingNodeDueToUserInteraction { false };
</span><span class="cx"> bool m_hasEverFocusedElementDueToUserInteractionSincePageTransition { false };
</span><span class="cx"> bool m_needsHiddenContentEditableQuirk { false };
</span><span class="lines">@@ -1430,11 +1427,11 @@
</span><span class="cx"> bool m_needsPlainTextQuirk { false };
</span><span class="cx">
</span><span class="cx"> #if ENABLE(CONTEXT_MENUS)
</span><del>- bool m_isShowingContextMenu;
</del><ins>+ bool m_isShowingContextMenu { false };
</ins><span class="cx"> #endif
</span><span class="cx">
</span><span class="cx"> RefPtr<WebCore::Node> m_assistedNode;
</span><del>- bool m_hasPendingBlurNotification;
</del><ins>+ bool m_hasPendingBlurNotification { false };
</ins><span class="cx">
</span><span class="cx"> #if PLATFORM(IOS)
</span><span class="cx"> RefPtr<WebCore::Range> m_currentWordRange;
</span><span class="lines">@@ -1445,21 +1442,21 @@
</span><span class="cx"> Start,
</span><span class="cx"> End
</span><span class="cx"> };
</span><del>- SelectionAnchor m_selectionAnchor;
</del><ins>+ SelectionAnchor m_selectionAnchor { Start };
</ins><span class="cx">
</span><span class="cx"> RefPtr<WebCore::Node> m_potentialTapNode;
</span><span class="cx"> WebCore::FloatPoint m_potentialTapLocation;
</span><span class="cx">
</span><span class="cx"> WebCore::ViewportConfiguration m_viewportConfiguration;
</span><del>- bool m_hasReceivedVisibleContentRectsAfterDidCommitLoad;
- bool m_scaleWasSetByUIProcess;
- bool m_userHasChangedPageScaleFactor;
- bool m_hasStablePageScaleFactor;
- bool m_useTestingViewportConfiguration;
- bool m_isInStableState;
- bool m_forceAlwaysUserScalable;
- std::chrono::milliseconds m_oldestNonStableUpdateVisibleContentRectsTimestamp;
- std::chrono::milliseconds m_estimatedLatency;
</del><ins>+ bool m_hasReceivedVisibleContentRectsAfterDidCommitLoad { false };
+ bool m_scaleWasSetByUIProcess { false };
+ bool m_userHasChangedPageScaleFactor { false };
+ bool m_hasStablePageScaleFactor { true };
+ bool m_useTestingViewportConfiguration { false };
+ bool m_isInStableState { true };
+ bool m_forceAlwaysUserScalable { false };
+ MonotonicTime m_oldestNonStableUpdateVisibleContentRectsTimestamp;
+ Seconds m_estimatedLatency { 0 };
</ins><span class="cx"> WebCore::FloatSize m_screenSize;
</span><span class="cx"> WebCore::FloatSize m_availableScreenSize;
</span><span class="cx"> RefPtr<WebCore::Range> m_currentBlockSelection;
</span><span class="lines">@@ -1468,8 +1465,8 @@
</span><span class="cx"> RefPtr<WebCore::Range> m_initialSelection;
</span><span class="cx"> WebCore::IntSize m_blockSelectionDesiredSize;
</span><span class="cx"> WebCore::FloatSize m_maximumUnobscuredSize;
</span><del>- int32_t m_deviceOrientation;
- bool m_inDynamicSizeUpdate;
</del><ins>+ int32_t m_deviceOrientation { 0 };
+ bool m_inDynamicSizeUpdate { false };
</ins><span class="cx"> HashMap<std::pair<WebCore::IntSize, double>, WebCore::IntPoint> m_dynamicSizeUpdateHistory;
</span><span class="cx"> RefPtr<WebCore::Node> m_pendingSyntheticClickNode;
</span><span class="cx"> WebCore::FloatPoint m_pendingSyntheticClickLocation;
</span><span class="lines">@@ -1481,15 +1478,15 @@
</span><span class="cx"> bool m_isSuspendedUnderLock { false };
</span><span class="cx">
</span><span class="cx"> HashSet<String, ASCIICaseInsensitiveHash> m_mimeTypesWithCustomContentProviders;
</span><del>- WebCore::Color m_backgroundColor;
</del><ins>+ WebCore::Color m_backgroundColor { WebCore::Color::white };
</ins><span class="cx">
</span><span class="cx"> HashSet<unsigned> m_activeRenderingSuppressionTokens;
</span><del>- unsigned m_maximumRenderingSuppressionToken;
</del><ins>+ unsigned m_maximumRenderingSuppressionToken { 0 };
</ins><span class="cx">
</span><del>- WebCore::ScrollPinningBehavior m_scrollPinningBehavior;
</del><ins>+ WebCore::ScrollPinningBehavior m_scrollPinningBehavior { WebCore::DoNotPin };
</ins><span class="cx"> WTF::Optional<WebCore::ScrollbarOverlayStyle> m_scrollbarOverlayStyle;
</span><span class="cx">
</span><del>- bool m_useAsyncScrolling;
</del><ins>+ bool m_useAsyncScrolling { false };
</ins><span class="cx">
</span><span class="cx"> WebCore::ActivityState::Flags m_activityState;
</span><span class="cx">
</span><span class="lines">@@ -1496,14 +1493,14 @@
</span><span class="cx"> UserActivity m_userActivity;
</span><span class="cx"> WebCore::HysteresisActivity m_userActivityHysteresis;
</span><span class="cx">
</span><del>- uint64_t m_pendingNavigationID;
</del><ins>+ uint64_t m_pendingNavigationID { 0 };
</ins><span class="cx">
</span><span class="cx"> #if ENABLE(WEBGL)
</span><del>- WebCore::WebGLLoadPolicy m_systemWebGLPolicy;
</del><ins>+ WebCore::WebGLLoadPolicy m_systemWebGLPolicy { WebCore::WebGLAllowCreation };
</ins><span class="cx"> #endif
</span><span class="cx">
</span><del>- bool m_mainFrameProgressCompleted;
- bool m_shouldDispatchFakeMouseMoveEvents;
</del><ins>+ bool m_mainFrameProgressCompleted { false };
+ bool m_shouldDispatchFakeMouseMoveEvents { true };
</ins><span class="cx"> bool m_isEditorStateMissingPostLayoutData { false };
</span><span class="cx"> bool m_isSelectingTextWhileInsertingAsynchronously { false };
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebPageiosWebPageIOSmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebPage/ios/WebPageIOS.mm (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebPage/ios/WebPageIOS.mm        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebKit2/WebProcess/WebPage/ios/WebPageIOS.mm        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -2122,12 +2122,12 @@
</span><span class="cx"> send(Messages::WebPageProxy::VoidCallback(callbackID));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-std::chrono::milliseconds WebPage::eventThrottlingDelay() const
</del><ins>+Seconds WebPage::eventThrottlingDelay() const
</ins><span class="cx"> {
</span><del>- if (m_isInStableState || m_estimatedLatency <= std::chrono::milliseconds(1000 / 60))
- return std::chrono::milliseconds::zero();
</del><ins>+ if (m_isInStableState || m_estimatedLatency <= Seconds(1.0 / 60))
+ return Seconds(0);
</ins><span class="cx">
</span><del>- return std::chrono::milliseconds(std::min<std::chrono::milliseconds::rep>(m_estimatedLatency.count() * 2, 1000));
</del><ins>+ return Seconds(std::min<double>(m_estimatedLatency.value() * 2, 1));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> void WebPage::syncApplyAutocorrection(const String& correction, const String& originalText, bool& correctionApplied)
</span><span class="lines">@@ -2832,7 +2832,7 @@
</span><span class="cx"> newExposedContentRect.moveBy(adjustmentDelta);
</span><span class="cx"> }
</span><span class="cx">
</span><del>- frameView.setScrollVelocity(0, 0, 0, monotonicallyIncreasingTime());
</del><ins>+ frameView.setScrollVelocity(0, 0, 0, MonotonicTime::now());
</ins><span class="cx">
</span><span class="cx"> IntPoint roundedUnobscuredContentRectPosition = roundedIntPoint(newUnobscuredContentRect.location());
</span><span class="cx"> frameView.setUnobscuredContentSize(newUnobscuredContentRect.size());
</span><span class="lines">@@ -2904,7 +2904,7 @@
</span><span class="cx"> minimumLayoutSizeInScrollViewCoordinates.scale(1 / scale);
</span><span class="cx"> IntSize minimumLayoutSizeInDocumentCoordinates = roundedIntSize(minimumLayoutSizeInScrollViewCoordinates);
</span><span class="cx"> frameView.setUnobscuredContentSize(minimumLayoutSizeInDocumentCoordinates);
</span><del>- frameView.setScrollVelocity(0, 0, 0, monotonicallyIncreasingTime());
</del><ins>+ frameView.setScrollVelocity(0, 0, 0, MonotonicTime::now());
</ins><span class="cx">
</span><span class="cx"> // FIXME: We could send down the obscured margins to find a better exposed rect and unobscured rect.
</span><span class="cx"> // It is not a big deal at the moment because the tile coverage will always extend past the obscured bottom inset.
</span><span class="lines">@@ -2982,7 +2982,7 @@
</span><span class="cx"> return adjustExposedRectForNewScale(exposedRect, exposedRectScale, newScale);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void WebPage::updateVisibleContentRects(const VisibleContentRectUpdateInfo& visibleContentRectUpdateInfo, double oldestTimestamp)
</del><ins>+void WebPage::updateVisibleContentRects(const VisibleContentRectUpdateInfo& visibleContentRectUpdateInfo, MonotonicTime oldestTimestamp)
</ins><span class="cx"> {
</span><span class="cx"> // Skip any VisibleContentRectUpdate that have been queued before DidCommitLoad suppresses the updates in the UIProcess.
</span><span class="cx"> if (visibleContentRectUpdateInfo.lastLayerTreeTransactionID() < m_mainFrame->firstLayerTreeTransactionIDAfterDidCommitLoad())
</span><span class="lines">@@ -3010,8 +3010,8 @@
</span><span class="cx"> if (m_isInStableState)
</span><span class="cx"> m_hasStablePageScaleFactor = true;
</span><span class="cx"> else {
</span><del>- if (m_oldestNonStableUpdateVisibleContentRectsTimestamp == std::chrono::milliseconds::zero())
- m_oldestNonStableUpdateVisibleContentRectsTimestamp = std::chrono::milliseconds(static_cast<std::chrono::milliseconds::rep>(oldestTimestamp * 1000));
</del><ins>+ if (!m_oldestNonStableUpdateVisibleContentRectsTimestamp)
+ m_oldestNonStableUpdateVisibleContentRectsTimestamp = oldestTimestamp;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> FloatRect exposedContentRect = visibleContentRectUpdateInfo.exposedContentRect();
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebPagemacRemoteLayerTreeDrawingAreamm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm (208915 => 208916)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm        2016-11-19 02:51:15 UTC (rev 208915)
+++ trunk/Source/WebKit2/WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm        2016-11-19 03:33:36 UTC (rev 208916)
</span><span class="lines">@@ -427,7 +427,7 @@
</span><span class="cx"> dispatch_async(m_commitQueue, [backingStoreFlusher, pageID] {
</span><span class="cx"> backingStoreFlusher->flush();
</span><span class="cx">
</span><del>- std::chrono::milliseconds timestamp = std::chrono::milliseconds(static_cast<std::chrono::milliseconds::rep>(monotonicallyIncreasingTime() * 1000));
</del><ins>+ MonotonicTime timestamp = MonotonicTime::now();
</ins><span class="cx"> dispatch_async(dispatch_get_main_queue(), [pageID, timestamp] {
</span><span class="cx"> if (WebPage* webPage = WebProcess::singleton().webPage(pageID))
</span><span class="cx"> webPage->didFlushLayerTreeAtTime(timestamp);
</span></span></pre>
</div>
</div>
</body>
</html>