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

Side by Side Diff: chrome/browser/resources/md_history/history_list.js

Issue 2333163002: MD History: Remove isFirstItem property from history-item (Closed)
Patch Set: Fix sizing Created 4 years, 3 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 unified diff | Download patch
« no previous file with comments | « chrome/browser/resources/md_history/history_list.html ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 Polymer({ 5 Polymer({
6 is: 'history-list', 6 is: 'history-list',
7 7
8 behaviors: [HistoryListBehavior], 8 behaviors: [HistoryListBehavior],
9 9
10 properties: { 10 properties: {
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
146 */ 146 */
147 isCardEnd_: function(item, i, length) { 147 isCardEnd_: function(item, i, length) {
148 if (length == 0 || i > length - 1) 148 if (length == 0 || i > length - 1)
149 return false; 149 return false;
150 return i == length - 1 || 150 return i == length - 1 ||
151 this.historyData_[i].dateRelativeDay != 151 this.historyData_[i].dateRelativeDay !=
152 this.historyData_[i + 1].dateRelativeDay; 152 this.historyData_[i + 1].dateRelativeDay;
153 }, 153 },
154 154
155 /** 155 /**
156 * @param {number} index
157 * @return {boolean}
158 * @private
159 */
160 isFirstItem_: function(index) {
161 return index == 0;
162 },
163
164 /**
165 * @private 156 * @private
166 */ 157 */
167 notifyListScroll_: function() { 158 notifyListScroll_: function() {
168 this.fire('history-list-scrolled'); 159 this.fire('history-list-scrolled');
169 }, 160 },
170 161
171 /** 162 /**
172 * @param {number} index 163 * @param {number} index
173 * @return {string} 164 * @return {string}
174 * @private 165 * @private
175 */ 166 */
176 pathForItem_: function(index) { 167 pathForItem_: function(index) {
177 return 'historyData_.' + index; 168 return 'historyData_.' + index;
178 }, 169 },
179 }); 170 });
OLDNEW
« no previous file with comments | « chrome/browser/resources/md_history/history_list.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698