OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #include "ppapi/proxy/plugin_message_filter.h" | 5 #include "ppapi/proxy/plugin_message_filter.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/location.h" | 8 #include "base/location.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "base/single_thread_task_runner.h" | 10 #include "base/single_thread_task_runner.h" |
(...skipping 13 matching lines...) Expand all Loading... |
24 std::set<PP_Instance>* seen_instance_ids, | 24 std::set<PP_Instance>* seen_instance_ids, |
25 scoped_refptr<ResourceReplyThreadRegistrar> registrar) | 25 scoped_refptr<ResourceReplyThreadRegistrar> registrar) |
26 : seen_instance_ids_(seen_instance_ids), | 26 : seen_instance_ids_(seen_instance_ids), |
27 resource_reply_thread_registrar_(registrar), | 27 resource_reply_thread_registrar_(registrar), |
28 sender_(NULL) { | 28 sender_(NULL) { |
29 } | 29 } |
30 | 30 |
31 PluginMessageFilter::~PluginMessageFilter() { | 31 PluginMessageFilter::~PluginMessageFilter() { |
32 } | 32 } |
33 | 33 |
34 void PluginMessageFilter::OnFilterAdded(IPC::Sender* sender) { | 34 void PluginMessageFilter::OnFilterAdded(IPC::Channel* channel) { |
35 sender_ = sender; | 35 sender_ = channel; |
36 } | 36 } |
37 | 37 |
38 void PluginMessageFilter::OnFilterRemoved() { | 38 void PluginMessageFilter::OnFilterRemoved() { |
39 sender_ = NULL; | 39 sender_ = NULL; |
40 } | 40 } |
41 | 41 |
42 bool PluginMessageFilter::OnMessageReceived(const IPC::Message& message) { | 42 bool PluginMessageFilter::OnMessageReceived(const IPC::Message& message) { |
43 bool handled = true; | 43 bool handled = true; |
44 IPC_BEGIN_MESSAGE_MAP(PluginMessageFilter, message) | 44 IPC_BEGIN_MESSAGE_MAP(PluginMessageFilter, message) |
45 IPC_MESSAGE_HANDLER(PpapiMsg_ReserveInstanceId, OnMsgReserveInstanceId) | 45 IPC_MESSAGE_HANDLER(PpapiMsg_ReserveInstanceId, OnMsgReserveInstanceId) |
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
111 DVLOG_IF(1, reply_params.sequence() != 0) | 111 DVLOG_IF(1, reply_params.sequence() != 0) |
112 << "Pepper resource reply message received but the resource doesn't " | 112 << "Pepper resource reply message received but the resource doesn't " |
113 "exist (probably has been destroyed)."; | 113 "exist (probably has been destroyed)."; |
114 return; | 114 return; |
115 } | 115 } |
116 resource->OnReplyReceived(reply_params, nested_msg); | 116 resource->OnReplyReceived(reply_params, nested_msg); |
117 } | 117 } |
118 | 118 |
119 } // namespace proxy | 119 } // namespace proxy |
120 } // namespace ppapi | 120 } // namespace ppapi |
OLD | NEW |