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

Side by Side Diff: chrome/browser/resources/options/search_engine_manager.js

Issue 15805002: Modify extension omnibox keywords to be user-configurable (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Test updates Created 7 years, 6 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 (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 /** @const */ var OptionsPage = options.OptionsPage; 6 /** @const */ var OptionsPage = options.OptionsPage;
7 /** @const */ var ArrayDataModel = cr.ui.ArrayDataModel; 7 /** @const */ var ArrayDataModel = cr.ui.ArrayDataModel;
8 8
9 /** 9 /**
10 * Encapsulated handling of search engine management page. 10 * Encapsulated handling of search engine management page.
(...skipping 19 matching lines...) Expand all
30 30
31 /** 31 /**
32 * List for other search engine options. 32 * List for other search engine options.
33 * @private 33 * @private
34 */ 34 */
35 othersList_: null, 35 othersList_: null,
36 36
37 /** 37 /**
38 * List for extension keywords. 38 * List for extension keywords.
39 * @private 39 * @private
40 extensionList_ : null, 40 */
41 extensionList_: null,
41 42
42 /** inheritDoc */ 43 /** inheritDoc */
43 initializePage: function() { 44 initializePage: function() {
44 OptionsPage.prototype.initializePage.call(this); 45 OptionsPage.prototype.initializePage.call(this);
45 46
46 this.defaultsList_ = $('default-search-engine-list'); 47 this.defaultsList_ = $('default-search-engine-list');
47 this.setUpList_(this.defaultsList_); 48 this.setUpList_(this.defaultsList_);
48 49
49 this.othersList_ = $('other-search-engine-list'); 50 this.othersList_ = $('other-search-engine-list');
50 this.setUpList_(this.othersList_); 51 this.setUpList_(this.othersList_);
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 106
106 SearchEngineManager.updateSearchEngineList = function(defaultEngines, 107 SearchEngineManager.updateSearchEngineList = function(defaultEngines,
107 otherEngines, 108 otherEngines,
108 keywords) { 109 keywords) {
109 SearchEngineManager.getInstance().updateSearchEngineList_(defaultEngines, 110 SearchEngineManager.getInstance().updateSearchEngineList_(defaultEngines,
110 otherEngines, 111 otherEngines,
111 keywords); 112 keywords);
112 }; 113 };
113 114
114 SearchEngineManager.validityCheckCallback = function(validity, modelIndex) { 115 SearchEngineManager.validityCheckCallback = function(validity, modelIndex) {
115 // Forward to both lists; the one without a matching modelIndex will ignore 116 // Forward to all lists; those without a matching modelIndex will ignore it.
116 // it.
117 SearchEngineManager.getInstance().defaultsList_.validationComplete( 117 SearchEngineManager.getInstance().defaultsList_.validationComplete(
118 validity, modelIndex); 118 validity, modelIndex);
119 SearchEngineManager.getInstance().othersList_.validationComplete( 119 SearchEngineManager.getInstance().othersList_.validationComplete(
120 validity, modelIndex); 120 validity, modelIndex);
121 SearchEngineManager.getInstance().extensionList_.validationComplete(
122 validity, modelIndex);
121 }; 123 };
122 124
123 // Export 125 // Export
124 return { 126 return {
125 SearchEngineManager: SearchEngineManager 127 SearchEngineManager: SearchEngineManager
126 }; 128 };
127 129
128 }); 130 });
129 131
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698