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/chromeos/keyboard_overlay.js

Issue 557633002: Add public API generation with cr.makePublic() and handle it in compiler pass (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@H_options_errors_3
Patch Set: fix bug with oobe Created 6 years, 3 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 6
7 /** 7 /**
8 * Auto-repeat delays (in ms) for the corresponding slider values, from 8 * Auto-repeat delays (in ms) for the corresponding slider values, from
9 * long to short. The values were chosen to provide a large range while giving 9 * long to short. The values were chosen to provide a large range while giving
10 * several options near the defaults. 10 * several options near the defaults.
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 154
155 assert(index != -1, 155 assert(index != -1,
156 'Failed to update ' + id + ' from pref with value ' + value); 156 'Failed to update ' + id + ' from pref with value ' + value);
157 } 157 }
158 158
159 $(id).value = index; 159 $(id).value = index;
160 }, 160 },
161 }; 161 };
162 162
163 // Forward public APIs to private implementations. 163 // Forward public APIs to private implementations.
164 [ 164 cr.makePublic(KeyboardOverlay, [
165 'showCapsLockOptions', 165 'showCapsLockOptions',
166 'showDiamondKeyOptions', 166 'showDiamondKeyOptions',
167 ].forEach(function(name) { 167 ]);
168 KeyboardOverlay[name] = function() {
169 var instance = KeyboardOverlay.getInstance();
170 return instance[name + '_'].apply(instance, arguments);
171 };
172 });
173 168
174 // Export 169 // Export
175 return { 170 return {
176 KeyboardOverlay: KeyboardOverlay 171 KeyboardOverlay: KeyboardOverlay
177 }; 172 };
178 }); 173 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698