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 PPAPI_HOST_PPAPI_HOST_H_ | 5 #ifndef PPAPI_HOST_PPAPI_HOST_H_ |
6 #define PPAPI_HOST_PPAPI_HOST_H_ | 6 #define PPAPI_HOST_PPAPI_HOST_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 // The sender is the channel to the plugin for outgoing messages. | 44 // The sender is the channel to the plugin for outgoing messages. |
45 // Normally the creator will add filters for resource creation messages | 45 // Normally the creator will add filters for resource creation messages |
46 // (AddHostFactoryFilter) and instance messages (AddInstanceMessageFilter) | 46 // (AddHostFactoryFilter) and instance messages (AddInstanceMessageFilter) |
47 // after construction. | 47 // after construction. |
48 PpapiHost(IPC::Sender* sender, const PpapiPermissions& perms); | 48 PpapiHost(IPC::Sender* sender, const PpapiPermissions& perms); |
49 virtual ~PpapiHost(); | 49 virtual ~PpapiHost(); |
50 | 50 |
51 const PpapiPermissions& permissions() const { return permissions_; } | 51 const PpapiPermissions& permissions() const { return permissions_; } |
52 | 52 |
53 // Sender implementation. Forwards to the sender_. | 53 // Sender implementation. Forwards to the sender_. |
54 virtual bool Send(IPC::Message* msg) OVERRIDE; | 54 virtual bool Send(IPC::Message* msg) override; |
55 | 55 |
56 // Listener implementation. | 56 // Listener implementation. |
57 virtual bool OnMessageReceived(const IPC::Message& msg) OVERRIDE; | 57 virtual bool OnMessageReceived(const IPC::Message& msg) override; |
58 | 58 |
59 // Sends the given reply message to the plugin. | 59 // Sends the given reply message to the plugin. |
60 void SendReply(const ReplyMessageContext& context, | 60 void SendReply(const ReplyMessageContext& context, |
61 const IPC::Message& msg); | 61 const IPC::Message& msg); |
62 | 62 |
63 // Sends the given unsolicited reply message to the plugin. | 63 // Sends the given unsolicited reply message to the plugin. |
64 void SendUnsolicitedReply(PP_Resource resource, const IPC::Message& msg); | 64 void SendUnsolicitedReply(PP_Resource resource, const IPC::Message& msg); |
65 | 65 |
66 // Similar to |SendUnsolicitedReply()|, but also sends handles. | 66 // Similar to |SendUnsolicitedReply()|, but also sends handles. |
67 void SendUnsolicitedReplyWithHandles( | 67 void SendUnsolicitedReplyWithHandles( |
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
143 PendingHostResourceMap pending_resource_hosts_; | 143 PendingHostResourceMap pending_resource_hosts_; |
144 int next_pending_resource_host_id_; | 144 int next_pending_resource_host_id_; |
145 | 145 |
146 DISALLOW_COPY_AND_ASSIGN(PpapiHost); | 146 DISALLOW_COPY_AND_ASSIGN(PpapiHost); |
147 }; | 147 }; |
148 | 148 |
149 } // namespace host | 149 } // namespace host |
150 } // namespace ppapi | 150 } // namespace ppapi |
151 | 151 |
152 #endif // PPAPI_HOST_PPAPIE_HOST_H_ | 152 #endif // PPAPI_HOST_PPAPIE_HOST_H_ |
OLD | NEW |