Index: content/renderer/pepper/host_dispatcher_wrapper.cc |
diff --git a/content/renderer/pepper/host_dispatcher_wrapper.cc b/content/renderer/pepper/host_dispatcher_wrapper.cc |
index 606d2815c41967537eb549d784711f091bed69d9..8b74a67483622ac0cbace33dc5cd2e740c8077a9 100644 |
--- a/content/renderer/pepper/host_dispatcher_wrapper.cc |
+++ b/content/renderer/pepper/host_dispatcher_wrapper.cc |
@@ -32,7 +32,7 @@ HostDispatcherWrapper::~HostDispatcherWrapper() {} |
bool HostDispatcherWrapper::Init(const IPC::ChannelHandle& channel_handle, |
PP_GetInterface_Func local_get_interface, |
const ppapi::Preferences& preferences, |
- PepperHungPluginFilter* filter) { |
+ scoped_refptr<PepperHungPluginFilter> filter) { |
if (channel_handle.name.empty()) |
return false; |
@@ -43,8 +43,14 @@ bool HostDispatcherWrapper::Init(const IPC::ChannelHandle& channel_handle, |
#endif |
dispatcher_delegate_.reset(new PepperProxyChannelDelegateImpl); |
+ // TODO/FIXME(dmichael): Should we really be passing the filter to |
+ // InitHostWithChannel? What about Init instead? |
raymes
2014/09/23 02:57:09
I'm not sure I understand this comment. Aren't we
dmichael (off chromium)
2014/09/23 17:38:42
Sorry, this is one of the things I meant when I sa
|
dispatcher_.reset(new ppapi::proxy::HostDispatcher( |
module_->pp_module(), local_get_interface, filter, permissions_)); |
+ // The HungPluginFilter needs to know when we are blocked on a sync message |
+ // to the plugin. Note the filter outlives the dispatcher, so there is no |
+ // need to remove is as an observer. |
raymes
2014/09/23 02:57:09
is->it
dmichael (off chromium)
2014/09/23 17:38:42
Done.
|
+ dispatcher_->AddSyncMessageStatusObserver(filter.get()); |
if (!dispatcher_->InitHostWithChannel(dispatcher_delegate_.get(), |
peer_pid_, |