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

Side by Side Diff: chrome/browser/policy/enterprise_install_attributes.cc

Issue 7941008: Cosmetic cleanups in chrome/browser/policy/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Upload was broken? Created 9 years, 3 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
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #include "chrome/browser/policy/enterprise_install_attributes.h" 5 #include "chrome/browser/policy/enterprise_install_attributes.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "chrome/browser/chromeos/cros/cryptohome_library.h" 8 #include "chrome/browser/chromeos/cros/cryptohome_library.h"
9 9
10 static const char kAttrEnterpriseOwned[] = "enterprise.owned"; 10 namespace {
11 static const char kAttrEnterpriseUser[] = "enterprise.user"; 11
12 const char kAttrEnterpriseOwned[] = "enterprise.owned";
13 const char kAttrEnterpriseUser[] = "enterprise.user";
14
15 } // namespace
12 16
13 namespace policy { 17 namespace policy {
14 18
15 EnterpriseInstallAttributes::EnterpriseInstallAttributes( 19 EnterpriseInstallAttributes::EnterpriseInstallAttributes(
16 chromeos::CryptohomeLibrary* cryptohome) 20 chromeos::CryptohomeLibrary* cryptohome)
17 : cryptohome_(cryptohome), 21 : cryptohome_(cryptohome),
18 device_locked_(false) {} 22 device_locked_(false) {}
19 23
20 EnterpriseInstallAttributes::LockResult EnterpriseInstallAttributes::LockDevice( 24 EnterpriseInstallAttributes::LockResult EnterpriseInstallAttributes::LockDevice(
21 const std::string& user) { 25 const std::string& user) {
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 cryptohome_->InstallAttributesGet(kAttrEnterpriseUser, 107 cryptohome_->InstallAttributesGet(kAttrEnterpriseUser,
104 &enterprise_user) && 108 &enterprise_user) &&
105 enterprise_owned == "true" && 109 enterprise_owned == "true" &&
106 !enterprise_user.empty()) { 110 !enterprise_user.empty()) {
107 registration_user_ = enterprise_user; 111 registration_user_ = enterprise_user;
108 } 112 }
109 } 113 }
110 } 114 }
111 115
112 } // namespace policy 116 } // namespace policy
OLDNEW
« no previous file with comments | « chrome/browser/policy/dummy_configuration_policy_provider.h ('k') | chrome/browser/policy/file_based_policy_loader.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698