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

Side by Side Diff: chrome/browser/resources/history/history.js

Issue 1856773002: Provide an explicit 2nd parameter to historyView.showNotification() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 | « no previous file | 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 <include src="../uber/uber_utils.js"> 5 <include src="../uber/uber_utils.js">
6 <include src="history_focus_manager.js"> 6 <include src="history_focus_manager.js">
7 7
8 /////////////////////////////////////////////////////////////////////////////// 8 ///////////////////////////////////////////////////////////////////////////////
9 // Globals: 9 // Globals:
10 /** @const */ var RESULTS_PER_PAGE = 150; 10 /** @const */ var RESULTS_PER_PAGE = 150;
(...skipping 1164 matching lines...) Expand 10 before | Expand all | Expand 10 after
1175 message += '<span>' + loadTimeData.getString( 1175 message += '<span>' + loadTimeData.getString(
1176 hasSyncedResults ? 'hasSyncedResults' : 'noSyncedResults') + '</span>'; 1176 hasSyncedResults ? 'hasSyncedResults' : 'noSyncedResults') + '</span>';
1177 } 1177 }
1178 1178
1179 if (includeOtherFormsOfBrowsingHistory) { 1179 if (includeOtherFormsOfBrowsingHistory) {
1180 message += ' ' /* A whitespace to separate <span>s. */ + '<span>' + 1180 message += ' ' /* A whitespace to separate <span>s. */ + '<span>' +
1181 loadTimeData.getString('otherFormsOfBrowsingHistory') + '</span>'; 1181 loadTimeData.getString('otherFormsOfBrowsingHistory') + '</span>';
1182 } 1182 }
1183 1183
1184 if (message) 1184 if (message)
1185 this.showNotification(message); 1185 this.showNotification(message, false /* isWarning */);
1186 }; 1186 };
1187 1187
1188 /** 1188 /**
1189 * @param {Visit} visit The visit about to be removed from this view. 1189 * @param {Visit} visit The visit about to be removed from this view.
1190 */ 1190 */
1191 HistoryView.prototype.onBeforeRemove = function(visit) { 1191 HistoryView.prototype.onBeforeRemove = function(visit) {
1192 assert(this.currentVisits_.indexOf(visit) >= 0); 1192 assert(this.currentVisits_.indexOf(visit) >= 0);
1193 1193
1194 var rowIndex = this.focusGrid_.getRowIndexForTarget(document.activeElement); 1194 var rowIndex = this.focusGrid_.getRowIndexForTarget(document.activeElement);
1195 if (rowIndex == -1) 1195 if (rowIndex == -1)
(...skipping 1206 matching lines...) Expand 10 before | Expand all | Expand 10 after
2402 historyView.reload(); 2402 historyView.reload();
2403 } 2403 }
2404 2404
2405 // Add handlers to HTML elements. 2405 // Add handlers to HTML elements.
2406 document.addEventListener('DOMContentLoaded', load); 2406 document.addEventListener('DOMContentLoaded', load);
2407 2407
2408 // This event lets us enable and disable menu items before the menu is shown. 2408 // This event lets us enable and disable menu items before the menu is shown.
2409 document.addEventListener('canExecute', function(e) { 2409 document.addEventListener('canExecute', function(e) {
2410 e.canExecute = true; 2410 e.canExecute = true;
2411 }); 2411 });
OLDNEW
« 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