<!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>[166851] 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/166851">166851</a></dd>
<dt>Author</dt> <dd>burg@cs.washington.edu</dd>
<dt>Date</dt> <dd>2014-04-06 10:28:20 -0700 (Sun, 06 Apr 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>Enable WEB_REPLAY for PLATFORM(MAC)
https://bugs.webkit.org/show_bug.cgi?id=130700

Reviewed by Timothy Hatcher.

Source/JavaScriptCore:

* Configurations/FeatureDefines.xcconfig:

Source/WebCore:

Switch on WEB_REPLAY feature flag for non-production builds.

* Configurations/FeatureDefines.xcconfig:
* replay/ReplayInputDispatchMethods.cpp: Fix the ENABLE(WEB_REPLAY) build.
It was broken by the bool to enum refactoring in <a href="http://trac.webkit.org/projects/webkit/changeset/166684">r166684</a>.
(WebCore::InitialNavigation::dispatch):

Source/WebInspectorUI:

If the ReplayAgent is available, then add an option to toggle between the
replay interface and normal Timeline interface from the timeline
sidebar panel. The option is available through a context menu item on the
sidebar panel's top navigation bar.

If web replay not available, just show the non-replay interface.

* Localizations/en.lproj/localizedStrings.js:
* UserInterface/Base/Main.js: Add WebInspector.showReplayInterfaceSetting.
(WebInspector.loaded):

* UserInterface/Views/TimelineSidebarPanel.js: Unconditionally create the replay
interface elements, but only show them if showReplayInterfaceSetting is enabled.
(WebInspector.TimelineSidebarPanel.prototype._updateReplayInterfaceVisibility): Added
(WebInspector.TimelineSidebarPanel.prototype._contextMenuNavigationBarOrStatusBar.toggleReplayInterface): Added.
(WebInspector.TimelineSidebarPanel.prototype._contextMenuNavigationBarOrStatusBar): Added.

Source/WebKit/mac:

* Configurations/FeatureDefines.xcconfig:

Source/WebKit2:

* Configurations/FeatureDefines.xcconfig:

Tools:

* Scripts/webkitperl/FeatureList.pm: Set the default for WEB_REPLAY for OS X engineering builds.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceJavaScriptCoreChangeLog">trunk/Source/JavaScriptCore/ChangeLog</a></li>
<li><a href="#trunkSourceJavaScriptCoreConfigurationsFeatureDefinesxcconfig">trunk/Source/JavaScriptCore/Configurations/FeatureDefines.xcconfig</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreConfigurationsFeatureDefinesxcconfig">trunk/Source/WebCore/Configurations/FeatureDefines.xcconfig</a></li>
<li><a href="#trunkSourceWebCorereplayReplayInputDispatchMethodscpp">trunk/Source/WebCore/replay/ReplayInputDispatchMethods.cpp</a></li>
<li><a href="#trunkSourceWebInspectorUIChangeLog">trunk/Source/WebInspectorUI/ChangeLog</a></li>
<li><a href="#trunkSourceWebInspectorUILocalizationsenlprojlocalizedStringsjs">trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js</a></li>
<li><a href="#trunkSourceWebInspectorUIUserInterfaceBaseMainjs">trunk/Source/WebInspectorUI/UserInterface/Base/Main.js</a></li>
<li><a href="#trunkSourceWebInspectorUIUserInterfaceViewsTimelineSidebarPaneljs">trunk/Source/WebInspectorUI/UserInterface/Views/TimelineSidebarPanel.js</a></li>
<li><a href="#trunkSourceWebKitmacChangeLog">trunk/Source/WebKit/mac/ChangeLog</a></li>
<li><a href="#trunkSourceWebKitmacConfigurationsFeatureDefinesxcconfig">trunk/Source/WebKit/mac/Configurations/FeatureDefines.xcconfig</a></li>
<li><a href="#trunkSourceWebKit2ChangeLog">trunk/Source/WebKit2/ChangeLog</a></li>
<li><a href="#trunkSourceWebKit2ConfigurationsFeatureDefinesxcconfig">trunk/Source/WebKit2/Configurations/FeatureDefines.xcconfig</a></li>
<li><a href="#trunkToolsChangeLog">trunk/Tools/ChangeLog</a></li>
<li><a href="#trunkToolsScriptswebkitperlFeatureListpm">trunk/Tools/Scripts/webkitperl/FeatureList.pm</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceJavaScriptCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/ChangeLog (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/ChangeLog        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Source/JavaScriptCore/ChangeLog        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -1,3 +1,12 @@
</span><ins>+2014-04-04  Brian J. Burg  &lt;burg@cs.washington.edu&gt;
+
+        Enable WEB_REPLAY for PLATFORM(MAC)
+        https://bugs.webkit.org/show_bug.cgi?id=130700
+
+        Reviewed by Timothy Hatcher.
+
+        * Configurations/FeatureDefines.xcconfig:
+
</ins><span class="cx"> 2014-04-05  Mark Hahnenberg  &lt;mhahnenberg@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Add missing files from r166837
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreConfigurationsFeatureDefinesxcconfig"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/Configurations/FeatureDefines.xcconfig (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/Configurations/FeatureDefines.xcconfig        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Source/JavaScriptCore/Configurations/FeatureDefines.xcconfig        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -208,7 +208,13 @@
</span><span class="cx"> ENABLE_VIEW_MODE_CSS_MEDIA = ;
</span><span class="cx"> ENABLE_WEBGL = ENABLE_WEBGL;
</span><span class="cx"> ENABLE_WEB_AUDIO = ENABLE_WEB_AUDIO;
</span><del>-ENABLE_WEB_REPLAY = ;
</del><ins>+ENABLE_WEB_REPLAY = $(ENABLE_WEB_REPLAY_$(PLATFORM_NAME));
+ENABLE_WEB_REPLAY_macosx = $(ENABLE_WEB_REPLAY_macosx_$(CONFIGURATION));
+ENABLE_WEB_REPLAY_macosx_Debug = ENABLE_WEB_REPLAY;
+ENABLE_WEB_REPLAY_macosx_Release = ENABLE_WEB_REPLAY;
+ENABLE_WEB_REPLAY_macosx_Production = ;
+ENABLE_WEB_REPLAY_iphoneos = ;
+ENABLE_WEB_REPLAY_iphonesimulator = ;
</ins><span class="cx"> ENABLE_WEB_SOCKETS = ENABLE_WEB_SOCKETS;
</span><span class="cx"> 
</span><span class="cx"> ENABLE_WEB_TIMING = $(ENABLE_WEB_TIMING_$(PLATFORM_NAME));
</span></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Source/WebCore/ChangeLog        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -1,3 +1,17 @@
</span><ins>+2014-04-04  Brian J. Burg  &lt;burg@cs.washington.edu&gt;
+
+        Enable WEB_REPLAY for PLATFORM(MAC)
+        https://bugs.webkit.org/show_bug.cgi?id=130700
+
+        Reviewed by Timothy Hatcher.
+
+        Switch on WEB_REPLAY feature flag for non-production builds.
+
+        * Configurations/FeatureDefines.xcconfig:
+        * replay/ReplayInputDispatchMethods.cpp: Fix the ENABLE(WEB_REPLAY) build.
+        It was broken by the bool to enum refactoring in r166684.
+        (WebCore::InitialNavigation::dispatch):
+
</ins><span class="cx"> 2014-04-05  Brian J. Burg  &lt;burg@cs.washington.edu&gt;
</span><span class="cx"> 
</span><span class="cx">         Web Inspector: remove unused test hook setInspectorResourcesDataSizeLimits
</span></span></pre></div>
<a id="trunkSourceWebCoreConfigurationsFeatureDefinesxcconfig"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Configurations/FeatureDefines.xcconfig (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Configurations/FeatureDefines.xcconfig        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Source/WebCore/Configurations/FeatureDefines.xcconfig        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -208,7 +208,13 @@
</span><span class="cx"> ENABLE_VIEW_MODE_CSS_MEDIA = ;
</span><span class="cx"> ENABLE_WEBGL = ENABLE_WEBGL;
</span><span class="cx"> ENABLE_WEB_AUDIO = ENABLE_WEB_AUDIO;
</span><del>-ENABLE_WEB_REPLAY = ;
</del><ins>+ENABLE_WEB_REPLAY = $(ENABLE_WEB_REPLAY_$(PLATFORM_NAME));
+ENABLE_WEB_REPLAY_macosx = $(ENABLE_WEB_REPLAY_macosx_$(CONFIGURATION));
+ENABLE_WEB_REPLAY_macosx_Debug = ENABLE_WEB_REPLAY;
+ENABLE_WEB_REPLAY_macosx_Release = ENABLE_WEB_REPLAY;
+ENABLE_WEB_REPLAY_macosx_Production = ;
+ENABLE_WEB_REPLAY_iphoneos = ;
+ENABLE_WEB_REPLAY_iphonesimulator = ;
</ins><span class="cx"> ENABLE_WEB_SOCKETS = ENABLE_WEB_SOCKETS;
</span><span class="cx"> 
</span><span class="cx"> ENABLE_WEB_TIMING = $(ENABLE_WEB_TIMING_$(PLATFORM_NAME));
</span></span></pre></div>
<a id="trunkSourceWebCorereplayReplayInputDispatchMethodscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/replay/ReplayInputDispatchMethods.cpp (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/replay/ReplayInputDispatchMethods.cpp        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Source/WebCore/replay/ReplayInputDispatchMethods.cpp        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -50,7 +50,7 @@
</span><span class="cx"> // Navigation inputs.
</span><span class="cx"> void InitialNavigation::dispatch(ReplayController&amp; controller)
</span><span class="cx"> {
</span><del>-    controller.page().mainFrame().navigationScheduler().scheduleLocationChange(m_securityOrigin.get(), m_url, m_referrer, true, true);
</del><ins>+    controller.page().mainFrame().navigationScheduler().scheduleLocationChange(m_securityOrigin.get(), m_url, m_referrer);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> void HandleKeyPress::dispatch(ReplayController&amp; controller)
</span></span></pre></div>
<a id="trunkSourceWebInspectorUIChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebInspectorUI/ChangeLog (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebInspectorUI/ChangeLog        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Source/WebInspectorUI/ChangeLog        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -1,5 +1,29 @@
</span><span class="cx"> 2014-04-05  Brian J. Burg  &lt;burg@cs.washington.edu&gt;
</span><span class="cx"> 
</span><ins>+        Enable WEB_REPLAY for PLATFORM(MAC)
+        https://bugs.webkit.org/show_bug.cgi?id=130700
+
+        Reviewed by Timothy Hatcher.
+
+        If the ReplayAgent is available, then add an option to toggle between the
+        replay interface and normal Timeline interface from the timeline
+        sidebar panel. The option is available through a context menu item on the
+        sidebar panel's top navigation bar.
+
+        If web replay not available, just show the non-replay interface.
+
+        * Localizations/en.lproj/localizedStrings.js:
+        * UserInterface/Base/Main.js: Add WebInspector.showReplayInterfaceSetting.
+        (WebInspector.loaded):
+
+        * UserInterface/Views/TimelineSidebarPanel.js: Unconditionally create the replay
+        interface elements, but only show them if showReplayInterfaceSetting is enabled.
+        (WebInspector.TimelineSidebarPanel.prototype._updateReplayInterfaceVisibility): Added
+        (WebInspector.TimelineSidebarPanel.prototype._contextMenuNavigationBarOrStatusBar.toggleReplayInterface): Added.
+        (WebInspector.TimelineSidebarPanel.prototype._contextMenuNavigationBarOrStatusBar): Added.
+
+2014-04-05  Brian J. Burg  &lt;burg@cs.washington.edu&gt;
+
</ins><span class="cx">         Web Inspector: remove unused metrics and commands from the Timeline agent
</span><span class="cx">         https://bugs.webkit.org/show_bug.cgi?id=131184
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebInspectorUILocalizationsenlprojlocalizedStringsjs"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -216,6 +216,7 @@
</span><span class="cx"> localizedStrings[&quot;Height&quot;] = &quot;Height&quot;;
</span><span class="cx"> localizedStrings[&quot;Hide compositing borders&quot;] = &quot;Hide compositing borders&quot;;
</span><span class="cx"> localizedStrings[&quot;Hide console (%s)&quot;] = &quot;Hide console (%s)&quot;;
</span><ins>+localizedStrings[&quot;Hide Replay Controls&quot;] = &quot;Hide Replay Controls&quot;;
</ins><span class="cx"> localizedStrings[&quot;Hide shadow DOM nodes&quot;] = &quot;Hide shadow DOM nodes&quot;;
</span><span class="cx"> localizedStrings[&quot;Hide the %s details sidebar&quot;] = &quot;Hide the %s details sidebar&quot;;
</span><span class="cx"> localizedStrings[&quot;Hide the %s details sidebar (%s)&quot;] = &quot;Hide the %s details sidebar (%s)&quot;;
</span><span class="lines">@@ -386,6 +387,7 @@
</span><span class="cx"> localizedStrings[&quot;Show console (%s)&quot;] = &quot;Show console (%s)&quot;;
</span><span class="cx"> localizedStrings[&quot;Show full-height console&quot;] = &quot;Show full-height console&quot;;
</span><span class="cx"> localizedStrings[&quot;Show function definition&quot;] = &quot;Show function definition&quot;;
</span><ins>+localizedStrings[&quot;Show Replay Controls&quot;] = &quot;Show Replay Controls&quot;;
</ins><span class="cx"> localizedStrings[&quot;Show shadow DOM nodes&quot;] = &quot;Show shadow DOM nodes&quot;;
</span><span class="cx"> localizedStrings[&quot;Show split console&quot;] = &quot;Show split console&quot;;
</span><span class="cx"> localizedStrings[&quot;Show the %s details sidebar&quot;] = &quot;Show the %s details sidebar&quot;;
</span></span></pre></div>
<a id="trunkSourceWebInspectorUIUserInterfaceBaseMainjs"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebInspectorUI/UserInterface/Base/Main.js (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebInspectorUI/UserInterface/Base/Main.js        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Source/WebInspectorUI/UserInterface/Base/Main.js        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -159,6 +159,7 @@
</span><span class="cx">     this._dockButtonToggledSetting = new WebInspector.Setting(&quot;dock-button-toggled&quot;, false);
</span><span class="cx"> 
</span><span class="cx">     this.showShadowDOMSetting = new WebInspector.Setting(&quot;show-shadow-dom&quot;, false);
</span><ins>+    this.showReplayInterfaceSetting = new WebInspector.Setting(&quot;show-web-replay&quot;, false);
</ins><span class="cx"> 
</span><span class="cx">     this.mouseCoords = {
</span><span class="cx">         x: 0,
</span></span></pre></div>
<a id="trunkSourceWebInspectorUIUserInterfaceViewsTimelineSidebarPaneljs"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TimelineSidebarPanel.js (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebInspectorUI/UserInterface/Views/TimelineSidebarPanel.js        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/TimelineSidebarPanel.js        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -49,7 +49,7 @@
</span><span class="cx">     timelinesTitleBarElement.classList.add(WebInspector.TimelineSidebarPanel.TimelinesTitleBarStyleClass);
</span><span class="cx">     this.element.insertBefore(timelinesTitleBarElement, this.element.firstChild);
</span><span class="cx"> 
</span><del>-    var statusBarElement = document.createElement(&quot;div&quot;);
</del><ins>+    var statusBarElement = this._statusBarElement = document.createElement(&quot;div&quot;);
</ins><span class="cx">     statusBarElement.classList.add(WebInspector.TimelineSidebarPanel.StatusBarStyleClass);
</span><span class="cx">     this.element.insertBefore(statusBarElement, this.element.firstChild);
</span><span class="cx"> 
</span><span class="lines">@@ -64,31 +64,33 @@
</span><span class="cx">     this._recordStatusElement.className = WebInspector.TimelineSidebarPanel.RecordStatusStyleClass;
</span><span class="cx">     statusBarElement.appendChild(this._recordStatusElement);
</span><span class="cx"> 
</span><del>-    if (window.ReplayAgent) {
-        // If replay support is enabled, hide the default status bar element and show a navigation bar instead.
-        statusBarElement.classList.add(WebInspector.TimelineSidebarPanel.HiddenStyleClassName);
</del><ins>+    WebInspector.showReplayInterfaceSetting.addEventListener(WebInspector.Setting.Event.Changed, this._updateReplayInterfaceVisibility, this);
</ins><span class="cx"> 
</span><del>-        this._navigationBar = new WebInspector.NavigationBar;
-        this.element.appendChild(this._navigationBar.element);
</del><ins>+    // We always create a navigation bar; its visibility is controlled by WebInspector.showReplayInterfaceSetting.
+    this._navigationBar = new WebInspector.NavigationBar;
+    this.element.appendChild(this._navigationBar.element);
</ins><span class="cx"> 
</span><del>-        var toolTip = WebInspector.UIString(&quot;Begin Capturing&quot;);
-        var altToolTip = WebInspector.UIString(&quot;End Capturing&quot;);
-        this._replayCaptureButtonItem = new WebInspector.ActivateButtonNavigationItem(&quot;replay-capture&quot;, toolTip, altToolTip, &quot;Images/Circle.svg&quot;, 16, 16);
-        this._replayCaptureButtonItem.addEventListener(WebInspector.ButtonNavigationItem.Event.Clicked, this._replayCaptureButtonClicked, this);
-        this._replayCaptureButtonItem.enabled = true;
-        this._navigationBar.addNavigationItem(this._replayCaptureButtonItem);
</del><ins>+    var toolTip = WebInspector.UIString(&quot;Begin Capturing&quot;);
+    var altToolTip = WebInspector.UIString(&quot;End Capturing&quot;);
+    this._replayCaptureButtonItem = new WebInspector.ActivateButtonNavigationItem(&quot;replay-capture&quot;, toolTip, altToolTip, &quot;Images/Circle.svg&quot;, 16, 16);
+    this._replayCaptureButtonItem.addEventListener(WebInspector.ButtonNavigationItem.Event.Clicked, this._replayCaptureButtonClicked, this);
+    this._replayCaptureButtonItem.enabled = true;
+    this._navigationBar.addNavigationItem(this._replayCaptureButtonItem);
</ins><span class="cx"> 
</span><del>-        toolTip = WebInspector.UIString(&quot;Start Playback&quot;);
-        altToolTip = WebInspector.UIString(&quot;Pause Playback&quot;);
-        this._replayPauseResumeButtonItem = new WebInspector.ToggleButtonNavigationItem(&quot;replay-pause-resume&quot;, toolTip, altToolTip, &quot;Images/Resume.svg&quot;, &quot;Images/Pause.svg&quot;, 16, 16, true);
-        this._replayPauseResumeButtonItem.addEventListener(WebInspector.ButtonNavigationItem.Event.Clicked, this._replayPauseResumeButtonClicked, this);
-        this._replayPauseResumeButtonItem.enabled = false;
-        this._navigationBar.addNavigationItem(this._replayPauseResumeButtonItem);
</del><ins>+    toolTip = WebInspector.UIString(&quot;Start Playback&quot;);
+    altToolTip = WebInspector.UIString(&quot;Pause Playback&quot;);
+    this._replayPauseResumeButtonItem = new WebInspector.ToggleButtonNavigationItem(&quot;replay-pause-resume&quot;, toolTip, altToolTip, &quot;Images/Resume.svg&quot;, &quot;Images/Pause.svg&quot;, 16, 16, true);
+    this._replayPauseResumeButtonItem.addEventListener(WebInspector.ButtonNavigationItem.Event.Clicked, this._replayPauseResumeButtonClicked, this);
+    this._replayPauseResumeButtonItem.enabled = false;
+    this._navigationBar.addNavigationItem(this._replayPauseResumeButtonItem);
</ins><span class="cx"> 
</span><del>-        WebInspector.replayManager.addEventListener(WebInspector.ReplayManager.Event.CaptureStarted, this._captureStarted, this);
-        WebInspector.replayManager.addEventListener(WebInspector.ReplayManager.Event.CaptureStopped, this._captureStopped, this);
-    }
</del><ins>+    WebInspector.replayManager.addEventListener(WebInspector.ReplayManager.Event.CaptureStarted, this._captureStarted, this);
+    WebInspector.replayManager.addEventListener(WebInspector.ReplayManager.Event.CaptureStopped, this._captureStopped, this);
</ins><span class="cx"> 
</span><ins>+    this._statusBarElement.oncontextmenu = this._contextMenuNavigationBarOrStatusBar.bind(this);
+    this._navigationBar.element.oncontextmenu = this._contextMenuNavigationBarOrStatusBar.bind(this);
+    this._updateReplayInterfaceVisibility();
+
</ins><span class="cx">     function createTimelineTreeElement(label, iconClass, identifier)
</span><span class="cx">     {
</span><span class="cx">         var treeElement = new WebInspector.GeneralTreeElement([iconClass, WebInspector.TimelineSidebarPanel.LargeIconStyleClass], label, null, identifier);
</span><span class="lines">@@ -377,6 +379,31 @@
</span><span class="cx"> 
</span><span class="cx">     // These methods are only used when ReplayAgent is available.
</span><span class="cx"> 
</span><ins>+    _updateReplayInterfaceVisibility: function()
+    {
+        var shouldShowReplayInterface = window.ReplayAgent &amp;&amp; WebInspector.showReplayInterfaceSetting.value;
+
+        this._statusBarElement.classList.toggle(WebInspector.TimelineSidebarPanel.HiddenStyleClassName, shouldShowReplayInterface);
+        this._navigationBar.element.classList.toggle(WebInspector.TimelineSidebarPanel.HiddenStyleClassName, !shouldShowReplayInterface);
+    },
+
+    _contextMenuNavigationBarOrStatusBar: function()
+    {
+        if (!window.ReplayAgent)
+            return;
+
+        function toggleReplayInterface() {
+            WebInspector.showReplayInterfaceSetting.value = !WebInspector.showReplayInterfaceSetting.value;
+        }
+
+        var contextMenu = new WebInspector.ContextMenu(event);
+        if (WebInspector.showReplayInterfaceSetting.value)
+            contextMenu.appendItem(WebInspector.UIString(&quot;Hide Replay Controls&quot;), toggleReplayInterface);
+        else
+            contextMenu.appendItem(WebInspector.UIString(&quot;Show Replay Controls&quot;), toggleReplayInterface);
+        contextMenu.show();
+    },
+
</ins><span class="cx">     _replayCaptureButtonClicked: function()
</span><span class="cx">     {
</span><span class="cx">         if (!this._replayCaptureButtonItem.activated) {
</span></span></pre></div>
<a id="trunkSourceWebKitmacChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/mac/ChangeLog (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/mac/ChangeLog        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Source/WebKit/mac/ChangeLog        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -1,3 +1,12 @@
</span><ins>+2014-04-04  Brian J. Burg  &lt;burg@cs.washington.edu&gt;
+
+        Enable WEB_REPLAY for PLATFORM(MAC)
+        https://bugs.webkit.org/show_bug.cgi?id=130700
+
+        Reviewed by Timothy Hatcher.
+
+        * Configurations/FeatureDefines.xcconfig:
+
</ins><span class="cx"> 2014-04-03  Sam Weinig  &lt;sam@webkit.org&gt;
</span><span class="cx"> 
</span><span class="cx">         [WebKit2] Promote user script SPI to API
</span></span></pre></div>
<a id="trunkSourceWebKitmacConfigurationsFeatureDefinesxcconfig"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/mac/Configurations/FeatureDefines.xcconfig (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/mac/Configurations/FeatureDefines.xcconfig        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Source/WebKit/mac/Configurations/FeatureDefines.xcconfig        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -208,7 +208,13 @@
</span><span class="cx"> ENABLE_VIEW_MODE_CSS_MEDIA = ;
</span><span class="cx"> ENABLE_WEBGL = ENABLE_WEBGL;
</span><span class="cx"> ENABLE_WEB_AUDIO = ENABLE_WEB_AUDIO;
</span><del>-ENABLE_WEB_REPLAY = ;
</del><ins>+ENABLE_WEB_REPLAY = $(ENABLE_WEB_REPLAY_$(PLATFORM_NAME));
+ENABLE_WEB_REPLAY_macosx = $(ENABLE_WEB_REPLAY_macosx_$(CONFIGURATION));
+ENABLE_WEB_REPLAY_macosx_Debug = ENABLE_WEB_REPLAY;
+ENABLE_WEB_REPLAY_macosx_Release = ENABLE_WEB_REPLAY;
+ENABLE_WEB_REPLAY_macosx_Production = ;
+ENABLE_WEB_REPLAY_iphoneos = ;
+ENABLE_WEB_REPLAY_iphonesimulator = ;
</ins><span class="cx"> ENABLE_WEB_SOCKETS = ENABLE_WEB_SOCKETS;
</span><span class="cx"> 
</span><span class="cx"> ENABLE_WEB_TIMING = $(ENABLE_WEB_TIMING_$(PLATFORM_NAME));
</span></span></pre></div>
<a id="trunkSourceWebKit2ChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/ChangeLog (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/ChangeLog        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Source/WebKit2/ChangeLog        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -1,3 +1,12 @@
</span><ins>+2014-04-04  Brian J. Burg  &lt;burg@cs.washington.edu&gt;
+
+        Enable WEB_REPLAY for PLATFORM(MAC)
+        https://bugs.webkit.org/show_bug.cgi?id=130700
+
+        Reviewed by Timothy Hatcher.
+
+        * Configurations/FeatureDefines.xcconfig:
+
</ins><span class="cx"> 2014-04-05  Miyoung Shin  &lt;myid.m.shin@gmail.com&gt;
</span><span class="cx"> 
</span><span class="cx">         [WK2] Fix unused parameter compile warning.
</span></span></pre></div>
<a id="trunkSourceWebKit2ConfigurationsFeatureDefinesxcconfig"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/Configurations/FeatureDefines.xcconfig (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/Configurations/FeatureDefines.xcconfig        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Source/WebKit2/Configurations/FeatureDefines.xcconfig        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -208,7 +208,13 @@
</span><span class="cx"> ENABLE_VIEW_MODE_CSS_MEDIA = ;
</span><span class="cx"> ENABLE_WEBGL = ENABLE_WEBGL;
</span><span class="cx"> ENABLE_WEB_AUDIO = ENABLE_WEB_AUDIO;
</span><del>-ENABLE_WEB_REPLAY = ;
</del><ins>+ENABLE_WEB_REPLAY = $(ENABLE_WEB_REPLAY_$(PLATFORM_NAME));
+ENABLE_WEB_REPLAY_macosx = $(ENABLE_WEB_REPLAY_macosx_$(CONFIGURATION));
+ENABLE_WEB_REPLAY_macosx_Debug = ENABLE_WEB_REPLAY;
+ENABLE_WEB_REPLAY_macosx_Release = ENABLE_WEB_REPLAY;
+ENABLE_WEB_REPLAY_macosx_Production = ;
+ENABLE_WEB_REPLAY_iphoneos = ;
+ENABLE_WEB_REPLAY_iphonesimulator = ;
</ins><span class="cx"> ENABLE_WEB_SOCKETS = ENABLE_WEB_SOCKETS;
</span><span class="cx"> 
</span><span class="cx"> ENABLE_WEB_TIMING = $(ENABLE_WEB_TIMING_$(PLATFORM_NAME));
</span></span></pre></div>
<a id="trunkToolsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Tools/ChangeLog (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/ChangeLog        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Tools/ChangeLog        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -1,3 +1,12 @@
</span><ins>+2014-04-04  Brian J. Burg  &lt;burg@cs.washington.edu&gt;
+
+        Enable WEB_REPLAY for PLATFORM(MAC)
+        https://bugs.webkit.org/show_bug.cgi?id=130700
+
+        Reviewed by Timothy Hatcher.
+
+        * Scripts/webkitperl/FeatureList.pm: Set the default for WEB_REPLAY for OS X engineering builds.
+
</ins><span class="cx"> 2014-04-05  Raphael Kubo da Costa  &lt;raphael.kubo.da.costa@intel.com&gt;
</span><span class="cx"> 
</span><span class="cx">         [CMake] Include X11's include dirs in TestNetscapePlugin
</span></span></pre></div>
<a id="trunkToolsScriptswebkitperlFeatureListpm"></a>
<div class="modfile"><h4>Modified: trunk/Tools/Scripts/webkitperl/FeatureList.pm (166850 => 166851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/Scripts/webkitperl/FeatureList.pm        2014-04-06 16:24:48 UTC (rev 166850)
+++ trunk/Tools/Scripts/webkitperl/FeatureList.pm        2014-04-06 17:28:20 UTC (rev 166851)
</span><span class="lines">@@ -444,7 +444,7 @@
</span><span class="cx">       define =&gt; &quot;ENABLE_WEB_AUDIO&quot;, default =&gt; (isEfl() || isGtk()), value =&gt; \$webAudioSupport },
</span><span class="cx"> 
</span><span class="cx">     { option =&gt; &quot;web-replay&quot;, desc =&gt; &quot;Toggle Web Replay support&quot;,
</span><del>-      define =&gt; &quot;ENABLE_WEB_REPLAY&quot;, default =&gt; 0, value =&gt; \$webReplaySupport },
</del><ins>+      define =&gt; &quot;ENABLE_WEB_REPLAY&quot;, default =&gt; isAppleMacWebKit(), value =&gt; \$webReplaySupport },
</ins><span class="cx"> 
</span><span class="cx">     { option =&gt; &quot;web-sockets&quot;, desc =&gt; &quot;Toggle Web Sockets support&quot;,
</span><span class="cx">       define =&gt; &quot;ENABLE_WEB_SOCKETS&quot;, default =&gt; 1, value =&gt; \$webSocketsSupport },
</span></span></pre>
</div>
</div>

</body>
</html>