<!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>[161454] trunk/Tools</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/161454">161454</a></dd>
<dt>Author</dt> <dd>ap@apple.com</dd>
<dt>Date</dt> <dd>2014-01-07 14:06:08 -0800 (Tue, 07 Jan 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>Popovers at build.webkit.org/dashboard could have titles
https://bugs.webkit.org/show_bug.cgi?id=126495

Reviewed by Timothy Hatcher.

Added titles to all popovers except for pending revisions one, which I would like
to improve more (probably add an ETA).

* BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotBuilderQueueView.js:
(BuildbotBuilderQueueView.prototype._presentPopoverFailureLogs): Moved code for
adding a title to base class.

* BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotQueueView.js:
(BuildbotQueueView.prototype._presentPopoverForPendingCommits): Moved code for inserting
a divider to a separate function.
(BuildbotQueueView.prototype._presentPopoverForRevisionRange): Added a title.
(BuildbotQueueView.prototype._presentNoChangePopover): Updated the text to match
title from above function.
(BuildbotQueueView.prototype._revisionPopoverContentForIteration): Renamed &quot;contentElement&quot;
variable to &quot;content&quot; to match all other code.
(BuildbotQueueView.prototype._addIterationHeadingToPopover): Added.
(BuildbotQueueView.prototype._addDividerToPopover): Added.

* BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotTesterQueueView.js:
(BuildbotTesterQueueView.prototype._popoverContentForLayoutTestRegressions): Add a title.
(BuildbotTesterQueueView.prototype._presentPopoverForLayoutTestRegressions): Ditto.
(BuildbotTesterQueueView.prototype._presentPopoverForMultipleFailureKinds): Ditto.

* BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Styles/QueueView.css:</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkToolsBuildSlaveSupportbuildwebkitorgconfigpublic_htmldashboardScriptsBuildbotBuilderQueueViewjs">trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotBuilderQueueView.js</a></li>
<li><a href="#trunkToolsBuildSlaveSupportbuildwebkitorgconfigpublic_htmldashboardScriptsBuildbotQueueViewjs">trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotQueueView.js</a></li>
<li><a href="#trunkToolsBuildSlaveSupportbuildwebkitorgconfigpublic_htmldashboardScriptsBuildbotTesterQueueViewjs">trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotTesterQueueView.js</a></li>
<li><a href="#trunkToolsBuildSlaveSupportbuildwebkitorgconfigpublic_htmldashboardStylesQueueViewcss">trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Styles/QueueView.css</a></li>
<li><a href="#trunkToolsChangeLog">trunk/Tools/ChangeLog</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkToolsBuildSlaveSupportbuildwebkitorgconfigpublic_htmldashboardScriptsBuildbotBuilderQueueViewjs"></a>
<div class="modfile"><h4>Modified: trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotBuilderQueueView.js (161453 => 161454)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotBuilderQueueView.js        2014-01-07 21:50:49 UTC (rev 161453)
+++ trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotBuilderQueueView.js        2014-01-07 22:06:08 UTC (rev 161454)
</span><span class="lines">@@ -143,18 +143,9 @@
</span><span class="cx">             content.appendChild(line);
</span><span class="cx">         }
</span><span class="cx"> 
</span><del>-        var title = document.createElement(&quot;div&quot;);
-        title.className = &quot;build-logs-popover-title&quot;;
-        title.textContent = iteration.queue.id;
-        content.appendChild(title);
</del><ins>+        this._addIterationHeadingToPopover(iteration, content);
+        this._addDividerToPopover(content);
</ins><span class="cx">         
</span><del>-        var builderPageLine = document.createElement(&quot;a&quot;);
-        builderPageLine.className = &quot;build-page-link&quot;;
-        builderPageLine.href = iteration.queue.buildbot.buildPageURLForIteration(iteration);
-        builderPageLine.textContent = &quot;build #&quot; + iteration.id;
-        builderPageLine.target = &quot;_blank&quot;;
-        content.appendChild(builderPageLine);
-
</del><span class="cx">         var logsHeadingLine = document.createElement(&quot;div&quot;);
</span><span class="cx">         logsHeadingLine.className = &quot;build-logs-heading&quot;;
</span><span class="cx">         logsHeadingLine.textContent = iteration.firstFailedStepName + &quot; failed&quot;;
</span></span></pre></div>
<a id="trunkToolsBuildSlaveSupportbuildwebkitorgconfigpublic_htmldashboardScriptsBuildbotQueueViewjs"></a>
<div class="modfile"><h4>Modified: trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotQueueView.js (161453 => 161454)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotQueueView.js        2014-01-07 21:50:49 UTC (rev 161453)
+++ trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotQueueView.js        2014-01-07 22:06:08 UTC (rev 161454)
</span><span class="lines">@@ -166,11 +166,8 @@
</span><span class="cx">         if (latestProductiveIteration.internalRevision &amp;&amp; internalTrac.latestRecordedRevisionNumber)
</span><span class="cx">             var linesForInternal = this._popoverLinesForCommitRange(internalTrac, latestProductiveIteration.internalRevision + 1, internalTrac.latestRecordedRevisionNumber);
</span><span class="cx"> 
</span><del>-        if (linesForOpenSource.length &amp;&amp; linesForInternal.length) {
-            var divider = document.createElement(&quot;div&quot;);
-            divider.className = &quot;divider&quot;;
-            content.appendChild(divider);
-        }
</del><ins>+        if (linesForOpenSource.length &amp;&amp; linesForInternal.length)
+            this._addDividerToPopover(content);
</ins><span class="cx"> 
</span><span class="cx">         for (var i = 0; i != linesForInternal.length; ++i)
</span><span class="cx">             content.appendChild(linesForInternal[i]);
</span><span class="lines">@@ -191,6 +188,12 @@
</span><span class="cx">         if (!linesForCommits.length)
</span><span class="cx">             return false;
</span><span class="cx"> 
</span><ins>+        var line = document.createElement(&quot;div&quot;);
+        line.className = &quot;title&quot;;
+        line.textContent = &quot;new commits in this build&quot;;
+        content.appendChild(line);
+        this._addDividerToPopover(content);
+
</ins><span class="cx">         for (var i = 0; i != linesForCommits.length; ++i)
</span><span class="cx">             content.appendChild(linesForCommits[i]);
</span><span class="cx"> 
</span><span class="lines">@@ -208,7 +211,7 @@
</span><span class="cx"> 
</span><span class="cx">         var line = document.createElement(&quot;div&quot;);
</span><span class="cx">         line.className = &quot;no-commits&quot;;
</span><del>-        line.textContent = &quot;no new commits in this buildbot queue iteration&quot;;
</del><ins>+        line.textContent = &quot;no new commits in this build&quot;;
</ins><span class="cx">         
</span><span class="cx">         content.appendChild(line);
</span><span class="cx"> 
</span><span class="lines">@@ -221,9 +224,9 @@
</span><span class="cx"> 
</span><span class="cx">     _revisionPopoverContentForIteration: function(iteration, internal)
</span><span class="cx">     {
</span><del>-        var contentElement = document.createElement(&quot;span&quot;);
-        contentElement.textContent = &quot;r&quot; + (internal ? iteration.internalRevision : iteration.openSourceRevision);
-        contentElement.classList.add(&quot;revision-number&quot;);
</del><ins>+        var content = document.createElement(&quot;span&quot;);
+        content.textContent = &quot;r&quot; + (internal ? iteration.internalRevision : iteration.openSourceRevision);
+        content.classList.add(&quot;revision-number&quot;);
</ins><span class="cx"> 
</span><span class="cx">         var previousIteration = iteration.previousProductiveIteration;
</span><span class="cx">         if (previousIteration) {
</span><span class="lines">@@ -233,14 +236,48 @@
</span><span class="cx">                 lastRevision: internal ? iteration.internalRevision : iteration.openSourceRevision
</span><span class="cx">             };
</span><span class="cx">             if (context.firstRevision &lt;= context.lastRevision)
</span><del>-                new PopoverTracker(contentElement, this._presentPopoverForRevisionRange.bind(this), context);
</del><ins>+                new PopoverTracker(content, this._presentPopoverForRevisionRange.bind(this), context);
</ins><span class="cx">             else
</span><del>-                new PopoverTracker(contentElement, this._presentNoChangePopover.bind(this), context);
</del><ins>+                new PopoverTracker(content, this._presentNoChangePopover.bind(this), context);
</ins><span class="cx">         }
</span><span class="cx"> 
</span><del>-        return contentElement;
</del><ins>+        return content;
</ins><span class="cx">     },
</span><span class="cx"> 
</span><ins>+    _addIterationHeadingToPopover: function(iteration, content, additionalText)
+    {
+        var title = document.createElement(&quot;div&quot;);
+        title.className = &quot;popover-iteration-heading&quot;;
+
+        var queueName = document.createElement(&quot;span&quot;);
+        queueName.className = &quot;queue-name&quot;;
+        queueName.textContent = iteration.queue.id;
+        title.appendChild(queueName);
+
+        var buildbotLink = document.createElement(&quot;a&quot;);
+        buildbotLink.className = &quot;buildbot-link&quot;;
+        buildbotLink.textContent = &quot;build #&quot; + iteration.id;
+        buildbotLink.href = iteration.queue.buildbot.buildPageURLForIteration(iteration);
+        buildbotLink.target = &quot;_blank&quot;;
+        title.appendChild(buildbotLink);
+
+        if (additionalText) {
+            var additionalTextElement = document.createElement(&quot;span&quot;);
+            additionalTextElement.className = &quot;additional-text&quot;;
+            additionalTextElement.textContent = additionalText;
+            title.appendChild(additionalTextElement);
+        }
+
+        content.appendChild(title);
+    },
+
+    _addDividerToPopover: function(content)
+    {
+        var divider = document.createElement(&quot;div&quot;);
+        divider.className = &quot;divider&quot;;
+        content.appendChild(divider);
+    },
+
</ins><span class="cx">     revisionContentForIteration: function(iteration)
</span><span class="cx">     {
</span><span class="cx">         console.assert(iteration.openSourceRevision);
</span></span></pre></div>
<a id="trunkToolsBuildSlaveSupportbuildwebkitorgconfigpublic_htmldashboardScriptsBuildbotTesterQueueViewjs"></a>
<div class="modfile"><h4>Modified: trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotTesterQueueView.js (161453 => 161454)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotTesterQueueView.js        2014-01-07 21:50:49 UTC (rev 161453)
+++ trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotTesterQueueView.js        2014-01-07 22:06:08 UTC (rev 161454)
</span><span class="lines">@@ -140,6 +140,9 @@
</span><span class="cx">         var content = document.createElement(&quot;div&quot;);
</span><span class="cx">         content.className = &quot;test-results-popover&quot;;
</span><span class="cx"> 
</span><ins>+        this._addIterationHeadingToPopover(iteration, content, &quot;layout test failures&quot;);
+        this._addDividerToPopover(content);
+
</ins><span class="cx">         if (!iteration.layoutTestResults.regressions) {
</span><span class="cx">             var message = document.createElement(&quot;div&quot;);
</span><span class="cx">             message.className = &quot;loading-failure&quot;;
</span><span class="lines">@@ -199,6 +202,9 @@
</span><span class="cx">             var content = document.createElement(&quot;div&quot;);
</span><span class="cx">             content.className = &quot;test-results-popover&quot;;
</span><span class="cx"> 
</span><ins>+            this._addIterationHeadingToPopover(iteration, content, &quot;layout test failures&quot;);
+            this._addDividerToPopover(content);
+
</ins><span class="cx">             var loadingIndicator = document.createElement(&quot;div&quot;);
</span><span class="cx">             loadingIndicator.className = &quot;loading-indicator&quot;;
</span><span class="cx">             loadingIndicator.textContent = &quot;Loading\u2026&quot;;
</span><span class="lines">@@ -236,6 +242,9 @@
</span><span class="cx">         var content = document.createElement(&quot;div&quot;);
</span><span class="cx">         content.className = &quot;test-results-popover&quot;;
</span><span class="cx"> 
</span><ins>+        this._addIterationHeadingToPopover(iteration, content);
+        this._addDividerToPopover(content);
+
</ins><span class="cx">         if (layoutTestResults.failureCount) {
</span><span class="cx">             var message = (layoutTestResults.tooManyFailures ? layoutTestResults.failureCount + &quot;\uff0b&quot; : layoutTestResults.failureCount) + &quot;\u00a0&quot; +
</span><span class="cx">                 (layoutTestResults.failureCount === 1 ? &quot;layout test failure&quot; : &quot;layout test failures&quot;);
</span></span></pre></div>
<a id="trunkToolsBuildSlaveSupportbuildwebkitorgconfigpublic_htmldashboardStylesQueueViewcss"></a>
<div class="modfile"><h4>Modified: trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Styles/QueueView.css (161453 => 161454)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Styles/QueueView.css        2014-01-07 21:50:49 UTC (rev 161453)
+++ trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Styles/QueueView.css        2014-01-07 22:06:08 UTC (rev 161454)
</span><span class="lines">@@ -40,8 +40,16 @@
</span><span class="cx">     margin-top: 10px;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.commit-history-popover &gt; .pending-commit,
-.commit-history-popover &gt; .no-commits {
</del><ins>+.popover .divider {
+    height: 7px;
+}
+
+.popover .popover-iteration-heading .buildbot-link,
+.popover .popover-iteration-heading .additional-text {
+    padding-left: 5px;
+}
+
+.commit-history-popover {
</ins><span class="cx">     font-family: &quot;HelveticaNeue-Light&quot;, &quot;Helvetica Neue&quot;, sans-serif;
</span><span class="cx">     color: rgb(145, 135, 95);
</span><span class="cx">     font-size: 12px;
</span><span class="lines">@@ -59,8 +67,12 @@
</span><span class="cx">     color: black;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.commit-history-popover &gt; .divider {
-    height: 7px;
</del><ins>+.build-logs-popover {
+    font-family: &quot;HelveticaNeue-Light&quot;, &quot;Helvetica Neue&quot;, sans-serif;
+    color: rgb(145, 135, 95);
+    font-size: 12px;
+    text-align: left;
+    padding: 1px 6px 1px 6px;
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> .build-logs-popover {
</span></span></pre></div>
<a id="trunkToolsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Tools/ChangeLog (161453 => 161454)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/ChangeLog        2014-01-07 21:50:49 UTC (rev 161453)
+++ trunk/Tools/ChangeLog        2014-01-07 22:06:08 UTC (rev 161454)
</span><span class="lines">@@ -1,5 +1,37 @@
</span><span class="cx"> 2014-01-07  Alexey Proskuryakov  &lt;ap@apple.com&gt;
</span><span class="cx"> 
</span><ins>+        Popovers at build.webkit.org/dashboard could have titles
+        https://bugs.webkit.org/show_bug.cgi?id=126495
+
+        Reviewed by Timothy Hatcher.
+
+        Added titles to all popovers except for pending revisions one, which I would like
+        to improve more (probably add an ETA).
+
+        * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotBuilderQueueView.js:
+        (BuildbotBuilderQueueView.prototype._presentPopoverFailureLogs): Moved code for 
+        adding a title to base class.
+
+        * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotQueueView.js:
+        (BuildbotQueueView.prototype._presentPopoverForPendingCommits): Moved code for inserting
+        a divider to a separate function.
+        (BuildbotQueueView.prototype._presentPopoverForRevisionRange): Added a title.
+        (BuildbotQueueView.prototype._presentNoChangePopover): Updated the text to match
+        title from above function.
+        (BuildbotQueueView.prototype._revisionPopoverContentForIteration): Renamed &quot;contentElement&quot;
+        variable to &quot;content&quot; to match all other code.
+        (BuildbotQueueView.prototype._addIterationHeadingToPopover): Added.
+        (BuildbotQueueView.prototype._addDividerToPopover): Added.
+
+        * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotTesterQueueView.js:
+        (BuildbotTesterQueueView.prototype._popoverContentForLayoutTestRegressions): Add a title.
+        (BuildbotTesterQueueView.prototype._presentPopoverForLayoutTestRegressions): Ditto.
+        (BuildbotTesterQueueView.prototype._presentPopoverForMultipleFailureKinds): Ditto.
+
+        * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Styles/QueueView.css:
+
+2014-01-07  Alexey Proskuryakov  &lt;ap@apple.com&gt;
+
</ins><span class="cx">         There should be a delay when quickly switching to a different popover at build.webkit.org/dashboard
</span><span class="cx">         https://bugs.webkit.org/show_bug.cgi?id=126472
</span><span class="cx"> 
</span></span></pre>
</div>
</div>

</body>
</html>