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 <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <string> | 10 #include <string> |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
65 const GURL& first_party_for_cookies) override; | 65 const GURL& first_party_for_cookies) override; |
66 void UpdateGeometry(const gfx::Rect& window_rect, | 66 void UpdateGeometry(const gfx::Rect& window_rect, |
67 const gfx::Rect& clip_rect, | 67 const gfx::Rect& clip_rect, |
68 const TransportDIB::Handle& windowless_buffer0, | 68 const TransportDIB::Handle& windowless_buffer0, |
69 const TransportDIB::Handle& windowless_buffer1, | 69 const TransportDIB::Handle& windowless_buffer1, |
70 int windowless_buffer_index); | 70 int windowless_buffer_index); |
71 void CancelDocumentLoad() override; | 71 void CancelDocumentLoad() override; |
72 void DidStartLoading() override; | 72 void DidStartLoading() override; |
73 void DidStopLoading() override; | 73 void DidStopLoading() override; |
74 bool IsOffTheRecord() override; | 74 bool IsOffTheRecord() override; |
75 #if defined(OS_WIN) | |
76 void SetWindowlessData(HANDLE pump_messages_event, | |
77 gfx::NativeViewId dummy_activation_window) override; | |
78 #endif | |
79 #if defined(OS_MACOSX) | 75 #if defined(OS_MACOSX) |
80 void FocusChanged(bool focused) override; | 76 void FocusChanged(bool focused) override; |
81 void StartIme() override; | 77 void StartIme() override; |
82 WebPluginAcceleratedSurface* GetAcceleratedSurface( | 78 WebPluginAcceleratedSurface* GetAcceleratedSurface( |
83 gfx::GpuPreference gpu_preference) override; | 79 gfx::GpuPreference gpu_preference) override; |
84 void AcceleratedPluginEnabledRendering() override; | 80 void AcceleratedPluginEnabledRendering() override; |
85 void AcceleratedPluginAllocatedIOSurface(int32_t width, | 81 void AcceleratedPluginAllocatedIOSurface(int32_t width, |
86 int32_t height, | 82 int32_t height, |
87 uint32_t surface_id) override; | 83 uint32_t surface_id) override; |
88 void AcceleratedPluginSwappedIOSurface() override; | 84 void AcceleratedPluginSwappedIOSurface() override; |
(...skipping 11 matching lines...) Expand all Loading... |
100 int host_render_view_routing_id() const { | 96 int host_render_view_routing_id() const { |
101 return host_render_view_routing_id_; | 97 return host_render_view_routing_id_; |
102 } | 98 } |
103 | 99 |
104 // For windowless plugins, paints the given rectangle into the local buffer. | 100 // For windowless plugins, paints the given rectangle into the local buffer. |
105 void Paint(const gfx::Rect& rect); | 101 void Paint(const gfx::Rect& rect); |
106 | 102 |
107 // Callback from the renderer to let us know that a paint occurred. | 103 // Callback from the renderer to let us know that a paint occurred. |
108 void DidPaint(); | 104 void DidPaint(); |
109 | 105 |
110 #if defined(OS_WIN) && !defined(USE_AURA) | |
111 // Retrieves the IME status from a windowless plugin and sends it to a | |
112 // renderer process. A renderer process will convert the coordinates from | |
113 // local to the window coordinates and send the converted coordinates to a | |
114 // browser process. | |
115 void UpdateIMEStatus(); | |
116 #endif | |
117 | |
118 private: | 106 private: |
119 class SharedTransportDIB : public base::RefCounted<SharedTransportDIB> { | 107 class SharedTransportDIB : public base::RefCounted<SharedTransportDIB> { |
120 public: | 108 public: |
121 explicit SharedTransportDIB(TransportDIB* dib); | 109 explicit SharedTransportDIB(TransportDIB* dib); |
122 TransportDIB* dib() { return dib_.get(); } | 110 TransportDIB* dib() { return dib_.get(); } |
123 private: | 111 private: |
124 friend class base::RefCounted<SharedTransportDIB>; | 112 friend class base::RefCounted<SharedTransportDIB>; |
125 ~SharedTransportDIB(); | 113 ~SharedTransportDIB(); |
126 | 114 |
127 scoped_ptr<TransportDIB> dib_; | 115 scoped_ptr<TransportDIB> dib_; |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
183 | 171 |
184 // Contains the routing id of the host render view. | 172 // Contains the routing id of the host render view. |
185 int host_render_view_routing_id_; | 173 int host_render_view_routing_id_; |
186 | 174 |
187 base::WeakPtrFactory<WebPluginProxy> weak_factory_; | 175 base::WeakPtrFactory<WebPluginProxy> weak_factory_; |
188 }; | 176 }; |
189 | 177 |
190 } // namespace content | 178 } // namespace content |
191 | 179 |
192 #endif // CONTENT_PLUGIN_WEBPLUGIN_PROXY_H_ | 180 #endif // CONTENT_PLUGIN_WEBPLUGIN_PROXY_H_ |
OLD | NEW |