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

Side by Side Diff: chrome/browser/browser_process_impl.cc

Issue 334783002: Componentize component_updater: Move some paths/constants to component. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge origin/master Created 6 years, 6 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 | Annotate | Revision Log
OLDNEW
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/browser_process_impl.h" 5 #include "chrome/browser/browser_process_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <map> 8 #include <map>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 #include "chrome/browser/renderer_host/chrome_resource_dispatcher_host_delegate. h" 62 #include "chrome/browser/renderer_host/chrome_resource_dispatcher_host_delegate. h"
63 #include "chrome/browser/safe_browsing/safe_browsing_service.h" 63 #include "chrome/browser/safe_browsing/safe_browsing_service.h"
64 #include "chrome/browser/shell_integration.h" 64 #include "chrome/browser/shell_integration.h"
65 #include "chrome/browser/status_icons/status_tray.h" 65 #include "chrome/browser/status_icons/status_tray.h"
66 #include "chrome/browser/ui/browser_dialogs.h" 66 #include "chrome/browser/ui/browser_dialogs.h"
67 #include "chrome/browser/ui/browser_finder.h" 67 #include "chrome/browser/ui/browser_finder.h"
68 #include "chrome/browser/web_resource/promo_resource_service.h" 68 #include "chrome/browser/web_resource/promo_resource_service.h"
69 #include "chrome/common/chrome_constants.h" 69 #include "chrome/common/chrome_constants.h"
70 #include "chrome/common/chrome_paths.h" 70 #include "chrome/common/chrome_paths.h"
71 #include "chrome/common/chrome_switches.h" 71 #include "chrome/common/chrome_switches.h"
72 #include "chrome/common/chrome_version_info.h"
72 #include "chrome/common/extensions/chrome_extensions_client.h" 73 #include "chrome/common/extensions/chrome_extensions_client.h"
73 #include "chrome/common/pref_names.h" 74 #include "chrome/common/pref_names.h"
74 #include "chrome/common/switch_utils.h" 75 #include "chrome/common/switch_utils.h"
75 #include "chrome/common/url_constants.h" 76 #include "chrome/common/url_constants.h"
76 #include "chrome/installer/util/google_update_constants.h" 77 #include "chrome/installer/util/google_update_constants.h"
77 #include "chrome/installer/util/google_update_settings.h" 78 #include "chrome/installer/util/google_update_settings.h"
78 #include "components/gcm_driver/gcm_driver.h" 79 #include "components/gcm_driver/gcm_driver.h"
79 #include "components/metrics/metrics_service.h" 80 #include "components/metrics/metrics_service.h"
80 #include "components/network_time/network_time_tracker.h" 81 #include "components/network_time/network_time_tracker.h"
81 #include "components/policy/core/common/policy_service.h" 82 #include "components/policy/core/common/policy_service.h"
(...skipping 698 matching lines...) Expand 10 before | Expand all | Expand 10 after
780 BrowserProcessImpl::component_updater() { 781 BrowserProcessImpl::component_updater() {
781 if (!component_updater_.get()) { 782 if (!component_updater_.get()) {
782 if (!BrowserThread::CurrentlyOn(BrowserThread::UI)) 783 if (!BrowserThread::CurrentlyOn(BrowserThread::UI))
783 return NULL; 784 return NULL;
784 component_updater::ComponentUpdateService::Configurator* configurator = 785 component_updater::ComponentUpdateService::Configurator* configurator =
785 component_updater::MakeChromeComponentUpdaterConfigurator( 786 component_updater::MakeChromeComponentUpdaterConfigurator(
786 CommandLine::ForCurrentProcess(), 787 CommandLine::ForCurrentProcess(),
787 io_thread()->system_url_request_context_getter()); 788 io_thread()->system_url_request_context_getter());
788 // Creating the component updater does not do anything, components 789 // Creating the component updater does not do anything, components
789 // need to be registered and Start() needs to be called. 790 // need to be registered and Start() needs to be called.
790 component_updater_.reset(ComponentUpdateServiceFactory(configurator)); 791 component_updater_.reset(
792 ComponentUpdateServiceFactory(configurator,
793 chrome::VersionInfo().Version(),
Sorin Jianu 2014/06/19 00:48:21 This could be members of the configurator.
794 chrome::VersionInfo().OSType()));
791 } 795 }
792 return component_updater_.get(); 796 return component_updater_.get();
793 } 797 }
794 798
795 CRLSetFetcher* BrowserProcessImpl::crl_set_fetcher() { 799 CRLSetFetcher* BrowserProcessImpl::crl_set_fetcher() {
796 if (!crl_set_fetcher_.get()) 800 if (!crl_set_fetcher_.get())
797 crl_set_fetcher_ = new CRLSetFetcher(); 801 crl_set_fetcher_ = new CRLSetFetcher();
798 return crl_set_fetcher_.get(); 802 return crl_set_fetcher_.get();
799 } 803 }
800 804
(...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after
1101 } 1105 }
1102 1106
1103 void BrowserProcessImpl::OnAutoupdateTimer() { 1107 void BrowserProcessImpl::OnAutoupdateTimer() {
1104 if (CanAutorestartForUpdate()) { 1108 if (CanAutorestartForUpdate()) {
1105 DLOG(WARNING) << "Detected update. Restarting browser."; 1109 DLOG(WARNING) << "Detected update. Restarting browser.";
1106 RestartBackgroundInstance(); 1110 RestartBackgroundInstance();
1107 } 1111 }
1108 } 1112 }
1109 1113
1110 #endif // (defined(OS_WIN) || defined(OS_LINUX)) && !defined(OS_CHROMEOS) 1114 #endif // (defined(OS_WIN) || defined(OS_LINUX)) && !defined(OS_CHROMEOS)
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/chrome_browser_main.cc » ('j') | chrome/browser/chrome_browser_main.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698