| OLD | NEW |
| 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 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 193 // Let the entryBox be styled appropriately when it contains keyboard focus. | 193 // Let the entryBox be styled appropriately when it contains keyboard focus. |
| 194 entryBox.addEventListener('focus', function() { | 194 entryBox.addEventListener('focus', function() { |
| 195 this.classList.add('contains-focus'); | 195 this.classList.add('contains-focus'); |
| 196 }, true); | 196 }, true); |
| 197 entryBox.addEventListener('blur', function() { | 197 entryBox.addEventListener('blur', function() { |
| 198 this.classList.remove('contains-focus'); | 198 this.classList.remove('contains-focus'); |
| 199 }, true); | 199 }, true); |
| 200 | 200 |
| 201 node.appendChild(entryBox); | 201 node.appendChild(entryBox); |
| 202 if (this.model_.isManagedProfile && this.model_.getGroupByDomain()) { | 202 if (this.model_.isManagedProfile && this.model_.getGroupByDomain()) { |
| 203 entryBox.appendChild( | 203 node.appendChild( |
| 204 getManagedStatusDOM(this.urlManualBehavior, this.urlInContentPack)); | 204 getManagedStatusDOM(this.urlManualBehavior, this.urlInContentPack)); |
| 205 } | 205 } |
| 206 | 206 |
| 207 if (isSearchResult) { | 207 if (isSearchResult) { |
| 208 time.appendChild(document.createTextNode(this.dateShort)); | 208 time.appendChild(document.createTextNode(this.dateShort)); |
| 209 var snippet = createElementWithClassName('div', 'snippet'); | 209 var snippet = createElementWithClassName('div', 'snippet'); |
| 210 this.addHighlightedText_(snippet, | 210 this.addHighlightedText_(snippet, |
| 211 this.snippet_, | 211 this.snippet_, |
| 212 this.model_.getSearchText()); | 212 this.model_.getSearchText()); |
| 213 node.appendChild(snippet); | 213 node.appendChild(snippet); |
| (...skipping 1630 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1844 } | 1844 } |
| 1845 } | 1845 } |
| 1846 | 1846 |
| 1847 // Add handlers to HTML elements. | 1847 // Add handlers to HTML elements. |
| 1848 document.addEventListener('DOMContentLoaded', load); | 1848 document.addEventListener('DOMContentLoaded', load); |
| 1849 | 1849 |
| 1850 // This event lets us enable and disable menu items before the menu is shown. | 1850 // This event lets us enable and disable menu items before the menu is shown. |
| 1851 document.addEventListener('canExecute', function(e) { | 1851 document.addEventListener('canExecute', function(e) { |
| 1852 e.canExecute = true; | 1852 e.canExecute = true; |
| 1853 }); | 1853 }); |
| OLD | NEW |