| 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/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "chrome/browser/about_flags.h" | 8 #include "chrome/browser/about_flags.h" |
| 9 #include "chrome/browser/browser_process.h" | 9 #include "chrome/browser/browser_process.h" |
| 10 #include "chrome/browser/extensions/extension_service.h" | 10 #include "chrome/browser/extensions/extension_service.h" |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 56 #include "chrome/common/url_constants.h" | 56 #include "chrome/common/url_constants.h" |
| 57 #include "content/public/browser/web_contents.h" | 57 #include "content/public/browser/web_contents.h" |
| 58 #include "content/public/browser/web_ui.h" | 58 #include "content/public/browser/web_ui.h" |
| 59 #include "content/public/common/content_client.h" | 59 #include "content/public/common/content_client.h" |
| 60 #include "googleurl/src/gurl.h" | 60 #include "googleurl/src/gurl.h" |
| 61 #include "ui/web_dialogs/constrained_web_dialog_ui.h" | 61 #include "ui/web_dialogs/constrained_web_dialog_ui.h" |
| 62 #include "ui/web_dialogs/web_dialog_ui.h" | 62 #include "ui/web_dialogs/web_dialog_ui.h" |
| 63 | 63 |
| 64 #if defined(OS_CHROMEOS) | 64 #if defined(OS_CHROMEOS) |
| 65 #include "chrome/browser/ui/webui/chromeos/choose_mobile_network_ui.h" | 65 #include "chrome/browser/ui/webui/chromeos/choose_mobile_network_ui.h" |
| 66 #include "chrome/browser/ui/webui/chromeos/cryptohome_ui.h" |
| 66 #include "chrome/browser/ui/webui/chromeos/imageburner/imageburner_ui.h" | 67 #include "chrome/browser/ui/webui/chromeos/imageburner/imageburner_ui.h" |
| 67 #include "chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.h" | 68 #include "chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.h" |
| 68 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" | 69 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" |
| 69 #include "chrome/browser/ui/webui/chromeos/mobile_setup_ui.h" | 70 #include "chrome/browser/ui/webui/chromeos/mobile_setup_ui.h" |
| 70 #include "chrome/browser/ui/webui/chromeos/proxy_settings_ui.h" | 71 #include "chrome/browser/ui/webui/chromeos/proxy_settings_ui.h" |
| 71 #include "chrome/browser/ui/webui/chromeos/register_page_ui.h" | 72 #include "chrome/browser/ui/webui/chromeos/register_page_ui.h" |
| 72 #include "chrome/browser/ui/webui/chromeos/sim_unlock_ui.h" | 73 #include "chrome/browser/ui/webui/chromeos/sim_unlock_ui.h" |
| 73 #include "chrome/browser/ui/webui/chromeos/system_info_ui.h" | 74 #include "chrome/browser/ui/webui/chromeos/system_info_ui.h" |
| 74 #endif | 75 #endif |
| 75 | 76 |
| (...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 265 if (url.host() == chrome::kChromeUIMetroFlowHost) | 266 if (url.host() == chrome::kChromeUIMetroFlowHost) |
| 266 return &NewWebUI<SetAsDefaultBrowserUI>; | 267 return &NewWebUI<SetAsDefaultBrowserUI>; |
| 267 #endif | 268 #endif |
| 268 #if (defined(USE_NSS) || defined(USE_OPENSSL)) && defined(USE_AURA) | 269 #if (defined(USE_NSS) || defined(USE_OPENSSL)) && defined(USE_AURA) |
| 269 if (url.host() == chrome::kChromeUICertificateViewerHost) | 270 if (url.host() == chrome::kChromeUICertificateViewerHost) |
| 270 return &NewWebUI<CertificateViewerUI>; | 271 return &NewWebUI<CertificateViewerUI>; |
| 271 #endif | 272 #endif |
| 272 #if defined(OS_CHROMEOS) | 273 #if defined(OS_CHROMEOS) |
| 273 if (url.host() == chrome::kChromeUIChooseMobileNetworkHost) | 274 if (url.host() == chrome::kChromeUIChooseMobileNetworkHost) |
| 274 return &NewWebUI<chromeos::ChooseMobileNetworkUI>; | 275 return &NewWebUI<chromeos::ChooseMobileNetworkUI>; |
| 276 if (url.host() == chrome::kChromeUICryptohomeHost) |
| 277 return &NewWebUI<chromeos::CryptohomeUI>; |
| 275 if (url.host() == chrome::kChromeUIImageBurnerHost) | 278 if (url.host() == chrome::kChromeUIImageBurnerHost) |
| 276 return &NewWebUI<ImageBurnUI>; | 279 return &NewWebUI<ImageBurnUI>; |
| 277 if (url.host() == chrome::kChromeUIKeyboardOverlayHost) | 280 if (url.host() == chrome::kChromeUIKeyboardOverlayHost) |
| 278 return &NewWebUI<KeyboardOverlayUI>; | 281 return &NewWebUI<KeyboardOverlayUI>; |
| 279 if (url.host() == chrome::kChromeUIMobileSetupHost) | 282 if (url.host() == chrome::kChromeUIMobileSetupHost) |
| 280 return &NewWebUI<MobileSetupUI>; | 283 return &NewWebUI<MobileSetupUI>; |
| 281 if (url.host() == chrome::kChromeUIOobeHost) | 284 if (url.host() == chrome::kChromeUIOobeHost) |
| 282 return &NewWebUI<chromeos::OobeUI>; | 285 return &NewWebUI<chromeos::OobeUI>; |
| 283 if (url.host() == chrome::kChromeUIProxySettingsHost) | 286 if (url.host() == chrome::kChromeUIProxySettingsHost) |
| 284 return &NewWebUI<chromeos::ProxySettingsUI>; | 287 return &NewWebUI<chromeos::ProxySettingsUI>; |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 334 url.host() == chrome::kChromeUIMemoryHost || | 337 url.host() == chrome::kChromeUIMemoryHost || |
| 335 url.host() == chrome::kChromeUIMemoryRedirectHost || | 338 url.host() == chrome::kChromeUIMemoryRedirectHost || |
| 336 url.host() == chrome::kChromeUIStatsHost || | 339 url.host() == chrome::kChromeUIStatsHost || |
| 337 url.host() == chrome::kChromeUITermsHost || | 340 url.host() == chrome::kChromeUITermsHost || |
| 338 url.host() == chrome::kChromeUIVersionHost | 341 url.host() == chrome::kChromeUIVersionHost |
| 339 #if defined(OS_LINUX) || defined(OS_OPENBSD) | 342 #if defined(OS_LINUX) || defined(OS_OPENBSD) |
| 340 || url.host() == chrome::kChromeUILinuxProxyConfigHost | 343 || url.host() == chrome::kChromeUILinuxProxyConfigHost |
| 341 || url.host() == chrome::kChromeUISandboxHost | 344 || url.host() == chrome::kChromeUISandboxHost |
| 342 #endif | 345 #endif |
| 343 #if defined(OS_CHROMEOS) | 346 #if defined(OS_CHROMEOS) |
| 344 || url.host() == chrome::kChromeUICryptohomeHost | |
| 345 || url.host() == chrome::kChromeUIDiscardsHost | 347 || url.host() == chrome::kChromeUIDiscardsHost |
| 346 || url.host() == chrome::kChromeUINetworkHost | 348 || url.host() == chrome::kChromeUINetworkHost |
| 347 || url.host() == chrome::kChromeUIOSCreditsHost | 349 || url.host() == chrome::kChromeUIOSCreditsHost |
| 348 || url.host() == chrome::kChromeUITransparencyHost | 350 || url.host() == chrome::kChromeUITransparencyHost |
| 349 #endif | 351 #endif |
| 350 #if defined(WEBUI_TASK_MANAGER) | 352 #if defined(WEBUI_TASK_MANAGER) |
| 351 || url.host() == chrome::kChromeUITaskManagerHost | 353 || url.host() == chrome::kChromeUITaskManagerHost |
| 352 #endif | 354 #endif |
| 353 ) { | 355 ) { |
| 354 return &NewWebUI<AboutUI>; | 356 return &NewWebUI<AboutUI>; |
| (...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 522 if (page_url.host() == chrome::kChromeUISettingsFrameHost) | 524 if (page_url.host() == chrome::kChromeUISettingsFrameHost) |
| 523 return options2::OptionsUI::GetFaviconResourceBytes(); | 525 return options2::OptionsUI::GetFaviconResourceBytes(); |
| 524 | 526 |
| 525 // Android doesn't use the plugins pages. | 527 // Android doesn't use the plugins pages. |
| 526 if (page_url.host() == chrome::kChromeUIPluginsHost) | 528 if (page_url.host() == chrome::kChromeUIPluginsHost) |
| 527 return PluginsUI::GetFaviconResourceBytes(); | 529 return PluginsUI::GetFaviconResourceBytes(); |
| 528 #endif | 530 #endif |
| 529 | 531 |
| 530 return NULL; | 532 return NULL; |
| 531 } | 533 } |
| OLD | NEW |