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

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

Issue 6002015: Policy: generate boilerplate policy type and constant code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge with ToT Created 9 years, 11 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/configuration_policy_provider_delegate_win.h" 5 #include "chrome/browser/policy/configuration_policy_provider_delegate_win.h"
6 6
7 #include "base/string_number_conversions.h" 7 #include "base/string_number_conversions.h"
8 #include "base/utf_string_conversions.h" 8 #include "base/utf_string_conversions.h"
9 #include "base/win/registry.h" 9 #include "base/win/registry.h"
10 #include "chrome/common/policy_constants.h" 10 #include "policy/policy_constants.h"
11 11
12 using base::win::RegKey; 12 using base::win::RegKey;
13 13
14 namespace { 14 namespace {
15 15
16 bool ReadRegistryStringValue(RegKey* key, const string16& name, 16 bool ReadRegistryStringValue(RegKey* key, const string16& name,
17 string16* result) { 17 string16* result) {
18 DWORD value_size = 0; 18 DWORD value_size = 0;
19 DWORD key_type = 0; 19 DWORD key_type = 0;
20 scoped_array<uint8> buffer; 20 scoped_array<uint8> buffer;
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 ERROR_SUCCESS) { 144 ERROR_SUCCESS) {
145 if (policy_key.ReadValueDW(value_name.c_str(), &value) == ERROR_SUCCESS) { 145 if (policy_key.ReadValueDW(value_name.c_str(), &value) == ERROR_SUCCESS) {
146 *result = value; 146 *result = value;
147 return true; 147 return true;
148 } 148 }
149 } 149 }
150 return false; 150 return false;
151 } 151 }
152 152
153 } // namespace policy 153 } // namespace policy
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698