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

Unified Diff: chrome/browser/ui/webui/options/chromeos/accounts_options_handler.cc

Issue 7171018: User Settings on CrOS now shows the managed banner for enrolled devices. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Fixed comments. Created 9 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/ui/webui/options/chromeos/accounts_options_handler.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/options/chromeos/accounts_options_handler.cc
diff --git a/chrome/browser/ui/webui/options/chromeos/accounts_options_handler.cc b/chrome/browser/ui/webui/options/chromeos/accounts_options_handler.cc
index dcf14ab8fa8962af54cefceabe8d931cdbf77558..dde7bc625bada62a713e0c9bfe43a13e8dddbd2b 100644
--- a/chrome/browser/ui/webui/options/chromeos/accounts_options_handler.cc
+++ b/chrome/browser/ui/webui/options/chromeos/accounts_options_handler.cc
@@ -14,7 +14,7 @@
#include "chrome/browser/chromeos/login/user_manager.h"
#include "chrome/browser/chromeos/user_cros_settings_provider.h"
#include "chrome/browser/prefs/pref_service.h"
-#include "chrome/browser/ui/webui/options/options_managed_banner_handler.h"
+#include "chrome/browser/policy/browser_policy_connector.h"
#include "grit/generated_resources.h"
#include "ui/base/l10n/l10n_util.h"
@@ -68,8 +68,8 @@ void AccountsOptionsHandler::GetLocalizedValues(
UserManager::Get()->IsLoggedInAsGuest() ?
ASCIIToUTF16("true") : ASCIIToUTF16("false"));
localized_strings->SetString("whitelist_is_managed",
- g_browser_process->local_state()->IsManagedPreference(
- kAccountsPrefUsers) ? ASCIIToUTF16("true") : ASCIIToUTF16("false"));
+ g_browser_process->browser_policy_connector()->IsEnterpriseManaged() ?
+ ASCIIToUTF16("true") : ASCIIToUTF16("false"));
}
UserCrosSettingsProvider* AccountsOptionsHandler::users_settings() const {
@@ -115,12 +115,4 @@ void AccountsOptionsHandler::WhitelistExistingUsers(const ListValue* args) {
web_ui_->CallJavascriptFunction("AccountsOptions.addUsers", whitelist_users);
}
-void AccountsOptionsHandler::Initialize() {
- DCHECK(web_ui_);
- banner_handler_.reset(
- OptionsManagedBannerHandler::Create(web_ui_,
- ASCIIToUTF16("AccountsOptions"),
- OPTIONS_PAGE_ACCOUNTS));
-}
-
} // namespace chromeos
« no previous file with comments | « chrome/browser/ui/webui/options/chromeos/accounts_options_handler.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698