OLD | NEW |
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/component_updater/ios_component_updater_configurato
r.h" | 5 #include "ios/chrome/browser/component_updater/ios_component_updater_configurato
r.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/threading/sequenced_worker_pool.h" | 10 #include "base/threading/sequenced_worker_pool.h" |
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
147 | 147 |
148 scoped_refptr<base::SequencedTaskRunner> | 148 scoped_refptr<base::SequencedTaskRunner> |
149 IOSConfigurator::GetSequencedTaskRunner() const { | 149 IOSConfigurator::GetSequencedTaskRunner() const { |
150 return web::WebThread::GetBlockingPool() | 150 return web::WebThread::GetBlockingPool() |
151 ->GetSequencedTaskRunnerWithShutdownBehavior( | 151 ->GetSequencedTaskRunnerWithShutdownBehavior( |
152 web::WebThread::GetBlockingPool()->GetSequenceToken(), | 152 web::WebThread::GetBlockingPool()->GetSequenceToken(), |
153 base::SequencedWorkerPool::SKIP_ON_SHUTDOWN); | 153 base::SequencedWorkerPool::SKIP_ON_SHUTDOWN); |
154 } | 154 } |
155 | 155 |
156 PrefService* IOSConfigurator::GetPrefService() const { | 156 PrefService* IOSConfigurator::GetPrefService() const { |
157 return nullptr; | 157 return GetApplicationContext()->GetLocalState(); |
158 } | 158 } |
159 | 159 |
160 } // namespace | 160 } // namespace |
161 | 161 |
162 scoped_refptr<update_client::Configurator> MakeIOSComponentUpdaterConfigurator( | 162 scoped_refptr<update_client::Configurator> MakeIOSComponentUpdaterConfigurator( |
163 const base::CommandLine* cmdline, | 163 const base::CommandLine* cmdline, |
164 net::URLRequestContextGetter* context_getter) { | 164 net::URLRequestContextGetter* context_getter) { |
165 return new IOSConfigurator(cmdline, context_getter); | 165 return new IOSConfigurator(cmdline, context_getter); |
166 } | 166 } |
167 | 167 |
168 } // namespace component_updater | 168 } // namespace component_updater |
OLD | NEW |