OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/net/chrome_url_request_context.h" | 5 #include "chrome/browser/net/chrome_url_request_context.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/message_loop.h" | 8 #include "base/message_loop.h" |
9 #include "base/message_loop_proxy.h" | 9 #include "base/message_loop_proxy.h" |
10 #include "base/string_util.h" | 10 #include "base/string_util.h" |
(...skipping 533 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
544 NewRunnableMethod(this, | 544 NewRunnableMethod(this, |
545 &ChromeURLRequestContextGetter::GetCookieStoreAsyncHelper, | 545 &ChromeURLRequestContextGetter::GetCookieStoreAsyncHelper, |
546 &completion, | 546 &completion, |
547 &result)); | 547 &result)); |
548 | 548 |
549 completion.Wait(); | 549 completion.Wait(); |
550 DCHECK(result); | 550 DCHECK(result); |
551 return result; | 551 return result; |
552 } | 552 } |
553 | 553 |
554 scoped_refptr<MessageLoopProxy> | 554 scoped_refptr<base::MessageLoopProxy> |
555 ChromeURLRequestContextGetter::GetIOMessageLoopProxy() { | 555 ChromeURLRequestContextGetter::GetIOMessageLoopProxy() { |
556 return ChromeThread::GetMessageLoopProxyForThread(ChromeThread::IO); | 556 return ChromeThread::GetMessageLoopProxyForThread(ChromeThread::IO); |
557 } | 557 } |
558 | 558 |
559 // static | 559 // static |
560 ChromeURLRequestContextGetter* ChromeURLRequestContextGetter::CreateOriginal( | 560 ChromeURLRequestContextGetter* ChromeURLRequestContextGetter::CreateOriginal( |
561 Profile* profile, const FilePath& cookie_store_path, | 561 Profile* profile, const FilePath& cookie_store_path, |
562 const FilePath& disk_cache_path, int cache_size) { | 562 const FilePath& disk_cache_path, int cache_size) { |
563 DCHECK(!profile->IsOffTheRecord()); | 563 DCHECK(!profile->IsOffTheRecord()); |
564 return new ChromeURLRequestContextGetter( | 564 return new ChromeURLRequestContextGetter( |
(...skipping 473 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1038 } | 1038 } |
1039 | 1039 |
1040 if (command_line.HasSwitch(switches::kProxyBypassList)) { | 1040 if (command_line.HasSwitch(switches::kProxyBypassList)) { |
1041 proxy_config->proxy_rules().bypass_rules.ParseFromString( | 1041 proxy_config->proxy_rules().bypass_rules.ParseFromString( |
1042 WideToASCII(command_line.GetSwitchValue( | 1042 WideToASCII(command_line.GetSwitchValue( |
1043 switches::kProxyBypassList))); | 1043 switches::kProxyBypassList))); |
1044 } | 1044 } |
1045 | 1045 |
1046 return proxy_config; | 1046 return proxy_config; |
1047 } | 1047 } |
OLD | NEW |