OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/ui/webui/chrome_web_ui_controller_factory.h" | 5 #include "chrome/browser/ui/webui/chrome_web_ui_controller_factory.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 #include "base/location.h" | 9 #include "base/location.h" |
10 #include "base/message_loop/message_loop_proxy.h" | 10 #include "base/message_loop/message_loop_proxy.h" |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
136 | 136 |
137 #if defined(OS_WIN) | 137 #if defined(OS_WIN) |
138 #include "chrome/browser/ui/webui/conflicts_ui.h" | 138 #include "chrome/browser/ui/webui/conflicts_ui.h" |
139 #include "chrome/browser/ui/webui/set_as_default_browser_ui.h" | 139 #include "chrome/browser/ui/webui/set_as_default_browser_ui.h" |
140 #endif | 140 #endif |
141 | 141 |
142 #if (defined(USE_NSS) || defined(USE_OPENSSL)) && defined(USE_AURA) | 142 #if (defined(USE_NSS) || defined(USE_OPENSSL)) && defined(USE_AURA) |
143 #include "chrome/browser/ui/webui/certificate_viewer_ui.h" | 143 #include "chrome/browser/ui/webui/certificate_viewer_ui.h" |
144 #endif | 144 #endif |
145 | 145 |
146 #if defined(ENABLE_MDNS) | 146 #if defined(ENABLE_SERVICE_DISCOVERY) |
147 #include "chrome/browser/ui/webui/local_discovery/local_discovery_ui.h" | 147 #include "chrome/browser/ui/webui/local_discovery/local_discovery_ui.h" |
148 #endif | 148 #endif |
149 | 149 |
150 #if defined(ENABLE_APP_LIST) | 150 #if defined(ENABLE_APP_LIST) |
151 #include "chrome/browser/ui/webui/app_list/start_page_ui.h" | 151 #include "chrome/browser/ui/webui/app_list/start_page_ui.h" |
152 #endif | 152 #endif |
153 | 153 |
154 using content::WebUI; | 154 using content::WebUI; |
155 using content::WebUIController; | 155 using content::WebUIController; |
156 using ui::ExternalWebDialogUI; | 156 using ui::ExternalWebDialogUI; |
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
244 if (url.host() == chrome::kChromeUICloudPrintResourcesHost) | 244 if (url.host() == chrome::kChromeUICloudPrintResourcesHost) |
245 return &NewWebUI<ExternalWebDialogUI>; | 245 return &NewWebUI<ExternalWebDialogUI>; |
246 if (url.host() == chrome::kChromeUICloudPrintSetupHost) | 246 if (url.host() == chrome::kChromeUICloudPrintSetupHost) |
247 return &NewWebUI<WebDialogUI>; | 247 return &NewWebUI<WebDialogUI>; |
248 if (url.host() == chrome::kChromeUIComponentsHost) | 248 if (url.host() == chrome::kChromeUIComponentsHost) |
249 return &NewWebUI<ComponentsUI>; | 249 return &NewWebUI<ComponentsUI>; |
250 if (url.spec() == chrome::kChromeUIConstrainedHTMLTestURL) | 250 if (url.spec() == chrome::kChromeUIConstrainedHTMLTestURL) |
251 return &NewWebUI<ConstrainedWebDialogUI>; | 251 return &NewWebUI<ConstrainedWebDialogUI>; |
252 if (url.host() == chrome::kChromeUICrashesHost) | 252 if (url.host() == chrome::kChromeUICrashesHost) |
253 return &NewWebUI<CrashesUI>; | 253 return &NewWebUI<CrashesUI>; |
254 #if defined(ENABLE_MDNS) | 254 #if defined(ENABLE_SERVICE_DISCOVERY) |
255 if (url.host() == chrome::kChromeUIDevicesHost && | 255 if (url.host() == chrome::kChromeUIDevicesHost && |
256 !CommandLine::ForCurrentProcess()->HasSwitch( | 256 !CommandLine::ForCurrentProcess()->HasSwitch( |
257 switches::kDisableDeviceDiscovery)) { | 257 switches::kDisableDeviceDiscovery)) { |
258 return &NewWebUI<LocalDiscoveryUI>; | 258 return &NewWebUI<LocalDiscoveryUI>; |
259 } | 259 } |
260 #endif | 260 #endif |
261 if (url.host() == chrome::kChromeUIFlagsHost) | 261 if (url.host() == chrome::kChromeUIFlagsHost) |
262 return &NewWebUI<FlagsUI>; | 262 return &NewWebUI<FlagsUI>; |
263 if (url.host() == chrome::kChromeUIHistoryFrameHost) | 263 if (url.host() == chrome::kChromeUIHistoryFrameHost) |
264 return &NewWebUI<HistoryUI>; | 264 return &NewWebUI<HistoryUI>; |
(...skipping 404 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
669 #endif | 669 #endif |
670 | 670 |
671 // Android doesn't use the plugins pages. | 671 // Android doesn't use the plugins pages. |
672 if (page_url.host() == chrome::kChromeUIPluginsHost) | 672 if (page_url.host() == chrome::kChromeUIPluginsHost) |
673 return PluginsUI::GetFaviconResourceBytes(scale_factor); | 673 return PluginsUI::GetFaviconResourceBytes(scale_factor); |
674 | 674 |
675 #endif | 675 #endif |
676 | 676 |
677 return NULL; | 677 return NULL; |
678 } | 678 } |
OLD | NEW |