Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(88)

Side by Side Diff: ui/webui/resources/js/chromeos/ui_account_tweaks.js

Issue 18197002: Remove the google drive option on the settings page for supervized user (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/ui/webui/chromeos/ui_account_tweaks.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 21 matching lines...) Expand all
32 }; 32 };
33 33
34 /** 34 /**
35 * @return {boolean} Whether we're currently in guest mode. 35 * @return {boolean} Whether we're currently in guest mode.
36 */ 36 */
37 UIAccountTweaks.loggedInAsGuest = function() { 37 UIAccountTweaks.loggedInAsGuest = function() {
38 return loadTimeData.getBoolean('loggedInAsGuest'); 38 return loadTimeData.getBoolean('loggedInAsGuest');
39 }; 39 };
40 40
41 /** 41 /**
42 * @return {boolean} Whether we're currently in supervised user mode.
43 */
44 UIAccountTweaks.loggedInAsLocallyManagedUser = function() {
45 return loadTimeData.getBoolean('loggedInAsLocallyManagedUser');
46 };
47
48 /**
42 * Disables or hides some elements in Guest mode in ChromeOS. 49 * Disables or hides some elements in Guest mode in ChromeOS.
43 * All elements within given document with guest-visibility 50 * All elements within given document with guest-visibility
44 * attribute are either hidden (for guest-visibility="hidden") 51 * attribute are either hidden (for guest-visibility="hidden")
45 * or disabled (for guest-visibility="disabled"). 52 * or disabled (for guest-visibility="disabled").
46 * 53 *
47 * @param {Document} document Document that should processed. 54 * @param {Document} document Document that should processed.
48 */ 55 */
49 UIAccountTweaks.applyGuestModeVisibility = function(document) { 56 UIAccountTweaks.applyGuestModeVisibility = function(document) {
50 if (!cr.isChromeOS || !UIAccountTweaks.loggedInAsGuest()) 57 if (!cr.isChromeOS || !UIAccountTweaks.loggedInAsGuest())
51 return; 58 return;
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
106 }; 113 };
107 } 114 }
108 }; 115 };
109 116
110 // Export 117 // Export
111 return { 118 return {
112 UIAccountTweaks: UIAccountTweaks 119 UIAccountTweaks: UIAccountTweaks
113 }; 120 };
114 121
115 }); 122 });
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/chromeos/ui_account_tweaks.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698