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/browser_init.h" | 5 #include "chrome/browser/browser_init.h" |
6 | 6 |
7 #include "app/l10n_util.h" | 7 #include "app/l10n_util.h" |
8 #include "app/resource_bundle.h" | 8 #include "app/resource_bundle.h" |
9 #include "base/event_recorder.h" | 9 #include "base/event_recorder.h" |
10 #include "base/path_service.h" | 10 #include "base/path_service.h" |
(...skipping 1000 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1011 } else { | 1011 } else { |
1012 CreateAutomationProvider<AutomationProvider>(automation_channel_id, | 1012 CreateAutomationProvider<AutomationProvider>(automation_channel_id, |
1013 profile, expected_tabs); | 1013 profile, expected_tabs); |
1014 } | 1014 } |
1015 } | 1015 } |
1016 | 1016 |
1017 if (command_line.HasSwitch(switches::kUseSpdy)) { | 1017 if (command_line.HasSwitch(switches::kUseSpdy)) { |
1018 std::string spdy_mode = | 1018 std::string spdy_mode = |
1019 command_line.GetSwitchValueASCII(switches::kUseSpdy); | 1019 command_line.GetSwitchValueASCII(switches::kUseSpdy); |
1020 net::HttpNetworkLayer::EnableSpdy(spdy_mode); | 1020 net::HttpNetworkLayer::EnableSpdy(spdy_mode); |
| 1021 #if defined(OS_WIN) |
| 1022 } else if (BrowserDistribution::GetDistribution()->IsSpdyEnabled()) { |
| 1023 std::string spdy_mode = |
| 1024 BrowserDistribution::GetDistribution()->GetSpdyMode(); |
| 1025 net::HttpNetworkLayer::EnableSpdy(spdy_mode); |
| 1026 #endif |
1021 } | 1027 } |
1022 | 1028 |
| 1029 |
1023 if (command_line.HasSwitch(switches::kExplicitlyAllowedPorts)) { | 1030 if (command_line.HasSwitch(switches::kExplicitlyAllowedPorts)) { |
1024 std::wstring allowed_ports = | 1031 std::wstring allowed_ports = |
1025 command_line.GetSwitchValue(switches::kExplicitlyAllowedPorts); | 1032 command_line.GetSwitchValue(switches::kExplicitlyAllowedPorts); |
1026 net::SetExplicitlyAllowedPorts(allowed_ports); | 1033 net::SetExplicitlyAllowedPorts(allowed_ports); |
1027 } | 1034 } |
1028 | 1035 |
1029 if (command_line.HasSwitch(switches::kEnableUserDataDirProfiles)) { | 1036 if (command_line.HasSwitch(switches::kEnableUserDataDirProfiles)) { |
1030 // Update user data dir profiles when kEnableUserDataDirProfiles is enabled. | 1037 // Update user data dir profiles when kEnableUserDataDirProfiles is enabled. |
1031 // Profile enumeration would be scheduled on file thread and when | 1038 // Profile enumeration would be scheduled on file thread and when |
1032 // enumeration is done, the profile list in BrowserProcess would be | 1039 // enumeration is done, the profile list in BrowserProcess would be |
(...skipping 23 matching lines...) Expand all Loading... |
1056 scoped_refptr<AutomationProviderClass> automation = | 1063 scoped_refptr<AutomationProviderClass> automation = |
1057 new AutomationProviderClass(profile); | 1064 new AutomationProviderClass(profile); |
1058 automation->ConnectToChannel(channel_id); | 1065 automation->ConnectToChannel(channel_id); |
1059 automation->SetExpectedTabCount(expected_tabs); | 1066 automation->SetExpectedTabCount(expected_tabs); |
1060 | 1067 |
1061 AutomationProviderList* list = | 1068 AutomationProviderList* list = |
1062 g_browser_process->InitAutomationProviderList(); | 1069 g_browser_process->InitAutomationProviderList(); |
1063 DCHECK(list); | 1070 DCHECK(list); |
1064 list->AddProvider(automation); | 1071 list->AddProvider(automation); |
1065 } | 1072 } |
OLD | NEW |