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_PLUGIN_WEBPLUGIN_PROXY_H_ | 5 #ifndef CONTENT_PLUGIN_WEBPLUGIN_PROXY_H_ |
6 #define CONTENT_PLUGIN_WEBPLUGIN_PROXY_H_ | 6 #define CONTENT_PLUGIN_WEBPLUGIN_PROXY_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/containers/hash_tables.h" | 10 #include "base/containers/hash_tables.h" |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 // marshalled WebPlugin calls. | 44 // marshalled WebPlugin calls. |
45 WebPluginProxy(PluginChannel* channel, | 45 WebPluginProxy(PluginChannel* channel, |
46 int route_id, | 46 int route_id, |
47 const GURL& page_url, | 47 const GURL& page_url, |
48 int host_render_view_routing_id); | 48 int host_render_view_routing_id); |
49 virtual ~WebPluginProxy(); | 49 virtual ~WebPluginProxy(); |
50 | 50 |
51 void set_delegate(WebPluginDelegateImpl* d) { delegate_ = d; } | 51 void set_delegate(WebPluginDelegateImpl* d) { delegate_ = d; } |
52 | 52 |
53 // WebPlugin overrides | 53 // WebPlugin overrides |
54 virtual void SetWindow(gfx::PluginWindowHandle window) OVERRIDE; | 54 virtual void SetWindow(gfx::PluginWindowHandle window) override; |
55 virtual void SetAcceptsInputEvents(bool accepts) OVERRIDE; | 55 virtual void SetAcceptsInputEvents(bool accepts) override; |
56 virtual void WillDestroyWindow(gfx::PluginWindowHandle window) OVERRIDE; | 56 virtual void WillDestroyWindow(gfx::PluginWindowHandle window) override; |
57 virtual void CancelResource(unsigned long id) OVERRIDE; | 57 virtual void CancelResource(unsigned long id) override; |
58 virtual void Invalidate() OVERRIDE; | 58 virtual void Invalidate() override; |
59 virtual void InvalidateRect(const gfx::Rect& rect) OVERRIDE; | 59 virtual void InvalidateRect(const gfx::Rect& rect) override; |
60 virtual NPObject* GetWindowScriptNPObject() OVERRIDE; | 60 virtual NPObject* GetWindowScriptNPObject() override; |
61 virtual NPObject* GetPluginElement() OVERRIDE; | 61 virtual NPObject* GetPluginElement() override; |
62 virtual bool FindProxyForUrl(const GURL& url, | 62 virtual bool FindProxyForUrl(const GURL& url, |
63 std::string* proxy_list) OVERRIDE; | 63 std::string* proxy_list) override; |
64 virtual void SetCookie(const GURL& url, | 64 virtual void SetCookie(const GURL& url, |
65 const GURL& first_party_for_cookies, | 65 const GURL& first_party_for_cookies, |
66 const std::string& cookie) OVERRIDE; | 66 const std::string& cookie) override; |
67 virtual std::string GetCookies(const GURL& url, | 67 virtual std::string GetCookies(const GURL& url, |
68 const GURL& first_party_for_cookies) OVERRIDE; | 68 const GURL& first_party_for_cookies) override; |
69 virtual void HandleURLRequest(const char* url, | 69 virtual void HandleURLRequest(const char* url, |
70 const char* method, | 70 const char* method, |
71 const char* target, | 71 const char* target, |
72 const char* buf, | 72 const char* buf, |
73 unsigned int len, | 73 unsigned int len, |
74 int notify_id, | 74 int notify_id, |
75 bool popups_allowed, | 75 bool popups_allowed, |
76 bool notify_redirects) OVERRIDE; | 76 bool notify_redirects) override; |
77 void UpdateGeometry(const gfx::Rect& window_rect, | 77 void UpdateGeometry(const gfx::Rect& window_rect, |
78 const gfx::Rect& clip_rect, | 78 const gfx::Rect& clip_rect, |
79 const TransportDIB::Handle& windowless_buffer0, | 79 const TransportDIB::Handle& windowless_buffer0, |
80 const TransportDIB::Handle& windowless_buffer1, | 80 const TransportDIB::Handle& windowless_buffer1, |
81 int windowless_buffer_index); | 81 int windowless_buffer_index); |
82 virtual void CancelDocumentLoad() OVERRIDE; | 82 virtual void CancelDocumentLoad() override; |
83 virtual void InitiateHTTPRangeRequest( | 83 virtual void InitiateHTTPRangeRequest( |
84 const char* url, const char* range_info, int range_request_id) OVERRIDE; | 84 const char* url, const char* range_info, int range_request_id) override; |
85 virtual void DidStartLoading() OVERRIDE; | 85 virtual void DidStartLoading() override; |
86 virtual void DidStopLoading() OVERRIDE; | 86 virtual void DidStopLoading() override; |
87 virtual void SetDeferResourceLoading(unsigned long resource_id, | 87 virtual void SetDeferResourceLoading(unsigned long resource_id, |
88 bool defer) OVERRIDE; | 88 bool defer) override; |
89 virtual bool IsOffTheRecord() OVERRIDE; | 89 virtual bool IsOffTheRecord() override; |
90 virtual void ResourceClientDeleted( | 90 virtual void ResourceClientDeleted( |
91 WebPluginResourceClient* resource_client) OVERRIDE; | 91 WebPluginResourceClient* resource_client) override; |
92 virtual void URLRedirectResponse(bool allow, int resource_id) OVERRIDE; | 92 virtual void URLRedirectResponse(bool allow, int resource_id) override; |
93 virtual bool CheckIfRunInsecureContent(const GURL& url) OVERRIDE; | 93 virtual bool CheckIfRunInsecureContent(const GURL& url) override; |
94 #if defined(OS_WIN) | 94 #if defined(OS_WIN) |
95 void SetWindowlessData(HANDLE pump_messages_event, | 95 void SetWindowlessData(HANDLE pump_messages_event, |
96 gfx::NativeViewId dummy_activation_window); | 96 gfx::NativeViewId dummy_activation_window); |
97 #endif | 97 #endif |
98 #if defined(OS_MACOSX) | 98 #if defined(OS_MACOSX) |
99 virtual void FocusChanged(bool focused) OVERRIDE; | 99 virtual void FocusChanged(bool focused) override; |
100 virtual void StartIme() OVERRIDE; | 100 virtual void StartIme() override; |
101 virtual WebPluginAcceleratedSurface* | 101 virtual WebPluginAcceleratedSurface* |
102 GetAcceleratedSurface(gfx::GpuPreference gpu_preference) OVERRIDE; | 102 GetAcceleratedSurface(gfx::GpuPreference gpu_preference) override; |
103 virtual void AcceleratedPluginEnabledRendering() OVERRIDE; | 103 virtual void AcceleratedPluginEnabledRendering() override; |
104 virtual void AcceleratedPluginAllocatedIOSurface(int32 width, | 104 virtual void AcceleratedPluginAllocatedIOSurface(int32 width, |
105 int32 height, | 105 int32 height, |
106 uint32 surface_id) OVERRIDE; | 106 uint32 surface_id) override; |
107 virtual void AcceleratedPluginSwappedIOSurface() OVERRIDE; | 107 virtual void AcceleratedPluginSwappedIOSurface() override; |
108 #endif | 108 #endif |
109 | 109 |
110 // IPC::Sender implementation. | 110 // IPC::Sender implementation. |
111 virtual bool Send(IPC::Message* msg) OVERRIDE; | 111 virtual bool Send(IPC::Message* msg) override; |
112 | 112 |
113 // class-specific methods | 113 // class-specific methods |
114 | 114 |
115 // Returns a WebPluginResourceClient object given its id, or NULL if no | 115 // Returns a WebPluginResourceClient object given its id, or NULL if no |
116 // object with that id exists. | 116 // object with that id exists. |
117 WebPluginResourceClient* GetResourceClient(int id); | 117 WebPluginResourceClient* GetResourceClient(int id); |
118 | 118 |
119 // Returns the id of the renderer that contains this plugin. | 119 // Returns the id of the renderer that contains this plugin. |
120 int GetRendererId(); | 120 int GetRendererId(); |
121 | 121 |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
212 | 212 |
213 // Contains the routing id of the host render view. | 213 // Contains the routing id of the host render view. |
214 int host_render_view_routing_id_; | 214 int host_render_view_routing_id_; |
215 | 215 |
216 base::WeakPtrFactory<WebPluginProxy> weak_factory_; | 216 base::WeakPtrFactory<WebPluginProxy> weak_factory_; |
217 }; | 217 }; |
218 | 218 |
219 } // namespace content | 219 } // namespace content |
220 | 220 |
221 #endif // CONTENT_PLUGIN_WEBPLUGIN_PROXY_H_ | 221 #endif // CONTENT_PLUGIN_WEBPLUGIN_PROXY_H_ |
OLD | NEW |