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

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

Issue 9403010: Add support for kiosk mode on the client. Make sure the settings are written in the lockbox. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressed comments and added more tests. Created 8 years, 10 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) 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 #include "chrome/browser/policy/browser_policy_connector.h" 5 #include "chrome/browser/policy/browser_policy_connector.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/file_path.h" 9 #include "base/file_path.h"
10 #include "base/path_service.h" 10 #include "base/path_service.h"
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
176 #if defined(OS_CHROMEOS) 176 #if defined(OS_CHROMEOS)
177 return install_attributes_.get() && install_attributes_->IsEnterpriseDevice(); 177 return install_attributes_.get() && install_attributes_->IsEnterpriseDevice();
178 #else 178 #else
179 return false; 179 return false;
180 #endif 180 #endif
181 } 181 }
182 182
183 EnterpriseInstallAttributes::LockResult 183 EnterpriseInstallAttributes::LockResult
184 BrowserPolicyConnector::LockDevice(const std::string& user) { 184 BrowserPolicyConnector::LockDevice(const std::string& user) {
185 #if defined(OS_CHROMEOS) 185 #if defined(OS_CHROMEOS)
186 if (install_attributes_.get()) 186 if (install_attributes_.get()) {
187 return install_attributes_->LockDevice(user); 187 return install_attributes_->LockDevice(user,
188 device_data_store_->device_mode(),
189 device_data_store_->device_id());
190 }
188 #endif 191 #endif
189 192
190 return EnterpriseInstallAttributes::LOCK_BACKEND_ERROR; 193 return EnterpriseInstallAttributes::LOCK_BACKEND_ERROR;
191 } 194 }
192 195
193 // static 196 // static
194 std::string BrowserPolicyConnector::GetSerialNumber() { 197 std::string BrowserPolicyConnector::GetSerialNumber() {
195 std::string serial_number; 198 std::string serial_number;
196 #if defined(OS_CHROMEOS) 199 #if defined(OS_CHROMEOS)
197 chromeos::system::StatisticsProvider* provider = 200 chromeos::system::StatisticsProvider* provider =
(...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after
510 config_dir_path.Append(FILE_PATH_LITERAL("recommended"))); 513 config_dir_path.Append(FILE_PATH_LITERAL("recommended")));
511 } else { 514 } else {
512 return NULL; 515 return NULL;
513 } 516 }
514 #else 517 #else
515 return NULL; 518 return NULL;
516 #endif 519 #endif
517 } 520 }
518 521
519 } // namespace policy 522 } // namespace policy
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/policy/cloud_policy_data_store.h » ('j') | chrome/browser/policy/device_token_fetcher.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698