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 #ifndef CHROME_RENDERER_CHROME_CONTENT_RENDERER_CLIENT_H_ | 5 #ifndef CHROME_RENDERER_CHROME_CONTENT_RENDERER_CLIENT_H_ |
6 #define CHROME_RENDERER_CHROME_CONTENT_RENDERER_CLIENT_H_ | 6 #define CHROME_RENDERER_CHROME_CONTENT_RENDERER_CLIENT_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 24 matching lines...) Expand all Loading... |
35 class ChromeContentRendererClient : public content::ContentRendererClient { | 35 class ChromeContentRendererClient : public content::ContentRendererClient { |
36 public: | 36 public: |
37 ChromeContentRendererClient(); | 37 ChromeContentRendererClient(); |
38 virtual ~ChromeContentRendererClient(); | 38 virtual ~ChromeContentRendererClient(); |
39 | 39 |
40 virtual void RenderThreadStarted() OVERRIDE; | 40 virtual void RenderThreadStarted() OVERRIDE; |
41 virtual void RenderViewCreated(RenderView* render_view) OVERRIDE; | 41 virtual void RenderViewCreated(RenderView* render_view) OVERRIDE; |
42 virtual void SetNumberOfViews(int number_of_views) OVERRIDE; | 42 virtual void SetNumberOfViews(int number_of_views) OVERRIDE; |
43 virtual SkBitmap* GetSadPluginBitmap() OVERRIDE; | 43 virtual SkBitmap* GetSadPluginBitmap() OVERRIDE; |
44 virtual std::string GetDefaultEncoding() OVERRIDE; | 44 virtual std::string GetDefaultEncoding() OVERRIDE; |
45 virtual WebKit::WebPlugin* CreatePlugin( | 45 virtual bool OverrideCreatePlugin( |
46 RenderView* render_view, | 46 RenderView* render_view, |
47 WebKit::WebFrame* frame, | 47 WebKit::WebFrame* frame, |
48 const WebKit::WebPluginParams& params) OVERRIDE; | 48 const WebKit::WebPluginParams& params, |
| 49 WebKit::WebPlugin** plugin) OVERRIDE; |
49 virtual void ShowErrorPage(RenderView* render_view, | 50 virtual void ShowErrorPage(RenderView* render_view, |
50 WebKit::WebFrame* frame, | 51 WebKit::WebFrame* frame, |
51 int http_status_code) OVERRIDE; | 52 int http_status_code) OVERRIDE; |
52 virtual std::string GetNavigationErrorHtml( | 53 virtual std::string GetNavigationErrorHtml( |
53 const WebKit::WebURLRequest& failed_request, | 54 const WebKit::WebURLRequest& failed_request, |
54 const WebKit::WebURLError& error) OVERRIDE; | 55 const WebKit::WebURLError& error) OVERRIDE; |
55 virtual bool RunIdleHandlerWhenWidgetsHidden() OVERRIDE; | 56 virtual bool RunIdleHandlerWhenWidgetsHidden() OVERRIDE; |
56 virtual bool AllowPopup(const GURL& creator) OVERRIDE; | 57 virtual bool AllowPopup(const GURL& creator) OVERRIDE; |
57 virtual bool ShouldFork(WebKit::WebFrame* frame, | 58 virtual bool ShouldFork(WebKit::WebFrame* frame, |
58 const GURL& url, | 59 const GURL& url, |
(...skipping 27 matching lines...) Expand all Loading... |
86 const std::string& value) OVERRIDE; | 87 const std::string& value) OVERRIDE; |
87 | 88 |
88 // For testing. | 89 // For testing. |
89 void SetExtensionDispatcher(ExtensionDispatcher* extension_dispatcher); | 90 void SetExtensionDispatcher(ExtensionDispatcher* extension_dispatcher); |
90 | 91 |
91 // Called in low-memory conditions to dump the memory used by the spellchecker | 92 // Called in low-memory conditions to dump the memory used by the spellchecker |
92 // and start over. | 93 // and start over. |
93 void OnPurgeMemory(); | 94 void OnPurgeMemory(); |
94 | 95 |
95 private: | 96 private: |
96 WebKit::WebPlugin* CreatePluginImpl( | 97 WebKit::WebPlugin* CreatePlugin( |
97 RenderView* render_view, | 98 RenderView* render_view, |
98 WebKit::WebFrame* frame, | 99 WebKit::WebFrame* frame, |
99 const WebKit::WebPluginParams& params, | 100 const WebKit::WebPluginParams& params, |
100 bool* is_default_plugin); | 101 bool* is_default_plugin); |
101 | 102 |
102 WebKit::WebPlugin* CreatePluginPlaceholder( | 103 WebKit::WebPlugin* CreatePluginPlaceholder( |
103 RenderView* render_view, | 104 RenderView* render_view, |
104 WebKit::WebFrame* frame, | 105 WebKit::WebFrame* frame, |
105 const WebKit::WebPluginParams& params, | 106 const WebKit::WebPluginParams& params, |
106 const webkit::npapi::PluginGroup& group, | 107 const webkit::npapi::PluginGroup& group, |
(...skipping 16 matching lines...) Expand all Loading... |
123 // The SpellCheckProvider is a RenderViewObserver, and handles its own | 124 // The SpellCheckProvider is a RenderViewObserver, and handles its own |
124 // destruction. | 125 // destruction. |
125 SpellCheckProvider* spellcheck_provider_; | 126 SpellCheckProvider* spellcheck_provider_; |
126 scoped_ptr<VisitedLinkSlave> visited_link_slave_; | 127 scoped_ptr<VisitedLinkSlave> visited_link_slave_; |
127 scoped_ptr<safe_browsing::PhishingClassifierFilter> phishing_classifier_; | 128 scoped_ptr<safe_browsing::PhishingClassifierFilter> phishing_classifier_; |
128 }; | 129 }; |
129 | 130 |
130 } // namespace chrome | 131 } // namespace chrome |
131 | 132 |
132 #endif // CHROME_RENDERER_CHROME_CONTENT_RENDERER_CLIENT_H_ | 133 #endif // CHROME_RENDERER_CHROME_CONTENT_RENDERER_CLIENT_H_ |
OLD | NEW |