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

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

Issue 2656443004: MD History: Add routing for grouped history mode. (Closed)
Patch Set: Review comments Created 3 years, 10 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
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-toolbar', 6 is: 'history-toolbar',
7 properties: { 7 properties: {
8 // Number of history items currently selected. 8 // Number of history items currently selected.
9 // TODO(calamity): bind this to 9 // TODO(calamity): bind this to
10 // listContainer.selectedItem.selectedPaths.length. 10 // listContainer.selectedItem.selectedPaths.length.
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after
201 }, 201 },
202 202
203 /** @private */ 203 /** @private */
204 numberOfItemsSelected_: function(count) { 204 numberOfItemsSelected_: function(count) {
205 return count > 0 ? loadTimeData.getStringF('itemsSelected', count) : ''; 205 return count > 0 ? loadTimeData.getStringF('itemsSelected', count) : '';
206 }, 206 },
207 207
208 /** @private */ 208 /** @private */
209 getHistoryInterval_: function() { 209 getHistoryInterval_: function() {
210 var info = this.queryInfo; 210 var info = this.queryInfo;
211 if (!info)
212 return;
213
211 if (this.groupedRange == HistoryRange.WEEK) 214 if (this.groupedRange == HistoryRange.WEEK)
212 return info.queryInterval; 215 return info.queryInterval;
213 216
214 if (this.groupedRange == HistoryRange.MONTH) 217 if (this.groupedRange == HistoryRange.MONTH)
215 return info.queryStartMonth; 218 return info.queryStartMonth;
216 }, 219 },
217 220
218 /** 221 /**
219 * @param {Event} e 222 * @param {Event} e
220 * @private 223 * @private
(...skipping 28 matching lines...) Expand all
249 }, 252 },
250 253
251 /** 254 /**
252 * @private 255 * @private
253 * @return {boolean} 256 * @return {boolean}
254 */ 257 */
255 isToday_: function() { 258 isToday_: function() {
256 return this.groupedOffset == 0; 259 return this.groupedOffset == 0;
257 }, 260 },
258 }); 261 });
OLDNEW
« no previous file with comments | « chrome/browser/resources/md_history/history_toolbar.html ('k') | chrome/browser/resources/md_history/lazy_load.crisper.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698