URLRequestContenxtGetter now accepts task runner

This commit is contained in:
Cheng Zhao 2017-01-23 15:42:37 +09:00
parent 622fd8d1d7
commit ac4ef926e1
3 changed files with 11 additions and 11 deletions

View file

@ -118,8 +118,8 @@ URLRequestContextGetter::URLRequestContextGetter(
NetLog* net_log,
const base::FilePath& base_path,
bool in_memory,
base::MessageLoop* io_loop,
base::MessageLoop* file_loop,
scoped_refptr<base::SingleThreadTaskRunner> io_task_runner,
scoped_refptr<base::SingleThreadTaskRunner> file_task_runner,
content::ProtocolHandlerMap* protocol_handlers,
content::URLRequestInterceptorScopedVector protocol_interceptors)
: delegate_(delegate),
@ -127,8 +127,8 @@ URLRequestContextGetter::URLRequestContextGetter(
net_log_(net_log),
base_path_(base_path),
in_memory_(in_memory),
io_loop_(io_loop),
file_loop_(file_loop),
io_task_runner_(io_task_runner),
file_task_runner_(file_task_runner),
protocol_interceptors_(std::move(protocol_interceptors)),
job_factory_(nullptr) {
// Must first be created on the UI thread.
@ -144,7 +144,7 @@ URLRequestContextGetter::URLRequestContextGetter(
// must synchronously run on the glib message loop. This will be passed to
// the URLRequestContextStorage on the IO thread in GetURLRequestContext().
proxy_config_service_ = net::ProxyService::CreateSystemProxyConfigService(
io_loop_->task_runner(), file_loop_->task_runner());
io_task_runner_, file_task_runner_);
}
URLRequestContextGetter::~URLRequestContextGetter() {