| 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 #include "content/renderer/pepper/renderer_ppapi_host_impl.h" | 5 #include "content/renderer/pepper/renderer_ppapi_host_impl.h" |
| 6 | 6 |
| 7 #include "base/files/file_path.h" | 7 #include "base/files/file_path.h" |
| 8 #include "base/logging.h" | 8 #include "base/logging.h" |
| 9 #include "base/process_util.h" | 9 #include "base/process_util.h" |
| 10 #include "content/common/sandbox_util.h" | 10 #include "content/common/sandbox_util.h" |
| 11 #include "content/renderer/pepper/fullscreen_container.h" |
| 12 #include "content/renderer/pepper/host_globals.h" |
| 11 #include "content/renderer/pepper/pepper_browser_connection.h" | 13 #include "content/renderer/pepper/pepper_browser_connection.h" |
| 12 #include "content/renderer/pepper/pepper_graphics_2d_host.h" | 14 #include "content/renderer/pepper/pepper_graphics_2d_host.h" |
| 13 #include "content/renderer/pepper/pepper_in_process_resource_creation.h" | 15 #include "content/renderer/pepper/pepper_in_process_resource_creation.h" |
| 14 #include "content/renderer/pepper/pepper_in_process_router.h" | 16 #include "content/renderer/pepper/pepper_in_process_router.h" |
| 15 #include "content/renderer/pepper/pepper_plugin_delegate_impl.h" | 17 #include "content/renderer/pepper/pepper_plugin_delegate_impl.h" |
| 18 #include "content/renderer/pepper/plugin_delegate.h" |
| 19 #include "content/renderer/pepper/plugin_module.h" |
| 20 #include "content/renderer/pepper/ppapi_plugin_instance_impl.h" |
| 16 #include "content/renderer/render_view_impl.h" | 21 #include "content/renderer/render_view_impl.h" |
| 17 #include "content/renderer/render_widget_fullscreen_pepper.h" | 22 #include "content/renderer/render_widget_fullscreen_pepper.h" |
| 18 #include "ipc/ipc_message.h" | 23 #include "ipc/ipc_message.h" |
| 19 #include "ppapi/host/ppapi_host.h" | 24 #include "ppapi/host/ppapi_host.h" |
| 20 #include "ppapi/proxy/host_dispatcher.h" | 25 #include "ppapi/proxy/host_dispatcher.h" |
| 21 #include "third_party/WebKit/public/platform/WebRect.h" | 26 #include "third_party/WebKit/public/platform/WebRect.h" |
| 22 #include "third_party/WebKit/public/web/WebDocument.h" | 27 #include "third_party/WebKit/public/web/WebDocument.h" |
| 23 #include "third_party/WebKit/public/web/WebElement.h" | 28 #include "third_party/WebKit/public/web/WebElement.h" |
| 24 #include "third_party/WebKit/public/web/WebPluginContainer.h" | 29 #include "third_party/WebKit/public/web/WebPluginContainer.h" |
| 25 #include "ui/gfx/point.h" | 30 #include "ui/gfx/point.h" |
| 26 #include "webkit/plugins/ppapi/fullscreen_container.h" | |
| 27 #include "webkit/plugins/ppapi/host_globals.h" | |
| 28 #include "webkit/plugins/ppapi/plugin_delegate.h" | |
| 29 #include "webkit/plugins/ppapi/plugin_module.h" | |
| 30 #include "webkit/plugins/ppapi/ppapi_plugin_instance_impl.h" | |
| 31 | 31 |
| 32 using webkit::ppapi::HostGlobals; | 32 using webkit::ppapi::HostGlobals; |
| 33 using webkit::ppapi::PluginInstance; | 33 using webkit::ppapi::PluginInstance; |
| 34 using webkit::ppapi::PluginInstanceImpl; | 34 using webkit::ppapi::PluginInstanceImpl; |
| 35 using webkit::ppapi::PluginModule; | 35 using webkit::ppapi::PluginModule; |
| 36 | 36 |
| 37 namespace content { | 37 namespace content { |
| 38 // static | 38 // static |
| 39 CONTENT_EXPORT RendererPpapiHost* | 39 CONTENT_EXPORT RendererPpapiHost* |
| 40 RendererPpapiHost::GetForPPInstance(PP_Instance instance) { | 40 RendererPpapiHost::GetForPPInstance(PP_Instance instance) { |
| (...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 273 PP_Instance pp_instance) const { | 273 PP_Instance pp_instance) const { |
| 274 PluginInstanceImpl* instance = HostGlobals::Get()->GetInstance(pp_instance); | 274 PluginInstanceImpl* instance = HostGlobals::Get()->GetInstance(pp_instance); |
| 275 if (!instance) | 275 if (!instance) |
| 276 return NULL; | 276 return NULL; |
| 277 if (!instance->IsValidInstanceOf(module_)) | 277 if (!instance->IsValidInstanceOf(module_)) |
| 278 return NULL; | 278 return NULL; |
| 279 return instance; | 279 return instance; |
| 280 } | 280 } |
| 281 | 281 |
| 282 } // namespace content | 282 } // namespace content |
| OLD | NEW |