Chromium Code Reviews| 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> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 44 #include "chrome/browser/ui/webui/profiler_ui.h" | 44 #include "chrome/browser/ui/webui/profiler_ui.h" |
| 45 #include "chrome/browser/ui/webui/settings/md_settings_ui.h" | 45 #include "chrome/browser/ui/webui/settings/md_settings_ui.h" |
| 46 #include "chrome/browser/ui/webui/signin/inline_login_ui.h" | 46 #include "chrome/browser/ui/webui/signin/inline_login_ui.h" |
| 47 #include "chrome/browser/ui/webui/signin/profile_signin_confirmation_ui.h" | 47 #include "chrome/browser/ui/webui/signin/profile_signin_confirmation_ui.h" |
| 48 #include "chrome/browser/ui/webui/signin/user_manager_ui.h" | 48 #include "chrome/browser/ui/webui/signin/user_manager_ui.h" |
| 49 #include "chrome/browser/ui/webui/signin_internals_ui.h" | 49 #include "chrome/browser/ui/webui/signin_internals_ui.h" |
| 50 #include "chrome/browser/ui/webui/sync_internals_ui.h" | 50 #include "chrome/browser/ui/webui/sync_internals_ui.h" |
| 51 #include "chrome/browser/ui/webui/translate_internals/translate_internals_ui.h" | 51 #include "chrome/browser/ui/webui/translate_internals/translate_internals_ui.h" |
| 52 #include "chrome/browser/ui/webui/user_actions/user_actions_ui.h" | 52 #include "chrome/browser/ui/webui/user_actions/user_actions_ui.h" |
| 53 #include "chrome/browser/ui/webui/version_ui.h" | 53 #include "chrome/browser/ui/webui/version_ui.h" |
| 54 #include "chrome/browser/ui/webui/web_component_test_ui.h" | |
| 54 #include "chrome/common/chrome_switches.h" | 55 #include "chrome/common/chrome_switches.h" |
| 55 #include "chrome/common/pref_names.h" | 56 #include "chrome/common/pref_names.h" |
| 56 #include "chrome/common/url_constants.h" | 57 #include "chrome/common/url_constants.h" |
| 57 #include "components/dom_distiller/core/dom_distiller_constants.h" | 58 #include "components/dom_distiller/core/dom_distiller_constants.h" |
| 58 #include "components/dom_distiller/core/dom_distiller_service.h" | 59 #include "components/dom_distiller/core/dom_distiller_service.h" |
| 59 #include "components/dom_distiller/core/url_constants.h" | 60 #include "components/dom_distiller/core/url_constants.h" |
| 60 #include "components/dom_distiller/webui/dom_distiller_ui.h" | 61 #include "components/dom_distiller/webui/dom_distiller_ui.h" |
| 61 #include "components/favicon/core/favicon_service.h" | 62 #include "components/favicon/core/favicon_service.h" |
| 62 #include "components/favicon_base/favicon_util.h" | 63 #include "components/favicon_base/favicon_util.h" |
| 63 #include "components/favicon_base/select_favicon_frames.h" | 64 #include "components/favicon_base/select_favicon_frames.h" |
| (...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 294 !url.SchemeIs(content::kChromeUIScheme)) { | 295 !url.SchemeIs(content::kChromeUIScheme)) { |
| 295 return NULL; | 296 return NULL; |
| 296 } | 297 } |
| 297 | 298 |
| 298 /**************************************************************************** | 299 /**************************************************************************** |
| 299 * Please keep this in alphabetical order. If #ifs or special logics are | 300 * Please keep this in alphabetical order. If #ifs or special logics are |
| 300 * required, add it below in the appropriate section. | 301 * required, add it below in the appropriate section. |
| 301 ***************************************************************************/ | 302 ***************************************************************************/ |
| 302 // We must compare hosts only since some of the Web UIs append extra stuff | 303 // We must compare hosts only since some of the Web UIs append extra stuff |
| 303 // after the host name. | 304 // after the host name. |
| 305 if (url.host() == chrome::kChromeUIWebComponentTestHost) | |
| 306 return &NewWebUI<WebComponentTestUI>; | |
|
stevenjb
2015/05/05 22:25:00
Either alphabetize this or put a comment above thi
michaelpg
2015/05/08 16:57:39
Done. (No reason for it to be first, I just forgot
| |
| 304 // All platform builds of Chrome will need to have a cloud printing | 307 // All platform builds of Chrome will need to have a cloud printing |
| 305 // dialog as backup. It's just that on Chrome OS, it's the only | 308 // dialog as backup. It's just that on Chrome OS, it's the only |
| 306 // print dialog. | 309 // print dialog. |
| 307 if (url.host() == chrome::kChromeUICloudPrintResourcesHost) | 310 if (url.host() == chrome::kChromeUICloudPrintResourcesHost) |
| 308 return &NewWebUI<ExternalWebDialogUI>; | 311 return &NewWebUI<ExternalWebDialogUI>; |
| 309 if (url.host() == chrome::kChromeUICloudPrintSetupHost) | 312 if (url.host() == chrome::kChromeUICloudPrintSetupHost) |
| 310 return &NewWebUI<WebDialogUI>; | 313 return &NewWebUI<WebDialogUI>; |
| 311 if (url.host() == chrome::kChromeUIComponentsHost) | 314 if (url.host() == chrome::kChromeUIComponentsHost) |
| 312 return &NewWebUI<ComponentsUI>; | 315 return &NewWebUI<ComponentsUI>; |
| 313 if (url.spec() == chrome::kChromeUIConstrainedHTMLTestURL) | 316 if (url.spec() == chrome::kChromeUIConstrainedHTMLTestURL) |
| (...skipping 442 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 756 #endif | 759 #endif |
| 757 | 760 |
| 758 // Android doesn't use the plugins pages. | 761 // Android doesn't use the plugins pages. |
| 759 if (page_url.host() == chrome::kChromeUIPluginsHost) | 762 if (page_url.host() == chrome::kChromeUIPluginsHost) |
| 760 return PluginsUI::GetFaviconResourceBytes(scale_factor); | 763 return PluginsUI::GetFaviconResourceBytes(scale_factor); |
| 761 | 764 |
| 762 #endif | 765 #endif |
| 763 | 766 |
| 764 return NULL; | 767 return NULL; |
| 765 } | 768 } |
| OLD | NEW |