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="ct-commit.html"> | 7 <link rel="import" href="ct-commit.html"> |
8 | 8 |
9 <polymer-element name="ct-commit-list" attributes="first last commits" noscript> | 9 <polymer-element name="ct-commit-list" attributes="first last commits" noscript> |
10 <template> | 10 <template> |
(...skipping 16 matching lines...) Expand all Loading... | |
27 _revisions: [], | 27 _revisions: [], |
28 | 28 |
29 observe: { | 29 observe: { |
30 first: '_update', | 30 first: '_update', |
31 last: '_update', | 31 last: '_update', |
32 }, | 32 }, |
33 | 33 |
34 _update: function() { | 34 _update: function() { |
35 if (!this.first || !this.last) | 35 if (!this.first || !this.last) |
36 return; | 36 return; |
37 | 37 this._revisions = Number.range(this.first, this.last).every(1); |
esprehn
2014/07/22 02:49:44
1 is the default, you don't need to pass it, thoug
| |
38 this._revisions = []; | |
39 for (var i = this.first; i <= this.last; i++) | |
40 this._revisions.push(i); | |
41 }, | 38 }, |
42 }); | 39 }); |
43 </script> | 40 </script> |
44 </polymer-element> | 41 </polymer-element> |
OLD | NEW |