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

Side by Side Diff: chrome/browser/resources/options2/startup_overlay.js

Issue 9168026: Move autocomplete_list.js from options and options2 to shared/js (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: copyright year 2012 Created 8 years, 11 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 cr.define('options', function() { 5 cr.define('options', function() {
6 var OptionsPage = options.OptionsPage; 6 var OptionsPage = options.OptionsPage;
7 var ArrayDataModel = cr.ui.ArrayDataModel; 7 var ArrayDataModel = cr.ui.ArrayDataModel;
8 8
9 const localStrings = new LocalStrings(); 9 const localStrings = new LocalStrings();
10 10
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 57
58 $('startup-overlay-ok').onclick = function() { 58 $('startup-overlay-ok').onclick = function() {
59 OptionsPage.closeOverlay(); 59 OptionsPage.closeOverlay();
60 } 60 }
61 61
62 // Initialize control enabled states. 62 // Initialize control enabled states.
63 Preferences.getInstance().addEventListener( 63 Preferences.getInstance().addEventListener(
64 this.startup_pages_pref_.name, 64 this.startup_pages_pref_.name,
65 this.handleStartupPageListChange_.bind(this)); 65 this.handleStartupPageListChange_.bind(this));
66 66
67 var suggestionList = new options.AutocompleteList(); 67 var suggestionList = new cr.ui.AutocompleteList();
68 suggestionList.autoExpands = true; 68 suggestionList.autoExpands = true;
69 suggestionList.suggestionUpdateRequestCallback = 69 suggestionList.suggestionUpdateRequestCallback =
70 this.requestAutocompleteSuggestions_.bind(this); 70 this.requestAutocompleteSuggestions_.bind(this);
71 $('startup-overlay').appendChild(suggestionList); 71 $('startup-overlay').appendChild(suggestionList);
72 this.autocompleteList_ = suggestionList; 72 this.autocompleteList_ = suggestionList;
73 startupPagesList.autocompleteList = suggestionList; 73 startupPagesList.autocompleteList = suggestionList;
74 }, 74 },
75 75
76 /** 76 /**
77 * Updates the startup pages list with the given entries. 77 * Updates the startup pages list with the given entries.
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 StartupOverlay[name] = function(value) { 134 StartupOverlay[name] = function(value) {
135 StartupOverlay.getInstance()[name + '_'](value); 135 StartupOverlay.getInstance()[name + '_'](value);
136 }; 136 };
137 }); 137 });
138 138
139 // Export 139 // Export
140 return { 140 return {
141 StartupOverlay: StartupOverlay 141 StartupOverlay: StartupOverlay
142 }; 142 };
143 }); 143 });
OLDNEW
« no previous file with comments | « chrome/browser/resources/options2/options_bundle.js ('k') | chrome/browser/resources/shared/js/cr/ui/autocomplete_list.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698