OLD | NEW |
---|---|
1 <!-- | 1 <!-- |
2 Copyright 2014 The Chromium Authors. All rights reserved. | 2 Copyright 2014 The Chromium Authors. All rights reserved. |
3 Use of this source code is governed by a BSD-style license that can be | 3 Use of this source code is governed by a BSD-style license that can be |
4 found in the LICENSE file. | 4 found in the LICENSE file. |
5 --> | 5 --> |
6 | 6 |
7 <link rel="import" href="../bower_components/paper-button/paper-button.html"> | 7 <link rel="import" href="../bower_components/paper-button/paper-button.html"> |
8 <link rel="import" href="../model/ct-commit-log.html"> | 8 <link rel="import" href="../model/ct-commit-log.html"> |
9 <link rel="import" href="ct-failure-analyzer.html"> | 9 <link rel="import" href="ct-failure-analyzer.html"> |
10 <link rel="import" href="ct-failure-stream.html"> | 10 <link rel="import" href="ct-failure-stream.html"> |
11 <link rel="import" href="ct-last-updated.html"> | |
11 <link rel="import" href="ct-tree-status.html"> | 12 <link rel="import" href="ct-tree-status.html"> |
12 | 13 |
13 <polymer-element name="ct-unexpected-failures" attributes="tree"> | 14 <polymer-element name="ct-unexpected-failures" attributes="tree"> |
14 <template> | 15 <template> |
15 <style> | 16 <style> |
16 ct-tree-status { | 17 ct-tree-status { |
17 white-space: nowrap; | 18 white-space: nowrap; |
18 overflow: hidden; | 19 overflow: hidden; |
19 text-overflow: ellipsis; | 20 text-overflow: ellipsis; |
20 margin: 5px; | 21 margin: 5px; |
21 padding: 3px; | 22 padding: 3px; |
22 } | 23 } |
23 | 24 |
24 ct-tree-status[status=open] { | 25 ct-tree-status[status=open] { |
25 margin: 0; | 26 margin: 0; |
26 padding: 0; | 27 padding: 0; |
27 } | 28 } |
29 | |
30 ct-last-updated { | |
31 white-space: nowrap; | |
32 overflow: hidden; | |
33 text-overflow: ellipsis; | |
34 margin: 5px; | |
35 padding: 3px; | |
36 } | |
28 </style> | 37 </style> |
29 <ct-failure-analyzer id="analyzer" failures="{{ failures }}" builderLatestRe visions="{{ builderLatestRevisions }}"></ct-failure-analyzer> | 38 <ct-failure-analyzer id="analyzer" failures="{{ failures }}" builderLatestRe visions="{{ builderLatestRevisions }}" date="{{ date }}"></ct-failure-analyzer> |
30 <ct-tree-status project="chromium"></ct-tree-status> | 39 <ct-tree-status project="chromium"></ct-tree-status> |
31 <ct-tree-status project="blink"></ct-tree-status> | 40 <ct-tree-status project="blink"></ct-tree-status> |
41 <ct-last-updated id="last_updated" date="{{ date }}"></ct-last-updated> | |
ojan
2014/08/08 06:05:13
I'd like to conserve this screen real estate as mu
teravest
2014/08/08 22:21:28
Sounds good. I've moved this into the top bar and
| |
32 <ct-failure-stream groups="{{ failures[tree] }}" commits="{{ revisionLog }}" tree="{{ tree }}"></ct-failure-stream> | 42 <ct-failure-stream groups="{{ failures[tree] }}" commits="{{ revisionLog }}" tree="{{ tree }}"></ct-failure-stream> |
33 </template> | 43 </template> |
34 <script> | 44 <script> |
35 (function() { | 45 (function() { |
36 var kUpdateFrequency = 1000 * 30; | 46 var kUpdateFrequency = 1000 * 30; |
37 | 47 |
38 Polymer({ | 48 Polymer({ |
39 revisionLog: new CTCommitLog(), | 49 revisionLog: new CTCommitLog(), |
40 tree: '', | 50 tree: '', |
41 | 51 |
42 attached: function() { | 52 attached: function() { |
43 this.update(); | 53 this.update(); |
44 setInterval(this.update.bind(this), kUpdateFrequency); | 54 setInterval(this.update.bind(this), kUpdateFrequency); |
45 }, | 55 }, |
46 | 56 |
47 update: function() { | 57 update: function() { |
48 // FIXME: These shouldn't update if there's already an update in progres s. | 58 // FIXME: These shouldn't update if there's already an update in progres s. |
49 this.revisionLog.update(); | 59 this.revisionLog.update(); |
50 this.$.analyzer.update(); | 60 this.$.analyzer.update(); |
51 var treeStatuses = this.shadowRoot.querySelectorAll("ct-tree-status"); | 61 var treeStatuses = this.shadowRoot.querySelectorAll("ct-tree-status"); |
52 for (var i = 0; i < treeStatuses.length; i++) | 62 for (var i = 0; i < treeStatuses.length; i++) |
53 treeStatuses[i].update(); | 63 treeStatuses[i].update(); |
64 this.$.last_updated.update(); | |
54 }, | 65 }, |
55 }); | 66 }); |
56 })(); | 67 })(); |
57 </script> | 68 </script> |
58 </polymer-element> | 69 </polymer-element> |
OLD | NEW |