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

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

Issue 155923002: Add a platform policy provider for Android. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review Created 6 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
« no previous file with comments | « no previous file | components/components_tests.gyp » ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/chrome_browser_policy_connector.h" 5 #include "chrome/browser/policy/chrome_browser_policy_connector.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 16 matching lines...) Expand all
27 #include "policy/policy_constants.h" 27 #include "policy/policy_constants.h"
28 28
29 #if defined(OS_WIN) 29 #if defined(OS_WIN)
30 #include "components/policy/core/common/policy_loader_win.h" 30 #include "components/policy/core/common/policy_loader_win.h"
31 #elif defined(OS_MACOSX) 31 #elif defined(OS_MACOSX)
32 #include <CoreFoundation/CoreFoundation.h> 32 #include <CoreFoundation/CoreFoundation.h>
33 #include "components/policy/core/common/policy_loader_mac.h" 33 #include "components/policy/core/common/policy_loader_mac.h"
34 #include "components/policy/core/common/preferences_mac.h" 34 #include "components/policy/core/common/preferences_mac.h"
35 #elif defined(OS_POSIX) && !defined(OS_ANDROID) 35 #elif defined(OS_POSIX) && !defined(OS_ANDROID)
36 #include "components/policy/core/common/config_dir_policy_loader.h" 36 #include "components/policy/core/common/config_dir_policy_loader.h"
37 #elif defined(OS_ANDROID)
38 #include "components/policy/core/common/policy_provider_android.h"
37 #endif 39 #endif
38 40
39 #if defined(OS_CHROMEOS) 41 #if defined(OS_CHROMEOS)
40 #include "chromeos/system/statistics_provider.h" 42 #include "chromeos/system/statistics_provider.h"
41 #endif 43 #endif
42 44
43 using content::BrowserThread; 45 using content::BrowserThread;
44 46
45 namespace policy { 47 namespace policy {
46 48
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 base::FilePath config_dir_path; 176 base::FilePath config_dir_path;
175 if (PathService::Get(chrome::DIR_POLICY_FILES, &config_dir_path)) { 177 if (PathService::Get(chrome::DIR_POLICY_FILES, &config_dir_path)) {
176 scoped_ptr<AsyncPolicyLoader> loader(new ConfigDirPolicyLoader( 178 scoped_ptr<AsyncPolicyLoader> loader(new ConfigDirPolicyLoader(
177 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::FILE), 179 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::FILE),
178 config_dir_path, 180 config_dir_path,
179 POLICY_SCOPE_MACHINE)); 181 POLICY_SCOPE_MACHINE));
180 return new AsyncPolicyProvider(GetSchemaRegistry(), loader.Pass()); 182 return new AsyncPolicyProvider(GetSchemaRegistry(), loader.Pass());
181 } else { 183 } else {
182 return NULL; 184 return NULL;
183 } 185 }
186 #elif defined(OS_ANDROID)
187 return new PolicyProviderAndroid();
184 #else 188 #else
185 return NULL; 189 return NULL;
186 #endif 190 #endif
187 } 191 }
188 192
189 } // namespace policy 193 } // namespace policy
OLDNEW
« no previous file with comments | « no previous file | components/components_tests.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698