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 cr.define('options', function() { | 5 cr.define('options', function() { |
6 | 6 |
7 var OptionsPage = options.OptionsPage; | 7 var OptionsPage = options.OptionsPage; |
8 | 8 |
9 ///////////////////////////////////////////////////////////////////////////// | 9 ///////////////////////////////////////////////////////////////////////////// |
10 // CookiesView class: | 10 // CookiesView class: |
(...skipping 20 matching lines...) Expand all Loading... |
31 */ | 31 */ |
32 queryDelayTimerId_: 0, | 32 queryDelayTimerId_: 0, |
33 | 33 |
34 /** | 34 /** |
35 * The most recent search query, empty string if the query is empty. | 35 * The most recent search query, empty string if the query is empty. |
36 * @type {string} | 36 * @type {string} |
37 * @private | 37 * @private |
38 */ | 38 */ |
39 lastQuery_: '', | 39 lastQuery_: '', |
40 | 40 |
| 41 /** @override */ |
41 initializePage: function() { | 42 initializePage: function() { |
42 OptionsPage.prototype.initializePage.call(this); | 43 OptionsPage.prototype.initializePage.call(this); |
43 | 44 |
44 var searchBox = this.pageDiv.querySelector('.cookies-search-box'); | 45 var searchBox = this.pageDiv.querySelector('.cookies-search-box'); |
45 searchBox.addEventListener( | 46 searchBox.addEventListener( |
46 'search', this.handleSearchQueryChange_.bind(this)); | 47 'search', this.handleSearchQueryChange_.bind(this)); |
47 searchBox.onkeydown = function(e) { | 48 searchBox.onkeydown = function(e) { |
48 // Prevent the overlay from handling this event. | 49 // Prevent the overlay from handling this event. |
49 if (e.keyIdentifier == 'Enter') | 50 if (e.keyIdentifier == 'Enter') |
50 e.stopPropagation(); | 51 e.stopPropagation(); |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
135 CookiesView.loadChildren = function(args) { | 136 CookiesView.loadChildren = function(args) { |
136 $('cookies-list').loadChildren(args[0], args[1]); | 137 $('cookies-list').loadChildren(args[0], args[1]); |
137 }; | 138 }; |
138 | 139 |
139 // Export | 140 // Export |
140 return { | 141 return { |
141 CookiesView: CookiesView | 142 CookiesView: CookiesView |
142 }; | 143 }; |
143 | 144 |
144 }); | 145 }); |
OLD | NEW |