| 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_RENDERER_PEPPER_PEPPER_PLUGIN_DELEGATE_IMPL_H_ | 5 #ifndef CONTENT_RENDERER_PEPPER_PEPPER_PLUGIN_DELEGATE_IMPL_H_ |
| 6 #define CONTENT_RENDERER_PEPPER_PEPPER_PLUGIN_DELEGATE_IMPL_H_ | 6 #define CONTENT_RENDERER_PEPPER_PEPPER_PLUGIN_DELEGATE_IMPL_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <map> | 9 #include <map> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 118 | 118 |
| 119 // Pointer to the associated plugin module. | 119 // Pointer to the associated plugin module. |
| 120 // Always set and cleared at the same time as the module's pointer to this. | 120 // Always set and cleared at the same time as the module's pointer to this. |
| 121 webkit::ppapi::PluginModule* plugin_module_; | 121 webkit::ppapi::PluginModule* plugin_module_; |
| 122 | 122 |
| 123 base::WeakPtr<PepperPluginDelegateImpl> delegate_; | 123 base::WeakPtr<PepperPluginDelegateImpl> delegate_; |
| 124 | 124 |
| 125 DISALLOW_COPY_AND_ASSIGN(PpapiBrokerImpl); | 125 DISALLOW_COPY_AND_ASSIGN(PpapiBrokerImpl); |
| 126 }; | 126 }; |
| 127 | 127 |
| 128 namespace webkit_glue { |
| 129 class ClipboardClient; |
| 130 } |
| 131 |
| 128 class PepperPluginDelegateImpl | 132 class PepperPluginDelegateImpl |
| 129 : public webkit::ppapi::PluginDelegate, | 133 : public webkit::ppapi::PluginDelegate, |
| 130 public base::SupportsWeakPtr<PepperPluginDelegateImpl>, | 134 public base::SupportsWeakPtr<PepperPluginDelegateImpl>, |
| 131 public PepperParentContextProvider, | 135 public PepperParentContextProvider, |
| 132 public content::RenderViewObserver { | 136 public content::RenderViewObserver { |
| 133 public: | 137 public: |
| 134 explicit PepperPluginDelegateImpl(RenderViewImpl* render_view); | 138 explicit PepperPluginDelegateImpl(RenderViewImpl* render_view); |
| 135 virtual ~PepperPluginDelegateImpl(); | 139 virtual ~PepperPluginDelegateImpl(); |
| 136 | 140 |
| 137 // Attempts to create a PPAPI plugin for the given filepath. On success, it | 141 // Attempts to create a PPAPI plugin for the given filepath. On success, it |
| (...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 386 virtual void DidChangeCursor(webkit::ppapi::PluginInstance* instance, | 390 virtual void DidChangeCursor(webkit::ppapi::PluginInstance* instance, |
| 387 const WebKit::WebCursorInfo& cursor) OVERRIDE; | 391 const WebKit::WebCursorInfo& cursor) OVERRIDE; |
| 388 virtual void DidReceiveMouseEvent( | 392 virtual void DidReceiveMouseEvent( |
| 389 webkit::ppapi::PluginInstance* instance) OVERRIDE; | 393 webkit::ppapi::PluginInstance* instance) OVERRIDE; |
| 390 virtual bool IsInFullscreenMode() OVERRIDE; | 394 virtual bool IsInFullscreenMode() OVERRIDE; |
| 391 virtual void SampleGamepads(WebKit::WebGamepads* data) OVERRIDE; | 395 virtual void SampleGamepads(WebKit::WebGamepads* data) OVERRIDE; |
| 392 virtual bool IsPageVisible() const OVERRIDE; | 396 virtual bool IsPageVisible() const OVERRIDE; |
| 393 virtual int EnumerateDevices( | 397 virtual int EnumerateDevices( |
| 394 PP_DeviceType_Dev type, | 398 PP_DeviceType_Dev type, |
| 395 const EnumerateDevicesCallback& callback) OVERRIDE; | 399 const EnumerateDevicesCallback& callback) OVERRIDE; |
| 400 virtual webkit_glue::ClipboardClient* CreateClipboardClient() const OVERRIDE; |
| 396 | 401 |
| 397 // RenderViewObserver implementation. | 402 // RenderViewObserver implementation. |
| 398 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; | 403 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; |
| 399 virtual void OnDestruct() OVERRIDE; | 404 virtual void OnDestruct() OVERRIDE; |
| 400 | 405 |
| 401 void OnTCPSocketConnectACK(uint32 plugin_dispatcher_id, | 406 void OnTCPSocketConnectACK(uint32 plugin_dispatcher_id, |
| 402 uint32 socket_id, | 407 uint32 socket_id, |
| 403 bool succeeded, | 408 bool succeeded, |
| 404 const PP_NetAddress_Private& local_addr, | 409 const PP_NetAddress_Private& local_addr, |
| 405 const PP_NetAddress_Private& remote_addr); | 410 const PP_NetAddress_Private& remote_addr); |
| (...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 501 webkit::ppapi::PluginInstance* last_mouse_event_target_; | 506 webkit::ppapi::PluginInstance* last_mouse_event_target_; |
| 502 | 507 |
| 503 scoped_ptr<content::GamepadSharedMemoryReader> gamepad_shared_memory_reader_; | 508 scoped_ptr<content::GamepadSharedMemoryReader> gamepad_shared_memory_reader_; |
| 504 | 509 |
| 505 scoped_ptr<DeviceEnumerationEventHandler> device_enumeration_event_handler_; | 510 scoped_ptr<DeviceEnumerationEventHandler> device_enumeration_event_handler_; |
| 506 | 511 |
| 507 DISALLOW_COPY_AND_ASSIGN(PepperPluginDelegateImpl); | 512 DISALLOW_COPY_AND_ASSIGN(PepperPluginDelegateImpl); |
| 508 }; | 513 }; |
| 509 | 514 |
| 510 #endif // CONTENT_RENDERER_PEPPER_PEPPER_PLUGIN_DELEGATE_IMPL_H_ | 515 #endif // CONTENT_RENDERER_PEPPER_PEPPER_PLUGIN_DELEGATE_IMPL_H_ |
| OLD | NEW |