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

Side by Side Diff: chrome/browser/chromeos/login/signed_settings.cc

Issue 8168010: PART4: Removed the owner cache special handling from UserCrosSettingsProvider. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 2 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 | « no previous file | chrome/browser/chromeos/login/user_manager.cc » ('j') | 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) 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/chromeos/login/signed_settings.h" 5 #include "chrome/browser/chromeos/login/signed_settings.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 345 matching lines...) Expand 10 before | Expand all | Expand 10 after
356 } else if (prop == kAccountsPrefUsers) { 356 } else if (prop == kAccountsPrefUsers) {
357 em::UserWhitelistProto* whitelist_proto = pol.mutable_user_whitelist(); 357 em::UserWhitelistProto* whitelist_proto = pol.mutable_user_whitelist();
358 whitelist_proto->clear_user_whitelist(); 358 whitelist_proto->clear_user_whitelist();
359 const base::ListValue& users = static_cast<const base::ListValue&>(value); 359 const base::ListValue& users = static_cast<const base::ListValue&>(value);
360 for (base::ListValue::const_iterator i = users.begin(); 360 for (base::ListValue::const_iterator i = users.begin();
361 i != users.end(); ++i) { 361 i != users.end(); ++i) {
362 std::string email; 362 std::string email;
363 if ((*i)->GetAsString(&email)) 363 if ((*i)->GetAsString(&email))
364 whitelist_proto->add_user_whitelist(email.c_str()); 364 whitelist_proto->add_user_whitelist(email.c_str());
365 } 365 }
366 } else if (prop == kDeviceOwner) {
367 // We don't serialize this one to the policy blob.
Mattias Nissler (ping if slow) 2011/10/07 13:46:52 It's actually good to make it a NOTREACHED(), do y
pastarmovj 2011/10/13 12:00:41 Actually it is not NOTREACHED() it will be called
366 } else { 368 } else {
367 NOTREACHED(); 369 NOTREACHED();
368 } 370 }
369 poldata->set_policy_value(pol.SerializeAsString()); 371 poldata->set_policy_value(pol.SerializeAsString());
370 } 372 }
371 373
372 void StorePropertyOp::PerformCallback(SignedSettings::ReturnCode code, 374 void StorePropertyOp::PerformCallback(SignedSettings::ReturnCode code,
373 bool value) { 375 bool value) {
374 d_->OnSettingsOpCompleted(code, value); 376 d_->OnSettingsOpCompleted(code, value);
375 } 377 }
(...skipping 326 matching lines...) Expand 10 before | Expand all | Expand 10 after
702 sig.assign(sig_ptr, sig_ptr + policy_.policy_data_signature().length()); 704 sig.assign(sig_ptr, sig_ptr + policy_.policy_data_signature().length());
703 service_->StartVerifyAttempt(policy_.policy_data(), sig, this); 705 service_->StartVerifyAttempt(policy_.policy_data(), sig, this);
704 } 706 }
705 707
706 void RetrievePolicyOp::PerformCallback(SignedSettings::ReturnCode code, 708 void RetrievePolicyOp::PerformCallback(SignedSettings::ReturnCode code,
707 const em::PolicyFetchResponse& value) { 709 const em::PolicyFetchResponse& value) {
708 d_->OnSettingsOpCompleted(code, value); 710 d_->OnSettingsOpCompleted(code, value);
709 } 711 }
710 712
711 } // namespace chromeos 713 } // namespace chromeos
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/chromeos/login/user_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698