OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CONTENT_PUBLIC_RENDERER_CONTENT_RENDERER_CLIENT_H_ | 5 #ifndef CONTENT_PUBLIC_RENDERER_CONTENT_RENDERER_CLIENT_H_ |
6 #define CONTENT_PUBLIC_RENDERER_CONTENT_RENDERER_CLIENT_H_ | 6 #define CONTENT_PUBLIC_RENDERER_CONTENT_RENDERER_CLIENT_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/string16.h" | 10 #include "base/string16.h" |
11 #include "base/memory/weak_ptr.h" | 11 #include "base/memory/weak_ptr.h" |
12 #include "ipc/ipc_message.h" | 12 #include "ipc/ipc_message.h" |
13 #include "content/public/common/content_client.h" | 13 #include "content/public/common/content_client.h" |
14 #include "content/public/common/page_transition_types.h" | 14 #include "content/public/common/page_transition_types.h" |
15 #include "third_party/WebKit/Source/WebKit/chromium/public/WebNavigationPolicy.h
" | 15 #include "third_party/WebKit/Source/WebKit/chromium/public/WebNavigationPolicy.h
" |
16 #include "third_party/WebKit/Source/WebKit/chromium/public/WebNavigationType.h" | 16 #include "third_party/WebKit/Source/WebKit/chromium/public/WebNavigationType.h" |
17 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPageVisibilityStat
e.h" | 17 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPageVisibilityStat
e.h" |
18 #include "v8/include/v8.h" | 18 #include "v8/include/v8.h" |
19 | 19 |
20 class FilePath; | 20 class FilePath; |
21 class GURL; | 21 class GURL; |
22 class SkBitmap; | 22 class SkBitmap; |
23 | 23 |
24 namespace WebKit { | 24 namespace WebKit { |
25 class WebAudioSourceProvider; | |
26 class WebFrame; | 25 class WebFrame; |
27 class WebMediaPlayerClient; | 26 class WebMediaPlayerClient; |
28 class WebPlugin; | 27 class WebPlugin; |
29 class WebURLRequest; | 28 class WebURLRequest; |
30 struct WebPluginParams; | 29 struct WebPluginParams; |
31 struct WebURLError; | 30 struct WebURLError; |
32 } | 31 } |
33 | 32 |
34 namespace webkit { | 33 namespace webkit { |
35 namespace ppapi { | 34 namespace ppapi { |
36 class PpapiInterfaceFactoryManager; | 35 class PpapiInterfaceFactoryManager; |
37 } | 36 } |
38 struct WebPluginInfo; | 37 struct WebPluginInfo; |
39 } | 38 } |
40 | 39 |
41 namespace media { | |
42 class AudioRendererSink; | |
43 class FilterCollection; | |
44 class MediaLog; | |
45 class MessageLoopFactory; | |
46 } | |
47 | |
48 namespace webkit_media { | 40 namespace webkit_media { |
49 class MediaStreamClient; | |
50 class WebMediaPlayerDelegate; | 41 class WebMediaPlayerDelegate; |
51 class WebMediaPlayerImpl; | 42 class WebMediaPlayerImpl; |
| 43 class WebMediaPlayerParams; |
52 } | 44 } |
53 | 45 |
54 namespace content { | 46 namespace content { |
55 | 47 |
56 class RenderView; | 48 class RenderView; |
57 | 49 |
58 // Embedder API for participating in renderer logic. | 50 // Embedder API for participating in renderer logic. |
59 class CONTENT_EXPORT ContentRendererClient { | 51 class CONTENT_EXPORT ContentRendererClient { |
60 public: | 52 public: |
61 virtual ~ContentRendererClient() {} | 53 virtual ~ContentRendererClient() {} |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
115 std::string* error_html, | 107 std::string* error_html, |
116 string16* error_description) {} | 108 string16* error_description) {} |
117 | 109 |
118 // Allows embedder to override creating a WebMediaPlayerImpl. If it returns | 110 // Allows embedder to override creating a WebMediaPlayerImpl. If it returns |
119 // NULL the content layer will create the media player. | 111 // NULL the content layer will create the media player. |
120 virtual webkit_media::WebMediaPlayerImpl* OverrideCreateWebMediaPlayer( | 112 virtual webkit_media::WebMediaPlayerImpl* OverrideCreateWebMediaPlayer( |
121 RenderView* render_view, | 113 RenderView* render_view, |
122 WebKit::WebFrame* frame, | 114 WebKit::WebFrame* frame, |
123 WebKit::WebMediaPlayerClient* client, | 115 WebKit::WebMediaPlayerClient* client, |
124 base::WeakPtr<webkit_media::WebMediaPlayerDelegate> delegate, | 116 base::WeakPtr<webkit_media::WebMediaPlayerDelegate> delegate, |
125 media::FilterCollection* collection, | 117 const webkit_media::WebMediaPlayerParams& params); |
126 WebKit::WebAudioSourceProvider* audio_source_provider, | |
127 media::AudioRendererSink* audio_renderer_sink, | |
128 media::MessageLoopFactory* message_loop_factory, | |
129 webkit_media::MediaStreamClient* media_stream_client, | |
130 media::MediaLog* media_log); | |
131 | 118 |
132 // Returns true if the renderer process should schedule the idle handler when | 119 // Returns true if the renderer process should schedule the idle handler when |
133 // all widgets are hidden. | 120 // all widgets are hidden. |
134 virtual bool RunIdleHandlerWhenWidgetsHidden(); | 121 virtual bool RunIdleHandlerWhenWidgetsHidden(); |
135 | 122 |
136 // Returns true if a popup window should be allowed. | 123 // Returns true if a popup window should be allowed. |
137 virtual bool AllowPopup(); | 124 virtual bool AllowPopup(); |
138 | 125 |
139 // Returns true if the navigation was handled by the embedder and should be | 126 // Returns true if the navigation was handled by the embedder and should be |
140 // ignored by WebKit. This method is used by CEF. | 127 // ignored by WebKit. This method is used by CEF. |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
194 const GURL& first_party_for_cookies, | 181 const GURL& first_party_for_cookies, |
195 const std::string& value); | 182 const std::string& value); |
196 | 183 |
197 virtual void RegisterPPAPIInterfaceFactories( | 184 virtual void RegisterPPAPIInterfaceFactories( |
198 webkit::ppapi::PpapiInterfaceFactoryManager* factory_manager) {} | 185 webkit::ppapi::PpapiInterfaceFactoryManager* factory_manager) {} |
199 }; | 186 }; |
200 | 187 |
201 } // namespace content | 188 } // namespace content |
202 | 189 |
203 #endif // CONTENT_PUBLIC_RENDERER_CONTENT_RENDERER_CLIENT_H_ | 190 #endif // CONTENT_PUBLIC_RENDERER_CONTENT_RENDERER_CLIENT_H_ |
OLD | NEW |