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

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

Issue 18593003: Disable mouse-focus of buttons in some WebUI pages (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add a public function to FocusManager Created 7 years, 5 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 | Annotate | Revision Log
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 6
7 /////////////////////////////////////////////////////////////////////////////// 7 ///////////////////////////////////////////////////////////////////////////////
8 // Globals: 8 // Globals:
9 /** @const */ var RESULTS_PER_PAGE = 150; 9 /** @const */ var RESULTS_PER_PAGE = 150;
10 10
(...skipping 1510 matching lines...) Expand 10 before | Expand all | Expand 10 after
1521 $('filter-controls').hidden = false; 1521 $('filter-controls').hidden = false;
1522 } 1522 }
1523 1523
1524 var title = loadTimeData.getString('title'); 1524 var title = loadTimeData.getString('title');
1525 uber.invokeMethodOnParent('setTitle', {title: title}); 1525 uber.invokeMethodOnParent('setTitle', {title: title});
1526 1526
1527 // Adjust the position of the notification bar when the window size changes. 1527 // Adjust the position of the notification bar when the window size changes.
1528 window.addEventListener('resize', 1528 window.addEventListener('resize',
1529 historyView.positionNotificationBar.bind(historyView)); 1529 historyView.positionNotificationBar.bind(historyView));
1530 1530
1531 cr.ui.FocusManager.disableMouseFocusOnButtons();
1532
1531 if (isMobileVersion()) { 1533 if (isMobileVersion()) {
1532 if (searchField) { 1534 if (searchField) {
1533 // Move the search box out of the header. 1535 // Move the search box out of the header.
1534 var resultsDisplay = $('results-display'); 1536 var resultsDisplay = $('results-display');
1535 resultsDisplay.parentNode.insertBefore($('search-field'), resultsDisplay); 1537 resultsDisplay.parentNode.insertBefore($('search-field'), resultsDisplay);
1536 1538
1537 window.addEventListener( 1539 window.addEventListener(
1538 'resize', historyView.updateClearBrowsingDataButton_); 1540 'resize', historyView.updateClearBrowsingDataButton_);
1539 1541
1540 // When the search field loses focus, add a delay before updating the 1542 // When the search field loses focus, add a delay before updating the
(...skipping 334 matching lines...) Expand 10 before | Expand all | Expand 10 after
1875 historyView.reload(); 1877 historyView.reload();
1876 } 1878 }
1877 1879
1878 // Add handlers to HTML elements. 1880 // Add handlers to HTML elements.
1879 document.addEventListener('DOMContentLoaded', load); 1881 document.addEventListener('DOMContentLoaded', load);
1880 1882
1881 // This event lets us enable and disable menu items before the menu is shown. 1883 // This event lets us enable and disable menu items before the menu is shown.
1882 document.addEventListener('canExecute', function(e) { 1884 document.addEventListener('canExecute', function(e) {
1883 e.canExecute = true; 1885 e.canExecute = true;
1884 }); 1886 });
OLDNEW
« no previous file with comments | « chrome/browser/resources/history/history.html ('k') | chrome/browser/resources/ntp4/new_tab.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698