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 var OptionsPage = options.OptionsPage; | 6 var OptionsPage = options.OptionsPage; |
7 var Page = cr.ui.pageManager.Page; | 7 var Page = cr.ui.pageManager.Page; |
8 var PageManager = cr.ui.pageManager.PageManager; | 8 var PageManager = cr.ui.pageManager.PageManager; |
9 var ArrayDataModel = cr.ui.ArrayDataModel; | 9 var ArrayDataModel = cr.ui.ArrayDataModel; |
10 var RepeatingButton = cr.ui.RepeatingButton; | 10 var RepeatingButton = cr.ui.RepeatingButton; |
(...skipping 1024 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1035 }, | 1035 }, |
1036 | 1036 |
1037 /** | 1037 /** |
1038 * Update the UI depending on whether the current profile has a pairing for | 1038 * Update the UI depending on whether the current profile has a pairing for |
1039 * Easy Unlock. | 1039 * Easy Unlock. |
1040 * @param {boolean} hasPairing True if the current profile has a pairing. | 1040 * @param {boolean} hasPairing True if the current profile has a pairing. |
1041 */ | 1041 */ |
1042 updateEasyUnlock_: function(hasPairing) { | 1042 updateEasyUnlock_: function(hasPairing) { |
1043 $('easy-unlock-setup').hidden = hasPairing; | 1043 $('easy-unlock-setup').hidden = hasPairing; |
1044 $('easy-unlock-enable').hidden = !hasPairing; | 1044 $('easy-unlock-enable').hidden = !hasPairing; |
| 1045 if (!hasPairing && EasyUnlockTurnOffOverlay.getInstance().visible) { |
| 1046 EasyUnlockTurnOffOverlay.dismiss(); |
| 1047 } |
1045 }, | 1048 }, |
1046 | 1049 |
1047 /** | 1050 /** |
1048 * Update the UI depending on whether the current profile manages any | 1051 * Update the UI depending on whether the current profile manages any |
1049 * supervised users. | 1052 * supervised users. |
1050 * @param {boolean} show True if the current profile manages any supervised | 1053 * @param {boolean} show True if the current profile manages any supervised |
1051 * users. | 1054 * users. |
1052 */ | 1055 */ |
1053 updateManagesSupervisedUsers_: function(show) { | 1056 updateManagesSupervisedUsers_: function(show) { |
1054 $('profiles-supervised-dashboard-tip').hidden = !show; | 1057 $('profiles-supervised-dashboard-tip').hidden = !show; |
(...skipping 901 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1956 BrowserOptions.getLoggedInUsername = function() { | 1959 BrowserOptions.getLoggedInUsername = function() { |
1957 return BrowserOptions.getInstance().username_; | 1960 return BrowserOptions.getInstance().username_; |
1958 }; | 1961 }; |
1959 } | 1962 } |
1960 | 1963 |
1961 // Export | 1964 // Export |
1962 return { | 1965 return { |
1963 BrowserOptions: BrowserOptions | 1966 BrowserOptions: BrowserOptions |
1964 }; | 1967 }; |
1965 }); | 1968 }); |
OLD | NEW |