Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(358)

Unified Diff: tracing/tracing/value/ui/related_event_set_span.html

Issue 2163833002: [polymer] Fix bad merge in related_event_set_span.html (Closed) Base URL: git@github.com:catapult-project/catapult.git@polymer10-migration
Patch Set: Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tracing/tracing/value/ui/related_event_set_span.html
diff --git a/tracing/tracing/value/ui/related_event_set_span.html b/tracing/tracing/value/ui/related_event_set_span.html
index dfd4d393dcee6a4c6b0850a9e62112e228bfc225..596bec810965f2d86bf8f045cc9cdbf291252f9f 100644
--- a/tracing/tracing/value/ui/related_event_set_span.html
+++ b/tracing/tracing/value/ui/related_event_set_span.html
@@ -6,6 +6,7 @@ found in the LICENSE file.
-->
<link rel="import" href="/tracing/ui/analysis/analysis_link.html">
+<link rel="import" href="/tracing/value/unit.html">
<dom-module id="tr-v-ui-related-event-set-span">
<script>
@@ -30,8 +31,12 @@ found in the LICENSE file.
Polymer.dom(this).textContent = '';
var events = this.diagnostic.events;
var link = document.createElement('tr-ui-a-analysis-link');
- var label = (events.length === 1) ? 'event' : 'events';
- link.setSelectionAndContent(events, events.length + ' ' + label);
+ var label = events.length + ' events';
+ if (events.length === 1) {
+ label = events[0].title + ' ';
+ label += tr.v.Unit.byName.timeDurationInMs.format(events[0].duration);
+ }
+ link.setSelectionAndContent(events, label);
Polymer.dom(this).appendChild(link);
}
});
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698