| 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 <vector> |
| 8 |
| 7 #include "base/bind.h" | 9 #include "base/bind.h" |
| 8 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| 9 #include "base/location.h" | 11 #include "base/location.h" |
| 10 #include "base/message_loop/message_loop_proxy.h" | 12 #include "base/message_loop/message_loop_proxy.h" |
| 11 #include "base/prefs/pref_service.h" | 13 #include "base/prefs/pref_service.h" |
| 12 #include "chrome/browser/about_flags.h" | 14 #include "chrome/browser/about_flags.h" |
| 13 #include "chrome/browser/bookmarks/enhanced_bookmarks_features.h" | 15 #include "chrome/browser/bookmarks/enhanced_bookmarks_features.h" |
| 14 #include "chrome/browser/dom_distiller/dom_distiller_service_factory.h" | 16 #include "chrome/browser/dom_distiller/dom_distiller_service_factory.h" |
| 15 #include "chrome/browser/extensions/extension_web_ui.h" | 17 #include "chrome/browser/extensions/extension_web_ui.h" |
| 16 #include "chrome/browser/favicon/favicon_service.h" | 18 #include "chrome/browser/favicon/favicon_service.h" |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 108 #endif | 110 #endif |
| 109 | 111 |
| 110 #if defined(OS_CHROMEOS) | 112 #if defined(OS_CHROMEOS) |
| 111 #include "chrome/browser/ui/webui/chromeos/bluetooth_pairing_ui.h" | 113 #include "chrome/browser/ui/webui/chromeos/bluetooth_pairing_ui.h" |
| 112 #include "chrome/browser/ui/webui/chromeos/certificate_manager_dialog_ui.h" | 114 #include "chrome/browser/ui/webui/chromeos/certificate_manager_dialog_ui.h" |
| 113 #include "chrome/browser/ui/webui/chromeos/charger_replacement_ui.h" | 115 #include "chrome/browser/ui/webui/chromeos/charger_replacement_ui.h" |
| 114 #include "chrome/browser/ui/webui/chromeos/choose_mobile_network_ui.h" | 116 #include "chrome/browser/ui/webui/chromeos/choose_mobile_network_ui.h" |
| 115 #include "chrome/browser/ui/webui/chromeos/cryptohome_ui.h" | 117 #include "chrome/browser/ui/webui/chromeos/cryptohome_ui.h" |
| 116 #include "chrome/browser/ui/webui/chromeos/drive_internals_ui.h" | 118 #include "chrome/browser/ui/webui/chromeos/drive_internals_ui.h" |
| 117 #include "chrome/browser/ui/webui/chromeos/first_run/first_run_ui.h" | 119 #include "chrome/browser/ui/webui/chromeos/first_run/first_run_ui.h" |
| 118 #include "chrome/browser/ui/webui/chromeos/fsp_internals_ui.h" | |
| 119 #include "chrome/browser/ui/webui/chromeos/imageburner/imageburner_ui.h" | 120 #include "chrome/browser/ui/webui/chromeos/imageburner/imageburner_ui.h" |
| 120 #include "chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.h" | 121 #include "chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.h" |
| 121 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" | 122 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" |
| 122 #include "chrome/browser/ui/webui/chromeos/mobile_setup_ui.h" | 123 #include "chrome/browser/ui/webui/chromeos/mobile_setup_ui.h" |
| 123 #include "chrome/browser/ui/webui/chromeos/network_ui.h" | 124 #include "chrome/browser/ui/webui/chromeos/network_ui.h" |
| 124 #include "chrome/browser/ui/webui/chromeos/nfc_debug_ui.h" | 125 #include "chrome/browser/ui/webui/chromeos/nfc_debug_ui.h" |
| 125 #include "chrome/browser/ui/webui/chromeos/power_ui.h" | 126 #include "chrome/browser/ui/webui/chromeos/power_ui.h" |
| 127 #include "chrome/browser/ui/webui/chromeos/provided_file_systems_ui.h" |
| 126 #include "chrome/browser/ui/webui/chromeos/proxy_settings_ui.h" | 128 #include "chrome/browser/ui/webui/chromeos/proxy_settings_ui.h" |
| 127 #include "chrome/browser/ui/webui/chromeos/salsa_ui.h" | 129 #include "chrome/browser/ui/webui/chromeos/salsa_ui.h" |
| 128 #include "chrome/browser/ui/webui/chromeos/set_time_ui.h" | 130 #include "chrome/browser/ui/webui/chromeos/set_time_ui.h" |
| 129 #include "chrome/browser/ui/webui/chromeos/sim_unlock_ui.h" | 131 #include "chrome/browser/ui/webui/chromeos/sim_unlock_ui.h" |
| 130 #include "chrome/browser/ui/webui/chromeos/slow_trace_ui.h" | 132 #include "chrome/browser/ui/webui/chromeos/slow_trace_ui.h" |
| 131 #include "chrome/browser/ui/webui/chromeos/slow_ui.h" | 133 #include "chrome/browser/ui/webui/chromeos/slow_ui.h" |
| 132 #endif | 134 #endif |
| 133 | 135 |
| 134 #if defined(USE_AURA) | 136 #if defined(USE_AURA) |
| 135 #include "chrome/browser/ui/webui/gesture_config_ui.h" | 137 #include "chrome/browser/ui/webui/gesture_config_ui.h" |
| (...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 407 if (url.host() == chrome::kChromeUICertificateManagerHost) | 409 if (url.host() == chrome::kChromeUICertificateManagerHost) |
| 408 return &NewWebUI<chromeos::CertificateManagerDialogUI>; | 410 return &NewWebUI<chromeos::CertificateManagerDialogUI>; |
| 409 if (url.host() == chrome::kChromeUIChargerReplacementHost) | 411 if (url.host() == chrome::kChromeUIChargerReplacementHost) |
| 410 return &NewWebUI<chromeos::ChargerReplacementUI>; | 412 return &NewWebUI<chromeos::ChargerReplacementUI>; |
| 411 if (url.host() == chrome::kChromeUIChooseMobileNetworkHost) | 413 if (url.host() == chrome::kChromeUIChooseMobileNetworkHost) |
| 412 return &NewWebUI<chromeos::ChooseMobileNetworkUI>; | 414 return &NewWebUI<chromeos::ChooseMobileNetworkUI>; |
| 413 if (url.host() == chrome::kChromeUICryptohomeHost) | 415 if (url.host() == chrome::kChromeUICryptohomeHost) |
| 414 return &NewWebUI<chromeos::CryptohomeUI>; | 416 return &NewWebUI<chromeos::CryptohomeUI>; |
| 415 if (url.host() == chrome::kChromeUIDriveInternalsHost) | 417 if (url.host() == chrome::kChromeUIDriveInternalsHost) |
| 416 return &NewWebUI<chromeos::DriveInternalsUI>; | 418 return &NewWebUI<chromeos::DriveInternalsUI>; |
| 417 if (url.host() == chrome::kChromeUIFSPInternalsHost) | |
| 418 return &NewWebUI<chromeos::FSPInternalsUI>; | |
| 419 if (url.host() == chrome::kChromeUIFirstRunHost) | 419 if (url.host() == chrome::kChromeUIFirstRunHost) |
| 420 return &NewWebUI<chromeos::FirstRunUI>; | 420 return &NewWebUI<chromeos::FirstRunUI>; |
| 421 if (url.host() == chrome::kChromeUIImageBurnerHost) | 421 if (url.host() == chrome::kChromeUIImageBurnerHost) |
| 422 return &NewWebUI<ImageBurnUI>; | 422 return &NewWebUI<ImageBurnUI>; |
| 423 if (url.host() == chrome::kChromeUIKeyboardOverlayHost) | 423 if (url.host() == chrome::kChromeUIKeyboardOverlayHost) |
| 424 return &NewWebUI<KeyboardOverlayUI>; | 424 return &NewWebUI<KeyboardOverlayUI>; |
| 425 if (url.host() == chrome::kChromeUIMobileSetupHost) | 425 if (url.host() == chrome::kChromeUIMobileSetupHost) |
| 426 return &NewWebUI<MobileSetupUI>; | 426 return &NewWebUI<MobileSetupUI>; |
| 427 if (url.host() == chrome::kChromeUINfcDebugHost) | 427 if (url.host() == chrome::kChromeUINfcDebugHost) |
| 428 return &NewWebUI<chromeos::NfcDebugUI>; | 428 return &NewWebUI<chromeos::NfcDebugUI>; |
| 429 if (url.host() == chrome::kChromeUIOobeHost) | 429 if (url.host() == chrome::kChromeUIOobeHost) |
| 430 return &NewWebUI<chromeos::OobeUI>; | 430 return &NewWebUI<chromeos::OobeUI>; |
| 431 if (url.host() == chrome::kChromeUIProvidedFileSystemsHost) |
| 432 return &NewWebUI<chromeos::ProvidedFileSystemsUI>; |
| 431 if (url.host() == chrome::kChromeUIProxySettingsHost) | 433 if (url.host() == chrome::kChromeUIProxySettingsHost) |
| 432 return &NewWebUI<chromeos::ProxySettingsUI>; | 434 return &NewWebUI<chromeos::ProxySettingsUI>; |
| 433 if (url.host() == chrome::kChromeUISalsaHost) | 435 if (url.host() == chrome::kChromeUISalsaHost) |
| 434 return &NewWebUI<SalsaUI>; | 436 return &NewWebUI<SalsaUI>; |
| 435 if (url.host() == chrome::kChromeUISetTimeHost) | 437 if (url.host() == chrome::kChromeUISetTimeHost) |
| 436 return &NewWebUI<chromeos::SetTimeUI>; | 438 return &NewWebUI<chromeos::SetTimeUI>; |
| 437 if (url.host() == chrome::kChromeUISimUnlockHost) | 439 if (url.host() == chrome::kChromeUISimUnlockHost) |
| 438 return &NewWebUI<chromeos::SimUnlockUI>; | 440 return &NewWebUI<chromeos::SimUnlockUI>; |
| 439 if (url.host() == chrome::kChromeUISlowHost) | 441 if (url.host() == chrome::kChromeUISlowHost) |
| 440 return &NewWebUI<chromeos::SlowUI>; | 442 return &NewWebUI<chromeos::SlowUI>; |
| (...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 685 #endif | 687 #endif |
| 686 | 688 |
| 687 // Android doesn't use the plugins pages. | 689 // Android doesn't use the plugins pages. |
| 688 if (page_url.host() == chrome::kChromeUIPluginsHost) | 690 if (page_url.host() == chrome::kChromeUIPluginsHost) |
| 689 return PluginsUI::GetFaviconResourceBytes(scale_factor); | 691 return PluginsUI::GetFaviconResourceBytes(scale_factor); |
| 690 | 692 |
| 691 #endif | 693 #endif |
| 692 | 694 |
| 693 return NULL; | 695 return NULL; |
| 694 } | 696 } |
| OLD | NEW |