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

Side by Side Diff: ios/chrome/browser/prefs/browser_prefs.mm

Issue 2643723004: Add Desktop iOS promotion logging to chrome ios app. (Closed)
Patch Set: add histogram Created 3 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "ios/chrome/browser/prefs/browser_prefs.h" 5 #include "ios/chrome/browser/prefs/browser_prefs.h"
6 6
7 #include "components/autofill/core/browser/autofill_manager.h" 7 #include "components/autofill/core/browser/autofill_manager.h"
8 #include "components/browsing_data/core/pref_names.h" 8 #include "components/browsing_data/core/pref_names.h"
9 #include "components/content_settings/core/browser/host_content_settings_map.h" 9 #include "components/content_settings/core/browser/host_content_settings_map.h"
10 #include "components/dom_distiller/core/distilled_page_prefs.h" 10 #include "components/dom_distiller/core/distilled_page_prefs.h"
(...skipping 18 matching lines...) Expand all
29 #include "components/signin/core/common/signin_pref_names.h" 29 #include "components/signin/core/common/signin_pref_names.h"
30 #include "components/ssl_config/ssl_config_service_manager.h" 30 #include "components/ssl_config/ssl_config_service_manager.h"
31 #include "components/strings/grit/components_locale_settings.h" 31 #include "components/strings/grit/components_locale_settings.h"
32 #include "components/sync/base/sync_prefs.h" 32 #include "components/sync/base/sync_prefs.h"
33 #include "components/translate/core/browser/translate_prefs.h" 33 #include "components/translate/core/browser/translate_prefs.h"
34 #include "components/translate/core/common/translate_pref_names.h" 34 #include "components/translate/core/common/translate_pref_names.h"
35 #include "components/update_client/update_client.h" 35 #include "components/update_client/update_client.h"
36 #include "components/variations/service/variations_service.h" 36 #include "components/variations/service/variations_service.h"
37 #include "components/web_resource/web_resource_pref_names.h" 37 #include "components/web_resource/web_resource_pref_names.h"
38 #include "ios/chrome/browser/browser_state/browser_state_info_cache.h" 38 #include "ios/chrome/browser/browser_state/browser_state_info_cache.h"
39 #include "ios/chrome/browser/desktop_promotion/desktop_promotion_prefs.h"
39 #include "ios/chrome/browser/first_run/first_run.h" 40 #include "ios/chrome/browser/first_run/first_run.h"
40 #import "ios/chrome/browser/geolocation/omnibox_geolocation_local_state.h" 41 #import "ios/chrome/browser/geolocation/omnibox_geolocation_local_state.h"
41 #import "ios/chrome/browser/memory/memory_debugger_manager.h" 42 #import "ios/chrome/browser/memory/memory_debugger_manager.h"
42 #import "ios/chrome/browser/metrics/ios_chrome_metrics_service_client.h" 43 #import "ios/chrome/browser/metrics/ios_chrome_metrics_service_client.h"
43 #include "ios/chrome/browser/net/http_server_properties_manager_factory.h" 44 #include "ios/chrome/browser/net/http_server_properties_manager_factory.h"
44 #include "ios/chrome/browser/notification_promo.h" 45 #include "ios/chrome/browser/notification_promo.h"
45 #include "ios/chrome/browser/physical_web/physical_web_prefs_registration.h" 46 #include "ios/chrome/browser/physical_web/physical_web_prefs_registration.h"
46 #include "ios/chrome/browser/pref_names.h" 47 #include "ios/chrome/browser/pref_names.h"
47 #include "ios/chrome/browser/signin/signin_manager_factory.h" 48 #include "ios/chrome/browser/signin/signin_manager_factory.h"
48 #import "ios/chrome/browser/ui/bookmarks/bookmark_interaction_controller.h" 49 #import "ios/chrome/browser/ui/bookmarks/bookmark_interaction_controller.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 registry->RegisterStringPref(prefs::kApplicationLocale, std::string()); 82 registry->RegisterStringPref(prefs::kApplicationLocale, std::string());
82 registry->RegisterBooleanPref(prefs::kEulaAccepted, false); 83 registry->RegisterBooleanPref(prefs::kEulaAccepted, false);
83 registry->RegisterBooleanPref(metrics::prefs::kMetricsReportingEnabled, 84 registry->RegisterBooleanPref(metrics::prefs::kMetricsReportingEnabled,
84 false); 85 false);
85 registry->RegisterBooleanPref(prefs::kLastSessionExitedCleanly, true); 86 registry->RegisterBooleanPref(prefs::kLastSessionExitedCleanly, true);
86 registry->RegisterBooleanPref(prefs::kMetricsReportingWifiOnly, true); 87 registry->RegisterBooleanPref(prefs::kMetricsReportingWifiOnly, true);
87 } 88 }
88 89
89 void RegisterBrowserStatePrefs(user_prefs::PrefRegistrySyncable* registry) { 90 void RegisterBrowserStatePrefs(user_prefs::PrefRegistrySyncable* registry) {
90 autofill::AutofillManager::RegisterProfilePrefs(registry); 91 autofill::AutofillManager::RegisterProfilePrefs(registry);
92 desktop_ios_promotion::RegisterDesktopPromotionUserPrefs(registry);
91 dom_distiller::DistilledPagePrefs::RegisterProfilePrefs(registry); 93 dom_distiller::DistilledPagePrefs::RegisterProfilePrefs(registry);
92 FirstRun::RegisterProfilePrefs(registry); 94 FirstRun::RegisterProfilePrefs(registry);
93 gcm::GCMChannelStatusSyncer::RegisterProfilePrefs(registry); 95 gcm::GCMChannelStatusSyncer::RegisterProfilePrefs(registry);
94 HostContentSettingsMap::RegisterProfilePrefs(registry); 96 HostContentSettingsMap::RegisterProfilePrefs(registry);
95 HttpServerPropertiesManagerFactory::RegisterProfilePrefs(registry); 97 HttpServerPropertiesManagerFactory::RegisterProfilePrefs(registry);
96 ntp_snippets::BookmarkSuggestionsProvider::RegisterProfilePrefs(registry); 98 ntp_snippets::BookmarkSuggestionsProvider::RegisterProfilePrefs(registry);
97 ntp_snippets::ContentSuggestionsService::RegisterProfilePrefs(registry); 99 ntp_snippets::ContentSuggestionsService::RegisterProfilePrefs(registry);
98 ntp_snippets::RemoteSuggestionsProviderImpl::RegisterProfilePrefs(registry); 100 ntp_snippets::RemoteSuggestionsProviderImpl::RegisterProfilePrefs(registry);
99 ntp_snippets::SchedulingRemoteSuggestionsProvider::RegisterProfilePrefs( 101 ntp_snippets::SchedulingRemoteSuggestionsProvider::RegisterProfilePrefs(
100 registry); 102 registry);
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
155 } 157 }
156 158
157 // This method should be periodically pruned of year+ old migrations. 159 // This method should be periodically pruned of year+ old migrations.
158 void MigrateObsoleteBrowserStatePrefs(PrefService* prefs) { 160 void MigrateObsoleteBrowserStatePrefs(PrefService* prefs) {
159 // Added 07/2014. 161 // Added 07/2014.
160 translate::TranslatePrefs::MigrateUserPrefs(prefs, prefs::kAcceptLanguages); 162 translate::TranslatePrefs::MigrateUserPrefs(prefs, prefs::kAcceptLanguages);
161 163
162 // Added 08/2015. 164 // Added 08/2015.
163 prefs->ClearPref(::prefs::kSigninSharedAuthenticationUserId); 165 prefs->ClearPref(::prefs::kSigninSharedAuthenticationUserId);
164 } 166 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698