OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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/dom_ui/dom_ui_factory.h" | 5 #include "chrome/browser/dom_ui/dom_ui_factory.h" |
6 | 6 |
7 #include "chrome/browser/dom_ui/downloads_ui.h" | 7 #include "chrome/browser/dom_ui/downloads_ui.h" |
8 #include "chrome/browser/dom_ui/devtools_ui.h" | 8 #include "chrome/browser/dom_ui/devtools_ui.h" |
9 #include "chrome/browser/dom_ui/history_ui.h" | 9 #include "chrome/browser/dom_ui/history_ui.h" |
10 #include "chrome/browser/dom_ui/html_dialog_ui.h" | 10 #include "chrome/browser/dom_ui/html_dialog_ui.h" |
11 #include "chrome/browser/dom_ui/new_tab_ui.h" | 11 #include "chrome/browser/dom_ui/new_tab_ui.h" |
12 #include "chrome/browser/dom_ui/print_ui.h" | 12 #include "chrome/browser/dom_ui/print_ui.h" |
13 #include "chrome/browser/extensions/extension_dom_ui.h" | 13 #include "chrome/browser/extensions/extension_dom_ui.h" |
14 #include "chrome/browser/extensions/extensions_service.h" | 14 #include "chrome/browser/extensions/extensions_service.h" |
15 #include "chrome/browser/extensions/extensions_ui.h" | 15 #include "chrome/browser/extensions/extensions_ui.h" |
16 #include "chrome/browser/profile.h" | 16 #include "chrome/browser/profile.h" |
17 #include "chrome/browser/tab_contents/tab_contents.h" | 17 #include "chrome/browser/tab_contents/tab_contents.h" |
18 #include "chrome/common/url_constants.h" | 18 #include "chrome/common/url_constants.h" |
19 #ifdef CHROME_PERSONALIZATION | 19 #ifdef CHROME_PERSONALIZATION |
20 #include "chrome/personalization/personalization.h" | 20 #include "chrome/browser/sync/personalization.h" |
21 #endif | 21 #endif |
22 #include "googleurl/src/gurl.h" | 22 #include "googleurl/src/gurl.h" |
23 | 23 |
24 // Backend for both querying for and creating new DOMUI objects. If you're just | 24 // Backend for both querying for and creating new DOMUI objects. If you're just |
25 // querying whether there's a DOM UI for the given URL, pass NULL for both the | 25 // querying whether there's a DOM UI for the given URL, pass NULL for both the |
26 // web contents and the new_ui. The return value will indiacate whether a DOM UI | 26 // web contents and the new_ui. The return value will indiacate whether a DOM UI |
27 // exists for the given URL. | 27 // exists for the given URL. |
28 // | 28 // |
29 // If you want to create a DOM UI, pass non-NULL pointers for both tab_contents | 29 // If you want to create a DOM UI, pass non-NULL pointers for both tab_contents |
30 // and new_ui. The *new_ui pointer will be filled with the created UI if it | 30 // and new_ui. The *new_ui pointer will be filled with the created UI if it |
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
135 } | 135 } |
136 | 136 |
137 // static | 137 // static |
138 DOMUI* DOMUIFactory::CreateDOMUIForURL(TabContents* tab_contents, | 138 DOMUI* DOMUIFactory::CreateDOMUIForURL(TabContents* tab_contents, |
139 const GURL& url) { | 139 const GURL& url) { |
140 DOMUI* dom_ui; | 140 DOMUI* dom_ui; |
141 if (!CreateDOMUI(url, tab_contents, &dom_ui)) | 141 if (!CreateDOMUI(url, tab_contents, &dom_ui)) |
142 return NULL; | 142 return NULL; |
143 return dom_ui; | 143 return dom_ui; |
144 } | 144 } |
OLD | NEW |