Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(132)

Side by Side Diff: content/renderer/render_frame_impl.cc

Issue 2411433002: Move ENABLE_PEPPER_CDMS to a buildflag header. (Closed)
Patch Set: fix Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "content/renderer/render_frame_impl.h" 5 #include "content/renderer/render_frame_impl.h"
6 6
7 #include <map> 7 #include <map>
8 #include <string> 8 #include <string>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 #include "third_party/WebKit/public/web/WebScopedUserGesture.h" 193 #include "third_party/WebKit/public/web/WebScopedUserGesture.h"
194 #include "third_party/WebKit/public/web/WebScriptSource.h" 194 #include "third_party/WebKit/public/web/WebScriptSource.h"
195 #include "third_party/WebKit/public/web/WebSearchableFormData.h" 195 #include "third_party/WebKit/public/web/WebSearchableFormData.h"
196 #include "third_party/WebKit/public/web/WebSecurityPolicy.h" 196 #include "third_party/WebKit/public/web/WebSecurityPolicy.h"
197 #include "third_party/WebKit/public/web/WebSerializedScriptValue.h" 197 #include "third_party/WebKit/public/web/WebSerializedScriptValue.h"
198 #include "third_party/WebKit/public/web/WebSettings.h" 198 #include "third_party/WebKit/public/web/WebSettings.h"
199 #include "third_party/WebKit/public/web/WebSurroundingText.h" 199 #include "third_party/WebKit/public/web/WebSurroundingText.h"
200 #include "third_party/WebKit/public/web/WebUserGestureIndicator.h" 200 #include "third_party/WebKit/public/web/WebUserGestureIndicator.h"
201 #include "third_party/WebKit/public/web/WebView.h" 201 #include "third_party/WebKit/public/web/WebView.h"
202 #include "third_party/WebKit/public/web/WebWidget.h" 202 #include "third_party/WebKit/public/web/WebWidget.h"
203 #include "third_party/widevine/cdm/cdm_features.h"
203 #include "url/url_constants.h" 204 #include "url/url_constants.h"
204 #include "url/url_util.h" 205 #include "url/url_util.h"
205 206
206 #if defined(ENABLE_PLUGINS) 207 #if defined(ENABLE_PLUGINS)
207 #include "content/renderer/pepper/pepper_browser_connection.h" 208 #include "content/renderer/pepper/pepper_browser_connection.h"
208 #include "content/renderer/pepper/pepper_plugin_instance_impl.h" 209 #include "content/renderer/pepper/pepper_plugin_instance_impl.h"
209 #include "content/renderer/pepper/pepper_plugin_registry.h" 210 #include "content/renderer/pepper/pepper_plugin_registry.h"
210 #include "content/renderer/pepper/pepper_webplugin_impl.h" 211 #include "content/renderer/pepper/pepper_webplugin_impl.h"
211 #include "content/renderer/pepper/plugin_module.h" 212 #include "content/renderer/pepper/plugin_module.h"
212 #endif 213 #endif
213 214
214 #if defined(ENABLE_WEBRTC) 215 #if defined(ENABLE_WEBRTC)
215 #include "content/renderer/media/rtc_peer_connection_handler.h" 216 #include "content/renderer/media/rtc_peer_connection_handler.h"
216 #endif 217 #endif
217 218
218 #if defined(OS_ANDROID) 219 #if defined(OS_ANDROID)
219 #include <cpu-features.h> 220 #include <cpu-features.h>
220 221
221 #include "content/renderer/java/gin_java_bridge_dispatcher.h" 222 #include "content/renderer/java/gin_java_bridge_dispatcher.h"
222 #include "content/renderer/media/android/renderer_media_player_manager.h" 223 #include "content/renderer/media/android/renderer_media_player_manager.h"
223 #include "content/renderer/media/android/renderer_surface_view_manager.h" 224 #include "content/renderer/media/android/renderer_surface_view_manager.h"
224 #include "content/renderer/media/android/stream_texture_factory.h" 225 #include "content/renderer/media/android/stream_texture_factory.h"
225 #include "content/renderer/media/android/webmediaplayer_android.h" 226 #include "content/renderer/media/android/webmediaplayer_android.h"
226 #include "media/base/android/media_codec_util.h" 227 #include "media/base/android/media_codec_util.h"
227 #include "third_party/WebKit/public/platform/WebFloatPoint.h" 228 #include "third_party/WebKit/public/platform/WebFloatPoint.h"
228 #endif 229 #endif
229 230
230 #if defined(ENABLE_PEPPER_CDMS) 231 #if BUILDFLAG(ENABLE_PEPPER_CDMS)
231 #include "content/renderer/media/cdm/pepper_cdm_wrapper_impl.h" 232 #include "content/renderer/media/cdm/pepper_cdm_wrapper_impl.h"
232 #include "content/renderer/media/cdm/render_cdm_factory.h" 233 #include "content/renderer/media/cdm/render_cdm_factory.h"
233 #endif 234 #endif
234 235
235 #if defined(ENABLE_MOJO_MEDIA) 236 #if defined(ENABLE_MOJO_MEDIA)
236 #include "content/renderer/media/media_interface_provider.h" 237 #include "content/renderer/media/media_interface_provider.h"
237 #endif 238 #endif
238 239
239 #if defined(ENABLE_MOJO_CDM) 240 #if defined(ENABLE_MOJO_CDM)
240 #include "media/mojo/clients/mojo_cdm_factory.h" // nogncheck 241 #include "media/mojo/clients/mojo_cdm_factory.h" // nogncheck
(...skipping 6051 matching lines...) Expand 10 before | Expand all | Expand 10 after
6292 if (cdm_factory_) 6293 if (cdm_factory_)
6293 return cdm_factory_.get(); 6294 return cdm_factory_.get();
6294 6295
6295 #if defined(ENABLE_MOJO_CDM) 6296 #if defined(ENABLE_MOJO_CDM)
6296 if (UseMojoCdm()) { 6297 if (UseMojoCdm()) {
6297 cdm_factory_.reset(new media::MojoCdmFactory(GetMediaInterfaceProvider())); 6298 cdm_factory_.reset(new media::MojoCdmFactory(GetMediaInterfaceProvider()));
6298 return cdm_factory_.get(); 6299 return cdm_factory_.get();
6299 } 6300 }
6300 #endif // defined(ENABLE_MOJO_CDM) 6301 #endif // defined(ENABLE_MOJO_CDM)
6301 6302
6302 #if defined(ENABLE_PEPPER_CDMS) 6303 #if BUILDFLAG(ENABLE_PEPPER_CDMS)
6303 DCHECK(frame_); 6304 DCHECK(frame_);
6304 cdm_factory_.reset( 6305 cdm_factory_.reset(
6305 new RenderCdmFactory(base::Bind(&PepperCdmWrapperImpl::Create, frame_))); 6306 new RenderCdmFactory(base::Bind(&PepperCdmWrapperImpl::Create, frame_)));
6306 #endif // defined(ENABLE_PEPPER_CDMS) 6307 #endif // BUILDFLAG(ENABLE_PEPPER_CDMS)
6307 6308
6308 return cdm_factory_.get(); 6309 return cdm_factory_.get();
6309 } 6310 }
6310 6311
6311 media::DecoderFactory* RenderFrameImpl::GetDecoderFactory() { 6312 media::DecoderFactory* RenderFrameImpl::GetDecoderFactory() {
6312 #if defined(ENABLE_MOJO_AUDIO_DECODER) || defined(ENABLE_MOJO_VIDEO_DECODER) 6313 #if defined(ENABLE_MOJO_AUDIO_DECODER) || defined(ENABLE_MOJO_VIDEO_DECODER)
6313 if (!decoder_factory_) { 6314 if (!decoder_factory_) {
6314 decoder_factory_.reset( 6315 decoder_factory_.reset(
6315 new media::MojoDecoderFactory(GetMediaInterfaceProvider())); 6316 new media::MojoDecoderFactory(GetMediaInterfaceProvider()));
6316 } 6317 }
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
6484 // event target. Potentially a Pepper plugin will receive the event. 6485 // event target. Potentially a Pepper plugin will receive the event.
6485 // In order to tell whether a plugin gets the last mouse event and which it 6486 // In order to tell whether a plugin gets the last mouse event and which it
6486 // is, we set |pepper_last_mouse_event_target_| to null here. If a plugin gets 6487 // is, we set |pepper_last_mouse_event_target_| to null here. If a plugin gets
6487 // the event, it will notify us via DidReceiveMouseEvent() and set itself as 6488 // the event, it will notify us via DidReceiveMouseEvent() and set itself as
6488 // |pepper_last_mouse_event_target_|. 6489 // |pepper_last_mouse_event_target_|.
6489 pepper_last_mouse_event_target_ = nullptr; 6490 pepper_last_mouse_event_target_ = nullptr;
6490 #endif 6491 #endif
6491 } 6492 }
6492 6493
6493 } // namespace content 6494 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698