summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorxiyuan@chromium.org <xiyuan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-11-03 23:38:39 +0000
committerxiyuan@chromium.org <xiyuan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-11-03 23:38:39 +0000
commit7127ee880fa572a61d67d548bd9e30b0eb74f0b1 (patch)
tree33493d2c3d416392455d8042124595af4afd1196
parentea812b8f47c0b2424b32a07b760a2d871303a9bc (diff)
downloadchromium_src-7127ee880fa572a61d67d548bd9e30b0eb74f0b1.zip
chromium_src-7127ee880fa572a61d67d548bd9e30b0eb74f0b1.tar.gz
chromium_src-7127ee880fa572a61d67d548bd9e30b0eb74f0b1.tar.bz2
[ChromeOS] Hardcoded screen lock enabled for google.com users.
This is a sad change that we have to hard code this. :( And hopefully, we will get the enterprise feature complete soon and could remove this hack. BUG=none. TEST=Verify that screen lock is enabled for google.com logins. Review URL: http://codereview.chromium.org/4347001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@64992 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/browser/chromeos/login/login_utils.cc11
1 files changed, 10 insertions, 1 deletions
diff --git a/chrome/browser/chromeos/login/login_utils.cc b/chrome/browser/chromeos/login/login_utils.cc
index 8136645..518358d 100644
--- a/chrome/browser/chromeos/login/login_utils.cc
+++ b/chrome/browser/chromeos/login/login_utils.cc
@@ -51,7 +51,6 @@ namespace chromeos {
namespace {
-
// Prefix for Auth token received from ClientLogin request.
const char kAuthPrefix[] = "Auth=";
// Suffix for Auth token received from ClientLogin request.
@@ -237,6 +236,16 @@ void LoginUtilsImpl::CompleteLogin(
btl->AddLoginTimeMarker("IMESTarted", false);
}
}
+
+ // We suck. This is a hack since we do not have the enterprise feature
+ // done yet to pull down policies from the domain admin. We'll take this
+ // out when we get that done properly.
+ // TODO(xiyuan): Remove this once enterprise feature is ready.
+ if (EndsWith(username, "@google.com", true)) {
+ PrefService* pref_service = profile->GetPrefs();
+ pref_service->SetBoolean(prefs::kEnableScreenLock, true);
+ }
+
DoBrowserLaunch(profile);
}