OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_factory.h" | 5 #include "chrome/browser/ui/webui/chrome_web_ui_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/extensions/extension_service.h" | 9 #include "chrome/browser/extensions/extension_service.h" |
10 #include "chrome/browser/extensions/extension_web_ui.h" | 10 #include "chrome/browser/extensions/extension_web_ui.h" |
(...skipping 12 matching lines...) Expand all Loading... |
23 #include "chrome/browser/ui/webui/gpu_internals_ui.h" | 23 #include "chrome/browser/ui/webui/gpu_internals_ui.h" |
24 #include "chrome/browser/ui/webui/history2_ui.h" | 24 #include "chrome/browser/ui/webui/history2_ui.h" |
25 #include "chrome/browser/ui/webui/history_ui.h" | 25 #include "chrome/browser/ui/webui/history_ui.h" |
26 #include "chrome/browser/ui/webui/html_dialog_ui.h" | 26 #include "chrome/browser/ui/webui/html_dialog_ui.h" |
27 #include "chrome/browser/ui/webui/media_internals_ui.h" | 27 #include "chrome/browser/ui/webui/media_internals_ui.h" |
28 #include "chrome/browser/ui/webui/net_internals_ui.h" | 28 #include "chrome/browser/ui/webui/net_internals_ui.h" |
29 #include "chrome/browser/ui/webui/ntp/new_tab_ui.h" | 29 #include "chrome/browser/ui/webui/ntp/new_tab_ui.h" |
30 #include "chrome/browser/ui/webui/options/options_ui.h" | 30 #include "chrome/browser/ui/webui/options/options_ui.h" |
31 #include "chrome/browser/ui/webui/plugins_ui.h" | 31 #include "chrome/browser/ui/webui/plugins_ui.h" |
32 #include "chrome/browser/ui/webui/print_preview_ui.h" | 32 #include "chrome/browser/ui/webui/print_preview_ui.h" |
33 #include "chrome/browser/ui/webui/quota_internals_ui.h" | |
34 #include "chrome/browser/ui/webui/sessions_ui.h" | 33 #include "chrome/browser/ui/webui/sessions_ui.h" |
35 #include "chrome/browser/ui/webui/sync_internals_ui.h" | 34 #include "chrome/browser/ui/webui/sync_internals_ui.h" |
36 #include "chrome/browser/ui/webui/test_chrome_web_ui_factory.h" | 35 #include "chrome/browser/ui/webui/test_chrome_web_ui_factory.h" |
37 #include "chrome/browser/ui/webui/textfields_ui.h" | 36 #include "chrome/browser/ui/webui/textfields_ui.h" |
38 #include "chrome/common/chrome_switches.h" | 37 #include "chrome/common/chrome_switches.h" |
39 #include "chrome/common/extensions/extension_constants.h" | 38 #include "chrome/common/extensions/extension_constants.h" |
40 #include "chrome/common/url_constants.h" | 39 #include "chrome/common/url_constants.h" |
41 #include "content/browser/tab_contents/tab_contents.h" | 40 #include "content/browser/tab_contents/tab_contents.h" |
42 #include "content/browser/webui/web_ui.h" | 41 #include "content/browser/webui/web_ui.h" |
43 #include "googleurl/src/gurl.h" | 42 #include "googleurl/src/gurl.h" |
(...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
173 if (url.host() == chrome::kChromeUINetInternalsHost) | 172 if (url.host() == chrome::kChromeUINetInternalsHost) |
174 return &NewWebUI<NetInternalsUI>; | 173 return &NewWebUI<NetInternalsUI>; |
175 if (url.host() == chrome::kChromeUIPluginsHost) | 174 if (url.host() == chrome::kChromeUIPluginsHost) |
176 return &NewWebUI<PluginsUI>; | 175 return &NewWebUI<PluginsUI>; |
177 if (url.host() == chrome::kChromeUISessionsHost) | 176 if (url.host() == chrome::kChromeUISessionsHost) |
178 return &NewWebUI<SessionsUI>; | 177 return &NewWebUI<SessionsUI>; |
179 if (url.host() == chrome::kChromeUISyncInternalsHost) | 178 if (url.host() == chrome::kChromeUISyncInternalsHost) |
180 return &NewWebUI<SyncInternalsUI>; | 179 return &NewWebUI<SyncInternalsUI>; |
181 if (url.host() == chrome::kChromeUISettingsHost) | 180 if (url.host() == chrome::kChromeUISettingsHost) |
182 return &NewWebUI<OptionsUI>; | 181 return &NewWebUI<OptionsUI>; |
183 if (url.host() == chrome::kChromeUIQuotaInternalsHost) | |
184 return &NewWebUI<QuotaInternalsUI>; | |
185 | 182 |
186 #if defined(OS_CHROMEOS) | 183 #if defined(OS_CHROMEOS) |
187 if (url.host() == chrome::kChromeUIChooseMobileNetworkHost) | 184 if (url.host() == chrome::kChromeUIChooseMobileNetworkHost) |
188 return &NewWebUI<chromeos::ChooseMobileNetworkUI>; | 185 return &NewWebUI<chromeos::ChooseMobileNetworkUI>; |
189 if (url.host() == chrome::kChromeUICollectedCookiesHost || | 186 if (url.host() == chrome::kChromeUICollectedCookiesHost || |
190 url.host() == chrome::kChromeUIHttpAuthHost) { | 187 url.host() == chrome::kChromeUIHttpAuthHost) { |
191 return &NewWebUI<ConstrainedHtmlUI>; | 188 return &NewWebUI<ConstrainedHtmlUI>; |
192 } | 189 } |
193 if (url.host() == chrome::kChromeUIActiveDownloadsHost) | 190 if (url.host() == chrome::kChromeUIActiveDownloadsHost) |
194 return &NewWebUI<ActiveDownloadsUI>; | 191 return &NewWebUI<ActiveDownloadsUI>; |
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
365 return FlashUI::GetFaviconResourceBytes(); | 362 return FlashUI::GetFaviconResourceBytes(); |
366 | 363 |
367 if (page_url.host() == chrome::kChromeUISettingsHost) | 364 if (page_url.host() == chrome::kChromeUISettingsHost) |
368 return OptionsUI::GetFaviconResourceBytes(); | 365 return OptionsUI::GetFaviconResourceBytes(); |
369 | 366 |
370 if (page_url.host() == chrome::kChromeUIPluginsHost) | 367 if (page_url.host() == chrome::kChromeUIPluginsHost) |
371 return PluginsUI::GetFaviconResourceBytes(); | 368 return PluginsUI::GetFaviconResourceBytes(); |
372 | 369 |
373 return NULL; | 370 return NULL; |
374 } | 371 } |
OLD | NEW |