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 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_DOM_UI_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_DOM_UI_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_DOM_UI_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_DOM_UI_H_ |
7 | 7 |
8 #include "base/scoped_ptr.h" | 8 #include "base/scoped_ptr.h" |
9 #include "chrome/browser/dom_ui/dom_ui.h" | 9 #include "chrome/browser/dom_ui/dom_ui.h" |
10 #include "chrome/browser/extensions/extension_function_dispatcher.h" | 10 #include "chrome/browser/extensions/extension_function_dispatcher.h" |
(...skipping 11 matching lines...) Expand all Loading... |
22 explicit ExtensionDOMUI(TabContents* tab_contents); | 22 explicit ExtensionDOMUI(TabContents* tab_contents); |
23 | 23 |
24 ExtensionFunctionDispatcher* extension_function_dispatcher() const { | 24 ExtensionFunctionDispatcher* extension_function_dispatcher() const { |
25 return extension_function_dispatcher_.get(); | 25 return extension_function_dispatcher_.get(); |
26 } | 26 } |
27 | 27 |
28 // DOMUI | 28 // DOMUI |
29 virtual void RenderViewCreated(RenderViewHost* render_view_host); | 29 virtual void RenderViewCreated(RenderViewHost* render_view_host); |
30 virtual void RenderViewReused(RenderViewHost* render_view_host); | 30 virtual void RenderViewReused(RenderViewHost* render_view_host); |
31 virtual void ProcessDOMUIMessage(const std::string& message, | 31 virtual void ProcessDOMUIMessage(const std::string& message, |
32 const std::string& content, | 32 const Value* content, |
33 int request_id, | 33 int request_id, |
34 bool has_callback); | 34 bool has_callback); |
35 | 35 |
36 // ExtensionFunctionDispatcher::Delegate | 36 // ExtensionFunctionDispatcher::Delegate |
37 virtual Browser* GetBrowser(); | 37 virtual Browser* GetBrowser(); |
38 | 38 |
39 // BrowserURLHandler | 39 // BrowserURLHandler |
40 static bool HandleChromeURLOverride(GURL* url, Profile* profile); | 40 static bool HandleChromeURLOverride(GURL* url, Profile* profile); |
41 | 41 |
42 // Register and unregister a dictionary of one or more overrides. | 42 // Register and unregister a dictionary of one or more overrides. |
(...skipping 20 matching lines...) Expand all Loading... |
63 | 63 |
64 // When the RenderViewHost changes (RenderViewCreated and RenderViewReused), | 64 // When the RenderViewHost changes (RenderViewCreated and RenderViewReused), |
65 // we need to reset the ExtensionFunctionDispatcher so it's talking to the | 65 // we need to reset the ExtensionFunctionDispatcher so it's talking to the |
66 // right one, as well as being linked to the correct URL. | 66 // right one, as well as being linked to the correct URL. |
67 void ResetExtensionFunctionDispatcher(RenderViewHost* render_view_host); | 67 void ResetExtensionFunctionDispatcher(RenderViewHost* render_view_host); |
68 | 68 |
69 scoped_ptr<ExtensionFunctionDispatcher> extension_function_dispatcher_; | 69 scoped_ptr<ExtensionFunctionDispatcher> extension_function_dispatcher_; |
70 }; | 70 }; |
71 | 71 |
72 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_DOM_UI_H_ | 72 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_DOM_UI_H_ |
OLD | NEW |