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 This file contains methods that allow to tweak | 6 * @fileoverview This file contains methods that allow to tweak |
7 * internal page UI based on the status of current user (owner/user/guest). | 7 * internal page UI based on the status of current user (owner/user/guest). |
8 * It is assumed that required data is passed via i18n strings | 8 * It is assumed that required data is passed via i18n strings |
9 * (using loadTimeData dictionary) that are filled with call to | 9 * (using loadTimeData dictionary) that are filled with call to |
10 * AddAccountUITweaksLocalizedValues in ui_account_tweaks.cc. | 10 * AddAccountUITweaksLocalizedValues in ui_account_tweaks.cc. |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 /** | 45 /** |
46 * @return {boolean} Whether we're currently in public session. | 46 * @return {boolean} Whether we're currently in public session. |
47 */ | 47 */ |
48 UIAccountTweaks.loggedInAsPublicAccount = function() { | 48 UIAccountTweaks.loggedInAsPublicAccount = function() { |
49 return loadTimeData.getBoolean('loggedInAsPublicAccount'); | 49 return loadTimeData.getBoolean('loggedInAsPublicAccount'); |
50 }; | 50 }; |
51 | 51 |
52 /** | 52 /** |
53 * @return {boolean} Whether we're currently in supervised user mode. | 53 * @return {boolean} Whether we're currently in supervised user mode. |
54 */ | 54 */ |
55 UIAccountTweaks.loggedInAsLocallyManagedUser = function() { | 55 UIAccountTweaks.loggedInAsSupervisedUser = function() { |
56 return loadTimeData.getBoolean('loggedInAsLocallyManagedUser'); | 56 return loadTimeData.getBoolean('loggedInAsSupervisedUser'); |
57 }; | 57 }; |
58 | 58 |
59 /** | 59 /** |
60 * Disables or hides some elements in specified type of session in ChromeOS. | 60 * Disables or hides some elements in specified type of session in ChromeOS. |
61 * All elements within given document with *sessionType*-visibility | 61 * All elements within given document with *sessionType*-visibility |
62 * attribute are either hidden (for *sessionType*-visibility="hidden") | 62 * attribute are either hidden (for *sessionType*-visibility="hidden") |
63 * or disabled (for *sessionType*-visibility="disabled"). | 63 * or disabled (for *sessionType*-visibility="disabled"). |
64 * | 64 * |
65 * @param {Document} document Document that should processed. | 65 * @param {Document} document Document that should processed. |
66 * @param {string} sessionType name of the session type processed. | 66 * @param {string} sessionType name of the session type processed. |
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
153 }; | 153 }; |
154 } | 154 } |
155 }; | 155 }; |
156 | 156 |
157 // Export | 157 // Export |
158 return { | 158 return { |
159 UIAccountTweaks: UIAccountTweaks | 159 UIAccountTweaks: UIAccountTweaks |
160 }; | 160 }; |
161 | 161 |
162 }); | 162 }); |
OLD | NEW |