| 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 cr.define('options', function() { | 5 cr.define('options', function() { |
| 6 | 6 |
| 7 var OptionsPage = options.OptionsPage; | 7 var OptionsPage = options.OptionsPage; |
| 8 var ArrayDataModel = cr.ui.ArrayDataModel; | 8 var ArrayDataModel = cr.ui.ArrayDataModel; |
| 9 | 9 |
| 10 /** | 10 /** |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 116 $('change-picture-button').onclick = function(event) { | 116 $('change-picture-button').onclick = function(event) { |
| 117 OptionsPage.navigateToPage('changePicture'); | 117 OptionsPage.navigateToPage('changePicture'); |
| 118 }; | 118 }; |
| 119 this.updateAccountPicture_(); | 119 this.updateAccountPicture_(); |
| 120 | 120 |
| 121 if (cr.commandLine && cr.commandLine.options['--bwsi']) { | 121 if (cr.commandLine && cr.commandLine.options['--bwsi']) { |
| 122 // Disable the screen lock checkbox and change-picture-button in | 122 // Disable the screen lock checkbox and change-picture-button in |
| 123 // guest mode. | 123 // guest mode. |
| 124 $('enable-screen-lock').disabled = true; | 124 $('enable-screen-lock').disabled = true; |
| 125 $('change-picture-button').disabled = true; | 125 $('change-picture-button').disabled = true; |
| 126 } else if (localStrings.getString('current_user_is_ephemeral') == |
| 127 'true') { |
| 128 // Disable the change-picture-button for ephemeral users. |
| 129 $('change-picture-button').disabled = true; |
| 126 } | 130 } |
| 127 } | 131 } |
| 128 | 132 |
| 129 if (PersonalOptions.disablePasswordManagement()) { | 133 if (PersonalOptions.disablePasswordManagement()) { |
| 130 // Disable the Password Manager in guest mode. | 134 // Disable the Password Manager in guest mode. |
| 131 $('passwords-offersave').disabled = true; | 135 $('passwords-offersave').disabled = true; |
| 132 $('passwords-neversave').disabled = true; | 136 $('passwords-neversave').disabled = true; |
| 133 $('passwords-offersave').value = false; | 137 $('passwords-offersave').value = false; |
| 134 $('passwords-neversave').value = true; | 138 $('passwords-neversave').value = true; |
| 135 $('manage-passwords').disabled = true; | 139 $('manage-passwords').disabled = true; |
| (...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 364 return instance[name + '_'].apply(instance, arguments); | 368 return instance[name + '_'].apply(instance, arguments); |
| 365 }; | 369 }; |
| 366 }); | 370 }); |
| 367 | 371 |
| 368 // Export | 372 // Export |
| 369 return { | 373 return { |
| 370 PersonalOptions: PersonalOptions | 374 PersonalOptions: PersonalOptions |
| 371 }; | 375 }; |
| 372 | 376 |
| 373 }); | 377 }); |
| OLD | NEW |