| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 #ifndef BROWSER_DOM_UI_CHROME_URL_DATA_MANAGER_H__ | 5 #ifndef BROWSER_DOM_UI_CHROME_URL_DATA_MANAGER_H__ |
| 6 #define BROWSER_DOM_UI_CHROME_URL_DATA_MANAGER_H__ | 6 #define BROWSER_DOM_UI_CHROME_URL_DATA_MANAGER_H__ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| 11 #include "base/task.h" | 11 #include "base/task.h" |
| 12 #include "chrome/common/ref_counted_util.h" | 12 #include "chrome/common/ref_counted_util.h" |
| 13 | 13 |
| 14 class GURL; | 14 class GURL; |
| 15 class MessageLoop; | 15 class MessageLoop; |
| 16 class URLRequest; | 16 class URLRequest; |
| 17 class URLRequestJob; | 17 class URLRequestJob; |
| 18 | 18 |
| 19 // To serve dynamic data off of chrome-resource: URLs, implement the | 19 // To serve dynamic data off of chrome: URLs, implement the |
| 20 // ChromeURLDataManager::DataSource interface and register your handler | 20 // ChromeURLDataManager::DataSource interface and register your handler |
| 21 // with AddDataSource. | 21 // with AddDataSource. |
| 22 | 22 |
| 23 // ChromeURLDataManager lives on the IO thread, so any interfacing with | 23 // ChromeURLDataManager lives on the IO thread, so any interfacing with |
| 24 // it from the UI thread needs to go through an InvokeLater. | 24 // it from the UI thread needs to go through an InvokeLater. |
| 25 class ChromeURLDataManager { | 25 class ChromeURLDataManager { |
| 26 public: | 26 public: |
| 27 ChromeURLDataManager(); | 27 ChromeURLDataManager(); |
| 28 ~ChromeURLDataManager(); | 28 ~ChromeURLDataManager(); |
| 29 | 29 |
| (...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 139 | 139 |
| 140 // The single global instance of ChromeURLDataManager. | 140 // The single global instance of ChromeURLDataManager. |
| 141 extern ChromeURLDataManager chrome_url_data_manager; | 141 extern ChromeURLDataManager chrome_url_data_manager; |
| 142 | 142 |
| 143 // Register our special URL handler under our special URL scheme. | 143 // Register our special URL handler under our special URL scheme. |
| 144 // Must be done once at startup. | 144 // Must be done once at startup. |
| 145 void RegisterURLRequestChromeJob(); | 145 void RegisterURLRequestChromeJob(); |
| 146 | 146 |
| 147 #endif // BROWSER_DOM_UI_CHROME_URL_DATA_MANAGER_H__ | 147 #endif // BROWSER_DOM_UI_CHROME_URL_DATA_MANAGER_H__ |
| 148 | 148 |
| OLD | NEW |