| 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 /** | 5 /** |
| 6 * @fileoverview Oobe network screen implementation. | 6 * @fileoverview Oobe network screen implementation. |
| 7 */ | 7 */ |
| 8 | 8 |
| 9 login.createScreen('NetworkScreen', 'connect', function() { | 9 login.createScreen('NetworkScreen', 'connect', function() { |
| 10 var USER_ACTION_CONTINUE_BUTTON_CLICKED = 'continue'; | 10 var USER_ACTION_CONTINUE_BUTTON_CLICKED = 'continue'; |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 this.declareUserAction( | 65 this.declareUserAction( |
| 66 $('connect-debugging-features-link'), | 66 $('connect-debugging-features-link'), |
| 67 { action_id: USER_ACTION_CONNECT_DEBUGGING_FEATURES_CLICKED, | 67 { action_id: USER_ACTION_CONNECT_DEBUGGING_FEATURES_CLICKED, |
| 68 condition: function(event) { return event.keyCode == 32; }, | 68 condition: function(event) { return event.keyCode == 32; }, |
| 69 event: 'keyup' | 69 event: 'keyup' |
| 70 }); | 70 }); |
| 71 | 71 |
| 72 this.context.addObserver( | 72 this.context.addObserver( |
| 73 CONTEXT_KEY_INPUT_METHOD, | 73 CONTEXT_KEY_INPUT_METHOD, |
| 74 function(inputMethodId) { | 74 function(inputMethodId) { |
| 75 $('oobe-welcome-md').setSelectedKeyboard(inputMethodId); |
| 76 |
| 75 option = $('keyboard-select').querySelector( | 77 option = $('keyboard-select').querySelector( |
| 76 'option[value="' + inputMethodId + '"]'); | 78 'option[value="' + inputMethodId + '"]'); |
| 77 if (option) | 79 if (option) |
| 78 option.selected = true; | 80 option.selected = true; |
| 79 }); | 81 }); |
| 80 this.context.addObserver(CONTEXT_KEY_TIMEZONE, function(timezoneId) { | 82 this.context.addObserver(CONTEXT_KEY_TIMEZONE, function(timezoneId) { |
| 81 $('timezone-select').value = timezoneId; | 83 $('timezone-select').value = timezoneId; |
| 82 }); | 84 }); |
| 83 this.context.addObserver(CONTEXT_KEY_CONTINUE_BUTTON_ENABLED, | 85 this.context.addObserver(CONTEXT_KEY_CONTINUE_BUTTON_ENABLED, |
| 84 function(enabled) { | 86 function(enabled) { |
| (...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 197 var timezoneList = loadTimeData.getValue('timezoneList'); | 199 var timezoneList = loadTimeData.getValue('timezoneList'); |
| 198 welcomeScreen.timezones = timezoneList; | 200 welcomeScreen.timezones = timezoneList; |
| 199 | 201 |
| 200 welcomeScreen.highlightStrength = | 202 welcomeScreen.highlightStrength = |
| 201 loadTimeData.getValue('highlightStrength'); | 203 loadTimeData.getValue('highlightStrength'); |
| 202 } | 204 } |
| 203 }, | 205 }, |
| 204 }; | 206 }; |
| 205 }); | 207 }); |
| 206 | 208 |
| OLD | NEW |