Chromium Code Reviews| Index: content/browser/renderer_host/render_view_host_impl.cc |
| diff --git a/content/browser/renderer_host/render_view_host_impl.cc b/content/browser/renderer_host/render_view_host_impl.cc |
| index 7613dcfd42b69bf5517ba666fdf81a44d781f3c3..4cfef57bffe3de2043c33d73f2fe77e98addeeca 100644 |
| --- a/content/browser/renderer_host/render_view_host_impl.cc |
| +++ b/content/browser/renderer_host/render_view_host_impl.cc |
| @@ -29,6 +29,7 @@ |
| #include "content/browser/renderer_host/render_process_host_impl.h" |
| #include "content/browser/renderer_host/render_view_host_delegate.h" |
| #include "content/common/accessibility_messages.h" |
| +#include "content/common/browser_plugin_messages.h" |
| #include "content/common/content_constants_internal.h" |
| #include "content/common/desktop_notification_messages.h" |
| #include "content/common/drag_messages.h" |
| @@ -827,7 +828,15 @@ bool RenderViewHostImpl::SuddenTerminationAllowed() const { |
| // RenderViewHostImpl, IPC message handlers: |
| bool RenderViewHostImpl::OnMessageReceived(const IPC::Message& msg) { |
| - if (!BrowserMessageFilter::CheckCanDispatchOnUI(msg, this)) |
| + // Allow BrowserPluginHostMsg_* sync messages to run on the UI thread. |
| + // Platform apps will not support windowed plugins so the deadlock cycle |
| + // browser -> plugin -> renderer -> browser referred in |
| + // BrowserMessageFilter::CheckCanDispatchOnUI() is not supposed to happen. If |
| + // we want to support windowed plugins, sync messages in BrowserPlugin might |
| + // need to be changed to async messages. |
|
Charlie Reis
2012/09/13 22:46:25
Please add a TODO referencing http://crbug.com/149
lazyboy
2012/09/14 19:17:30
Done.
|
| + if (msg.type() != BrowserPluginHostMsg_HandleInputEvent::ID && |
| + msg.type() != BrowserPluginHostMsg_ResizeGuest::ID && |
| + !BrowserMessageFilter::CheckCanDispatchOnUI(msg, this)) |
| return true; |
| // Filter out most IPC messages if this renderer is swapped out. |