OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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/chrome_browser_main.h" | 5 #include "chrome/browser/chrome_browser_main.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
107 #include "components/device_event_log/device_event_log.h" | 107 #include "components/device_event_log/device_event_log.h" |
108 #include "components/flags_ui/pref_service_flags_storage.h" | 108 #include "components/flags_ui/pref_service_flags_storage.h" |
109 #include "components/google/core/browser/google_util.h" | 109 #include "components/google/core/browser/google_util.h" |
110 #include "components/language_usage_metrics/language_usage_metrics.h" | 110 #include "components/language_usage_metrics/language_usage_metrics.h" |
111 #include "components/metrics/call_stack_profile_metrics_provider.h" | 111 #include "components/metrics/call_stack_profile_metrics_provider.h" |
112 #include "components/metrics/metrics_service.h" | 112 #include "components/metrics/metrics_service.h" |
113 #include "components/metrics/profiler/content/content_tracking_synchronizer_dele
gate.h" | 113 #include "components/metrics/profiler/content/content_tracking_synchronizer_dele
gate.h" |
114 #include "components/metrics/profiler/tracking_synchronizer.h" | 114 #include "components/metrics/profiler/tracking_synchronizer.h" |
115 #include "components/metrics_services_manager/metrics_services_manager.h" | 115 #include "components/metrics_services_manager/metrics_services_manager.h" |
116 #include "components/nacl/browser/nacl_browser.h" | 116 #include "components/nacl/browser/nacl_browser.h" |
| 117 #include "components/password_manager/core/browser/password_manager_util.h" |
117 #include "components/prefs/json_pref_store.h" | 118 #include "components/prefs/json_pref_store.h" |
118 #include "components/prefs/pref_registry_simple.h" | 119 #include "components/prefs/pref_registry_simple.h" |
119 #include "components/prefs/pref_service.h" | 120 #include "components/prefs/pref_service.h" |
120 #include "components/prefs/pref_value_store.h" | 121 #include "components/prefs/pref_value_store.h" |
121 #include "components/prefs/scoped_user_pref_update.h" | 122 #include "components/prefs/scoped_user_pref_update.h" |
122 #include "components/rappor/rappor_service.h" | 123 #include "components/rappor/rappor_service.h" |
123 #include "components/signin/core/common/profile_management_switches.h" | 124 #include "components/signin/core/common/profile_management_switches.h" |
124 #include "components/startup_metric_utils/browser/startup_metric_utils.h" | 125 #include "components/startup_metric_utils/browser/startup_metric_utils.h" |
125 #include "components/tracing/tracing_switches.h" | 126 #include "components/tracing/tracing_switches.h" |
126 #include "components/translate/content/browser/browser_cld_utils.h" | 127 #include "components/translate/content/browser/browser_cld_utils.h" |
(...skipping 580 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
707 scoped_ptr<base::FeatureList> feature_list(new base::FeatureList); | 708 scoped_ptr<base::FeatureList> feature_list(new base::FeatureList); |
708 feature_list->InitializeFromCommandLine( | 709 feature_list->InitializeFromCommandLine( |
709 command_line->GetSwitchValueASCII(switches::kEnableFeatures), | 710 command_line->GetSwitchValueASCII(switches::kEnableFeatures), |
710 command_line->GetSwitchValueASCII(switches::kDisableFeatures)); | 711 command_line->GetSwitchValueASCII(switches::kDisableFeatures)); |
711 | 712 |
712 #if defined(FIELDTRIAL_TESTING_ENABLED) | 713 #if defined(FIELDTRIAL_TESTING_ENABLED) |
713 if (!command_line->HasSwitch(switches::kDisableFieldTrialTestingConfig) && | 714 if (!command_line->HasSwitch(switches::kDisableFieldTrialTestingConfig) && |
714 !command_line->HasSwitch(switches::kForceFieldTrials) && | 715 !command_line->HasSwitch(switches::kForceFieldTrials) && |
715 !command_line->HasSwitch(variations::switches::kVariationsServerURL)) { | 716 !command_line->HasSwitch(variations::switches::kVariationsServerURL)) { |
716 chrome_variations::AssociateDefaultFieldTrialConfig(feature_list.get()); | 717 chrome_variations::AssociateDefaultFieldTrialConfig(feature_list.get()); |
| 718 password_manager_util::RegisterFieldTrials(feature_list.get()); |
717 } | 719 } |
718 #endif // defined(FIELDTRIAL_TESTING_ENABLED) | 720 #endif // defined(FIELDTRIAL_TESTING_ENABLED) |
719 | 721 |
720 variations::VariationsService* variations_service = | 722 variations::VariationsService* variations_service = |
721 browser_process_->variations_service(); | 723 browser_process_->variations_service(); |
722 if (variations_service) | 724 if (variations_service) |
723 variations_service->CreateTrialsFromSeed(feature_list.get()); | 725 variations_service->CreateTrialsFromSeed(feature_list.get()); |
724 | 726 |
725 base::FeatureList::SetInstance(std::move(feature_list)); | 727 base::FeatureList::SetInstance(std::move(feature_list)); |
726 | 728 |
(...skipping 1165 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1892 chromeos::CrosSettings::Shutdown(); | 1894 chromeos::CrosSettings::Shutdown(); |
1893 #endif // defined(OS_CHROMEOS) | 1895 #endif // defined(OS_CHROMEOS) |
1894 #endif // defined(OS_ANDROID) | 1896 #endif // defined(OS_ANDROID) |
1895 } | 1897 } |
1896 | 1898 |
1897 // Public members: | 1899 // Public members: |
1898 | 1900 |
1899 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { | 1901 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { |
1900 chrome_extra_parts_.push_back(parts); | 1902 chrome_extra_parts_.push_back(parts); |
1901 } | 1903 } |
OLD | NEW |