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

Side by Side Diff: net/proxy/proxy_service.cc

Issue 7583053: Add MessageLoopProxy::current (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: No need for MessageLoopProxy destruction observer. Created 9 years, 4 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
« no previous file with comments | « net/proxy/polling_proxy_config_service.cc ('k') | ppapi/proxy/ppb_core_proxy.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "net/proxy/proxy_service.h" 5 #include "net/proxy/proxy_service.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 410 matching lines...) Expand 10 before | Expand all | Expand 10 after
421 DCHECK(dhcp_proxy_script_fetcher); 421 DCHECK(dhcp_proxy_script_fetcher);
422 DCHECK(host_resolver); 422 DCHECK(host_resolver);
423 423
424 if (num_pac_threads == 0) 424 if (num_pac_threads == 0)
425 num_pac_threads = kDefaultNumPacThreads; 425 num_pac_threads = kDefaultNumPacThreads;
426 426
427 ProxyResolverFactory* sync_resolver_factory = 427 ProxyResolverFactory* sync_resolver_factory =
428 new ProxyResolverFactoryForV8( 428 new ProxyResolverFactoryForV8(
429 host_resolver, 429 host_resolver,
430 MessageLoop::current(), 430 MessageLoop::current(),
431 base::MessageLoopProxy::CreateForCurrentThread(), 431 base::MessageLoopProxy::current(),
432 net_log, 432 net_log,
433 network_delegate); 433 network_delegate);
434 434
435 ProxyResolver* proxy_resolver = 435 ProxyResolver* proxy_resolver =
436 new MultiThreadedProxyResolver(sync_resolver_factory, num_pac_threads); 436 new MultiThreadedProxyResolver(sync_resolver_factory, num_pac_threads);
437 437
438 ProxyService* proxy_service = 438 ProxyService* proxy_service =
439 new ProxyService(proxy_config_service, proxy_resolver, net_log); 439 new ProxyService(proxy_config_service, proxy_resolver, net_log);
440 440
441 // Configure fetchers to use for PAC script downloads and auto-detect. 441 // Configure fetchers to use for PAC script downloads and auto-detect.
(...skipping 579 matching lines...) Expand 10 before | Expand all | Expand 10 after
1021 OnCompletion(result_); 1021 OnCompletion(result_);
1022 } 1022 }
1023 } 1023 }
1024 1024
1025 void SyncProxyServiceHelper::OnCompletion(int rv) { 1025 void SyncProxyServiceHelper::OnCompletion(int rv) {
1026 result_ = rv; 1026 result_ = rv;
1027 event_.Signal(); 1027 event_.Signal();
1028 } 1028 }
1029 1029
1030 } // namespace net 1030 } // namespace net
OLDNEW
« no previous file with comments | « net/proxy/polling_proxy_config_service.cc ('k') | ppapi/proxy/ppb_core_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698