Chromium Code Reviews| Index: content/browser/browser_plugin/browser_plugin_embedder.cc |
| diff --git a/content/browser/browser_plugin/browser_plugin_embedder.cc b/content/browser/browser_plugin/browser_plugin_embedder.cc |
| index 4ffaa3d7b383bdb45bb84d562e2a17ae8b070f4e..0c306499bd0011b9f61e9ee9cbb80c25e765f411 100644 |
| --- a/content/browser/browser_plugin/browser_plugin_embedder.cc |
| +++ b/content/browser/browser_plugin/browser_plugin_embedder.cc |
| @@ -250,6 +250,8 @@ bool BrowserPluginEmbedder::OnMessageReceived(const IPC::Message& message) { |
| OnPluginDestroyed) |
| IPC_MESSAGE_HANDLER(BrowserPluginHostMsg_BuffersSwappedACK, |
| OnSwapBuffersACK) |
| + IPC_MESSAGE_HANDLER(BrowserPluginHostMsg_AllowMediaAccess, |
| + OnAllowMediaAccess) |
| IPC_MESSAGE_UNHANDLED(handled = false) |
| IPC_END_MESSAGE_MAP() |
| return handled; |
| @@ -359,6 +361,14 @@ void BrowserPluginEmbedder::OnPluginDestroyed(int instance_id) { |
| DestroyGuestByInstanceID(instance_id); |
| } |
| +void BrowserPluginEmbedder::OnAllowMediaAccess(int instance_id, |
| + int request_id, |
| + bool should_allow) { |
| + BrowserPluginGuest* guest = GetGuestByInstanceID(instance_id); |
|
Fady Samuel
2013/02/05 17:53:27
No need for this. Simply add BrowserPluginHostMsg_
lazyboy
2013/02/07 04:38:42
Yep, we also have embedder_web_contents_ directly
|
| + if (guest) |
| + guest->AllowMediaAccess(web_contents(), request_id, should_allow); |
| +} |
| + |
| void BrowserPluginEmbedder::OnSwapBuffersACK(int route_id, |
| int gpu_host_id, |
| const std::string& mailbox_name, |