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 307 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
318 | 318 |
319 // If the request with id |request_id| is pending then informs the | 319 // If the request with id |request_id| is pending then informs the |
320 // BrowserPlugin that the guest's permission request has been allowed or | 320 // BrowserPlugin that the guest's permission request has been allowed or |
321 // denied by the embedder. | 321 // denied by the embedder. |
322 void RespondPermissionIfRequestIsPending(int request_id, bool allow); | 322 void RespondPermissionIfRequestIsPending(int request_id, bool allow); |
323 // Cleans up pending permission request once the associated event.request | 323 // Cleans up pending permission request once the associated event.request |
324 // object goes out of scope in JavaScript. | 324 // object goes out of scope in JavaScript. |
325 void OnRequestObjectGarbageCollected(int request_id); | 325 void OnRequestObjectGarbageCollected(int request_id); |
326 // V8 garbage collection callback for |object|. | 326 // V8 garbage collection callback for |object|. |
327 static void WeakCallbackForPersistObject(v8::Isolate* isolate, | 327 static void WeakCallbackForPersistObject(v8::Isolate* isolate, |
328 v8::Persistent<v8::Value> object, | 328 v8::Persistent<v8::Value>* object, |
329 void* param); | 329 void* param); |
330 | 330 |
331 // IPC message handlers. | 331 // IPC message handlers. |
332 // Please keep in alphabetical order. | 332 // Please keep in alphabetical order. |
333 void OnAddMessageToConsole( | 333 void OnAddMessageToConsole( |
334 int instance_id, | 334 int instance_id, |
335 const base::DictionaryValue& message_info); | 335 const base::DictionaryValue& message_info); |
336 void OnAdvanceFocus(int instance_id, bool reverse); | 336 void OnAdvanceFocus(int instance_id, bool reverse); |
337 void OnAttachACK(int instance_id, | 337 void OnAttachACK(int instance_id, |
338 const BrowserPluginMsg_Attach_ACK_Params& ack_params); | 338 const BrowserPluginMsg_Attach_ACK_Params& ack_params); |
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
448 // Weak factory used in v8 |MakeWeak| callback, since the v8 callback might | 448 // Weak factory used in v8 |MakeWeak| callback, since the v8 callback might |
449 // get called after BrowserPlugin has been destroyed. | 449 // get called after BrowserPlugin has been destroyed. |
450 base::WeakPtrFactory<BrowserPlugin> weak_ptr_factory_; | 450 base::WeakPtrFactory<BrowserPlugin> weak_ptr_factory_; |
451 | 451 |
452 DISALLOW_COPY_AND_ASSIGN(BrowserPlugin); | 452 DISALLOW_COPY_AND_ASSIGN(BrowserPlugin); |
453 }; | 453 }; |
454 | 454 |
455 } // namespace content | 455 } // namespace content |
456 | 456 |
457 #endif // CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_H_ | 457 #endif // CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_H_ |
OLD | NEW |