OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "chrome/browser/geolocation/chrome_geolocation_permission_context_facto
ry.h" |
| 6 |
| 7 #include "chrome/common/pref_names.h" |
| 8 |
| 9 ChromeGeolocationPermissionContext* |
| 10 ChromeGeolocationPermissionContextFactory::Create(Profile* profile) { |
| 11 #if defined(OS_ANDROID) |
| 12 return new ChromeGeolocationPermissionContextAndroid(profile); |
| 13 #else |
| 14 return new ChromeGeolocationPermissionContext(profile); |
| 15 #endif |
| 16 } |
| 17 |
| 18 void ChromeGeolocationPermissionContextFactory::RegisterUserPrefs( |
| 19 PrefService* user_prefs) { |
| 20 #if defined(OS_ANDROID) |
| 21 user_prefs->RegisterBooleanPref(prefs::kGeolocationEnabled, |
| 22 true, |
| 23 PrefService::UNSYNCABLE_PREF); |
| 24 #endif |
| 25 } |
OLD | NEW |