| 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 #if defined(TOOLKIT_GTK) | 7 #if defined(TOOLKIT_GTK) |
| 8 #include <gtk/gtk.h> | 8 #include <gtk/gtk.h> |
| 9 #endif | 9 #endif |
| 10 | 10 |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 49 #include "chrome/browser/component_updater/flash_component_installer.h" | 49 #include "chrome/browser/component_updater/flash_component_installer.h" |
| 50 #include "chrome/browser/component_updater/pnacl/pnacl_component_installer.h" | 50 #include "chrome/browser/component_updater/pnacl/pnacl_component_installer.h" |
| 51 #include "chrome/browser/component_updater/recovery_component_installer.h" | 51 #include "chrome/browser/component_updater/recovery_component_installer.h" |
| 52 #include "chrome/browser/component_updater/swiftshader_component_installer.h" | 52 #include "chrome/browser/component_updater/swiftshader_component_installer.h" |
| 53 #include "chrome/browser/component_updater/widevine_cdm_component_installer.h" | 53 #include "chrome/browser/component_updater/widevine_cdm_component_installer.h" |
| 54 #include "chrome/browser/defaults.h" | 54 #include "chrome/browser/defaults.h" |
| 55 #include "chrome/browser/extensions/extension_protocols.h" | 55 #include "chrome/browser/extensions/extension_protocols.h" |
| 56 #include "chrome/browser/extensions/extension_service.h" | 56 #include "chrome/browser/extensions/extension_service.h" |
| 57 #include "chrome/browser/extensions/extension_system.h" | 57 #include "chrome/browser/extensions/extension_system.h" |
| 58 #include "chrome/browser/extensions/startup_helper.h" | 58 #include "chrome/browser/extensions/startup_helper.h" |
| 59 #include "chrome/browser/feedback/feedback_profile_observer.h" | |
| 60 #include "chrome/browser/first_run/first_run.h" | 59 #include "chrome/browser/first_run/first_run.h" |
| 61 #include "chrome/browser/first_run/upgrade_util.h" | 60 #include "chrome/browser/first_run/upgrade_util.h" |
| 62 #include "chrome/browser/google/google_search_counter.h" | 61 #include "chrome/browser/google/google_search_counter.h" |
| 63 #include "chrome/browser/google/google_util.h" | 62 #include "chrome/browser/google/google_util.h" |
| 64 #include "chrome/browser/gpu/gl_string_manager.h" | 63 #include "chrome/browser/gpu/gl_string_manager.h" |
| 65 #include "chrome/browser/jankometer.h" | 64 #include "chrome/browser/jankometer.h" |
| 66 #include "chrome/browser/media/media_capture_devices_dispatcher.h" | 65 #include "chrome/browser/media/media_capture_devices_dispatcher.h" |
| 67 #include "chrome/browser/metrics/field_trial_synchronizer.h" | 66 #include "chrome/browser/metrics/field_trial_synchronizer.h" |
| 68 #include "chrome/browser/metrics/metrics_log.h" | 67 #include "chrome/browser/metrics/metrics_log.h" |
| 69 #include "chrome/browser/metrics/metrics_service.h" | 68 #include "chrome/browser/metrics/metrics_service.h" |
| (...skipping 947 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1017 // ... additional setup, including CreateProfile() | 1016 // ... additional setup, including CreateProfile() |
| 1018 // PostProfileInit() | 1017 // PostProfileInit() |
| 1019 // ... additional setup | 1018 // ... additional setup |
| 1020 // PreBrowserStart() | 1019 // PreBrowserStart() |
| 1021 // ... browser_creator_->Start (OR parameters().ui_task->Run()) | 1020 // ... browser_creator_->Start (OR parameters().ui_task->Run()) |
| 1022 // PostBrowserStart() | 1021 // PostBrowserStart() |
| 1023 | 1022 |
| 1024 void ChromeBrowserMainParts::PreProfileInit() { | 1023 void ChromeBrowserMainParts::PreProfileInit() { |
| 1025 TRACE_EVENT0("startup", "ChromeBrowserMainParts::PreProfileInit"); | 1024 TRACE_EVENT0("startup", "ChromeBrowserMainParts::PreProfileInit"); |
| 1026 | 1025 |
| 1027 // Initialize the feedback uploader so it can setup notifications for profile | |
| 1028 // creation. | |
| 1029 feedback::FeedbackProfileObserver::Initialize(); | |
| 1030 | |
| 1031 for (size_t i = 0; i < chrome_extra_parts_.size(); ++i) | 1026 for (size_t i = 0; i < chrome_extra_parts_.size(); ++i) |
| 1032 chrome_extra_parts_[i]->PreProfileInit(); | 1027 chrome_extra_parts_[i]->PreProfileInit(); |
| 1033 | 1028 |
| 1034 #if !defined(OS_ANDROID) | 1029 #if !defined(OS_ANDROID) |
| 1035 ProfileManager* profile_manager = g_browser_process->profile_manager(); | 1030 ProfileManager* profile_manager = g_browser_process->profile_manager(); |
| 1036 | 1031 |
| 1037 // First check if any ephemeral profiles are left behind because of browser | 1032 // First check if any ephemeral profiles are left behind because of browser |
| 1038 // crash and schedule them for deletion and then proceed with getting the set | 1033 // crash and schedule them for deletion and then proceed with getting the set |
| 1039 // of profiles to open. | 1034 // of profiles to open. |
| 1040 ProfileInfoCache& profile_cache = profile_manager->GetProfileInfoCache(); | 1035 ProfileInfoCache& profile_cache = profile_manager->GetProfileInfoCache(); |
| (...skipping 646 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1687 chromeos::CrosSettings::Shutdown(); | 1682 chromeos::CrosSettings::Shutdown(); |
| 1688 #endif | 1683 #endif |
| 1689 #endif | 1684 #endif |
| 1690 } | 1685 } |
| 1691 | 1686 |
| 1692 // Public members: | 1687 // Public members: |
| 1693 | 1688 |
| 1694 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { | 1689 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { |
| 1695 chrome_extra_parts_.push_back(parts); | 1690 chrome_extra_parts_.push_back(parts); |
| 1696 } | 1691 } |
| OLD | NEW |