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

Side by Side Diff: chrome/browser/extensions/updater/chrome_update_client_config.cc

Issue 1362043005: Add extensions code to use common updater in components/update_client/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: merged latest origin/master Created 5 years, 2 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "base/command_line.h"
6 #include "base/version.h"
7 #include "chrome/browser/component_updater/component_patcher_operation_out_of_pr ocess.h"
8 #include "chrome/browser/extensions/updater/chrome_update_client_config.h"
9 #include "chrome/browser/update_client/chrome_update_query_params_delegate.h"
10 #include "chrome/common/channel_info.h"
11 #include "content/public/browser/browser_context.h"
12
13 namespace extensions {
14
15 ChromeUpdateClientConfig::ChromeUpdateClientConfig(
16 content::BrowserContext* context)
17 : impl_(base::CommandLine::ForCurrentProcess(),
18 context->GetRequestContext()) {
19 impl_.set_enable_alt_source_url(false);
20 }
21
22 int ChromeUpdateClientConfig::InitialDelay() const {
23 return impl_.InitialDelay();
24 }
25
26 int ChromeUpdateClientConfig::NextCheckDelay() const {
27 return impl_.NextCheckDelay();
28 }
29
30 int ChromeUpdateClientConfig::StepDelay() const {
31 return impl_.StepDelay();
32 }
33
34 int ChromeUpdateClientConfig::OnDemandDelay() const {
35 return impl_.OnDemandDelay();
36 }
37
38 int ChromeUpdateClientConfig::UpdateDelay() const {
39 return 0;
40 }
41
42 std::vector<GURL> ChromeUpdateClientConfig::UpdateUrl() const {
43 return impl_.UpdateUrl();
44 }
45
46 std::vector<GURL> ChromeUpdateClientConfig::PingUrl() const {
47 return impl_.PingUrl();
48 }
49
50 base::Version ChromeUpdateClientConfig::GetBrowserVersion() const {
51 return impl_.GetBrowserVersion();
52 }
53
54 std::string ChromeUpdateClientConfig::GetChannel() const {
55 return chrome::GetChannelString();
56 }
57
58 std::string ChromeUpdateClientConfig::GetLang() const {
59 return ChromeUpdateQueryParamsDelegate::GetLang();
60 }
61
62 std::string ChromeUpdateClientConfig::GetOSLongName() const {
63 return impl_.GetOSLongName();
64 }
65
66 std::string ChromeUpdateClientConfig::ExtraRequestParams() const {
67 return impl_.ExtraRequestParams();
68 }
69
70 net::URLRequestContextGetter* ChromeUpdateClientConfig::RequestContext() const {
71 return impl_.RequestContext();
72 }
73
74 scoped_refptr<update_client::OutOfProcessPatcher>
75 ChromeUpdateClientConfig::CreateOutOfProcessPatcher() const {
76 return make_scoped_refptr(new component_updater::ChromeOutOfProcessPatcher);
77 }
78
79 bool ChromeUpdateClientConfig::DeltasEnabled() const {
80 return impl_.DeltasEnabled();
81 }
82
83 bool ChromeUpdateClientConfig::UseBackgroundDownloader() const {
84 return impl_.UseBackgroundDownloader();
85 }
86
87 ChromeUpdateClientConfig::~ChromeUpdateClientConfig() {}
88
89 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/browser/extensions/updater/chrome_update_client_config.h ('k') | chrome/chrome_browser_extensions.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698