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_BROWSER_PLUGIN_BROWSER_PLUGIN_H_ | 5 #ifndef CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_H_ |
6 #define CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_H_ | 6 #define CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_H_ |
7 | 7 |
8 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPlugin.h" | 8 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPlugin.h" |
9 | 9 |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
281 bool allow); | 281 bool allow); |
282 | 282 |
283 // If the request with id |request_id| is pending then informs the | 283 // If the request with id |request_id| is pending then informs the |
284 // BrowserPlugin that the guest's permission request has been allowed or | 284 // BrowserPlugin that the guest's permission request has been allowed or |
285 // denied by the embedder. | 285 // denied by the embedder. |
286 void RespondPermissionIfRequestIsPending(int request_id, bool allow); | 286 void RespondPermissionIfRequestIsPending(int request_id, bool allow); |
287 // Cleans up pending permission request once the associated event.request | 287 // Cleans up pending permission request once the associated event.request |
288 // object goes out of scope in JavaScript. | 288 // object goes out of scope in JavaScript. |
289 void OnRequestObjectGarbageCollected(int request_id); | 289 void OnRequestObjectGarbageCollected(int request_id); |
290 // V8 garbage collection callback for |object|. | 290 // V8 garbage collection callback for |object|. |
291 static void WeakCallbackForPersistObject(v8::Persistent<v8::Value> object, | 291 static void WeakCallbackForPersistObject(v8::Isolate* isolate, |
| 292 v8::Persistent<v8::Value> object, |
292 void* param); | 293 void* param); |
293 | 294 |
294 // IPC message handlers. | 295 // IPC message handlers. |
295 // Please keep in alphabetical order. | 296 // Please keep in alphabetical order. |
296 void OnAdvanceFocus(int instance_id, bool reverse); | 297 void OnAdvanceFocus(int instance_id, bool reverse); |
297 void OnBuffersSwapped(int instance_id, | 298 void OnBuffersSwapped(int instance_id, |
298 const gfx::Size& size, | 299 const gfx::Size& size, |
299 std::string mailbox_name, | 300 std::string mailbox_name, |
300 int gpu_route_id, | 301 int gpu_route_id, |
301 int gpu_host_id); | 302 int gpu_host_id); |
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
401 // Weak factory used in v8 |MakeWeak| callback, since the v8 callback might | 402 // Weak factory used in v8 |MakeWeak| callback, since the v8 callback might |
402 // get called after BrowserPlugin has been destroyed. | 403 // get called after BrowserPlugin has been destroyed. |
403 base::WeakPtrFactory<BrowserPlugin> weak_ptr_factory_; | 404 base::WeakPtrFactory<BrowserPlugin> weak_ptr_factory_; |
404 | 405 |
405 DISALLOW_COPY_AND_ASSIGN(BrowserPlugin); | 406 DISALLOW_COPY_AND_ASSIGN(BrowserPlugin); |
406 }; | 407 }; |
407 | 408 |
408 } // namespace content | 409 } // namespace content |
409 | 410 |
410 #endif // CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_H_ | 411 #endif // CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_H_ |
OLD | NEW |