OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 Page = cr.ui.pageManager.Page; | 6 var Page = cr.ui.pageManager.Page; |
7 var PageManager = cr.ui.pageManager.PageManager; | 7 var PageManager = cr.ui.pageManager.PageManager; |
8 var ArrayDataModel = cr.ui.ArrayDataModel; | 8 var ArrayDataModel = cr.ui.ArrayDataModel; |
9 | 9 |
10 /** | 10 /** |
(...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
229 * @private | 229 * @private |
230 */ | 230 */ |
231 onSuccess_: function() { | 231 onSuccess_: function() { |
232 this.updateImportInProgress_(false); | 232 this.updateImportInProgress_(false); |
233 options.SupervisedUserListData.resetPromise(); | 233 options.SupervisedUserListData.resetPromise(); |
234 PageManager.closeAllOverlays(); | 234 PageManager.closeAllOverlays(); |
235 }, | 235 }, |
236 }; | 236 }; |
237 | 237 |
238 // Forward public APIs to private implementations. | 238 // Forward public APIs to private implementations. |
239 cr.makePublic(SupervisedUserImportOverlay, [ | 239 [ |
240 'onSuccess', | 240 'onSuccess', |
241 ]); | 241 ].forEach(function(name) { |
| 242 SupervisedUserImportOverlay[name] = function() { |
| 243 var instance = SupervisedUserImportOverlay.getInstance(); |
| 244 return instance[name + '_'].apply(instance, arguments); |
| 245 }; |
| 246 }); |
242 | 247 |
243 // Export | 248 // Export |
244 return { | 249 return { |
245 SupervisedUserImportOverlay: SupervisedUserImportOverlay, | 250 SupervisedUserImportOverlay: SupervisedUserImportOverlay, |
246 }; | 251 }; |
247 }); | 252 }); |
OLD | NEW |