Chromium Code Reviews| Index: chrome/browser/browser_main.cc |
| diff --git a/chrome/browser/browser_main.cc b/chrome/browser/browser_main.cc |
| index 75944c5678869e285f40e4ba3b6bd858f3c43a13..09ca24f3579706c2c3a5e6400bb36135ed735d31 100644 |
| --- a/chrome/browser/browser_main.cc |
| +++ b/chrome/browser/browser_main.cc |
| @@ -128,6 +128,7 @@ |
| #include "chrome/browser/chromeos/boot_times_loader.h" |
| #include "chrome/browser/chromeos/brightness_observer.h" |
| #include "chrome/browser/chromeos/system_key_event_listener.h" |
| +#include "chrome/browser/chromeos/webproxy_task.h" |
| #include "chrome/browser/oom_priority_manager.h" |
| #endif |
| @@ -641,6 +642,9 @@ void CreateChildThreads(BrowserProcessImpl* process) { |
| process->process_launcher_thread(); |
| process->cache_thread(); |
| process->io_thread(); |
| +#if defined(OS_CHROMEOS) |
| + process->webproxy_thread(); |
| +#endif |
| // Create watchdog thread after creating all other threads because it will |
| // watch the other threads and they must be running. |
| process->watchdog_thread(); |
| @@ -1470,6 +1474,16 @@ int BrowserMain(const MainFunctionParams& parameters) { |
| OptionallyRunChromeOSLoginManager(parsed_command_line); |
| } |
| +#if defined(OS_CHROMEOS) |
| + // We delay launching websocket to TCP proxy because we do not want to |
|
zel
2011/04/07 16:54:12
can we make this launch when API is being used for
Denis Lagno
2011/04/07 17:48:22
it is possible but in this case I need to either m
Denis Lagno
2011/04/11 23:21:27
launching webproxy is on demand now.
Idle webproxy
|
| + // increase startup time accidentally. |
| + const int kWebProxyDelayMs = 5000; |
| + // TODO(dilmah): remove webproxy thread, instead implement the same |
| + // functionality via hooks into websocket layer. |
| + g_browser_process->webproxy_thread()->message_loop()->PostDelayedTask( |
| + FROM_HERE, new chromeos::WebproxyTask(), kWebProxyDelayMs); |
| +#endif |
| + |
| #if !defined(OS_MACOSX) |
| // Importing other browser settings is done in a browser-like process |
| // that exits when this task has finished. |