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 // IPC messages for extensions. | 5 // IPC messages for extensions. |
6 // Multiply-included message file, hence no include guard. | 6 // Multiply-included message file, hence no include guard. |
7 | 7 |
8 #include "base/shared_memory.h" | 8 #include "base/shared_memory.h" |
9 #include "base/values.h" | 9 #include "base/values.h" |
10 #include "chrome/common/extensions/extension.h" | 10 #include "chrome/common/extensions/extension.h" |
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
154 | 154 |
155 template <> | 155 template <> |
156 struct ParamTraits<extensions::APIPermission::ID> { | 156 struct ParamTraits<extensions::APIPermission::ID> { |
157 typedef extensions::APIPermission::ID param_type; | 157 typedef extensions::APIPermission::ID param_type; |
158 static void Write(Message* m, const param_type& p); | 158 static void Write(Message* m, const param_type& p); |
159 static bool Read(const Message* m, PickleIterator* iter, param_type* p); | 159 static bool Read(const Message* m, PickleIterator* iter, param_type* p); |
160 static void Log(const param_type& p, std::string* l); | 160 static void Log(const param_type& p, std::string* l); |
161 }; | 161 }; |
162 | 162 |
163 template <> | 163 template <> |
| 164 struct ParamTraits<scoped_refptr<extensions::APIPermissionDetail> > { |
| 165 typedef scoped_refptr<extensions::APIPermissionDetail> param_type; |
| 166 static void Write(Message* m, const param_type& p); |
| 167 static bool Read(const Message* m, PickleIterator* iter, param_type* r); |
| 168 static void Log(const param_type& p, std::string* l); |
| 169 }; |
| 170 |
| 171 template <> |
| 172 struct ParamTraits<extensions::APIPermissionSet> { |
| 173 typedef extensions::APIPermissionSet param_type; |
| 174 static void Write(Message* m, const param_type& p); |
| 175 static bool Read(const Message* m, PickleIterator* iter, param_type* r); |
| 176 static void Log(const param_type& p, std::string* l); |
| 177 }; |
| 178 |
| 179 |
| 180 template <> |
164 struct ParamTraits<ExtensionMsg_Loaded_Params> { | 181 struct ParamTraits<ExtensionMsg_Loaded_Params> { |
165 typedef ExtensionMsg_Loaded_Params param_type; | 182 typedef ExtensionMsg_Loaded_Params param_type; |
166 static void Write(Message* m, const param_type& p); | 183 static void Write(Message* m, const param_type& p); |
167 static bool Read(const Message* m, PickleIterator* iter, param_type* p); | 184 static bool Read(const Message* m, PickleIterator* iter, param_type* p); |
168 static void Log(const param_type& p, std::string* l); | 185 static void Log(const param_type& p, std::string* l); |
169 }; | 186 }; |
170 | 187 |
171 } // namespace IPC | 188 } // namespace IPC |
172 | 189 |
173 #endif // CHROME_COMMON_EXTENSIONS_EXTENSION_MESSAGES_H_ | 190 #endif // CHROME_COMMON_EXTENSIONS_EXTENSION_MESSAGES_H_ |
(...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
496 // alive. | 513 // alive. |
497 IPC_MESSAGE_ROUTED0(ExtensionHostMsg_DecrementLazyKeepaliveCount) | 514 IPC_MESSAGE_ROUTED0(ExtensionHostMsg_DecrementLazyKeepaliveCount) |
498 | 515 |
499 // Fetches a globally unique ID (for the lifetime of the browser) from the | 516 // Fetches a globally unique ID (for the lifetime of the browser) from the |
500 // browser process. | 517 // browser process. |
501 IPC_SYNC_MESSAGE_CONTROL0_1(ExtensionHostMsg_GenerateUniqueID, | 518 IPC_SYNC_MESSAGE_CONTROL0_1(ExtensionHostMsg_GenerateUniqueID, |
502 int /* unique_id */) | 519 int /* unique_id */) |
503 | 520 |
504 // Resumes resource requests for a newly created app window. | 521 // Resumes resource requests for a newly created app window. |
505 IPC_MESSAGE_CONTROL1(ExtensionHostMsg_ResumeRequests, int /* route_id */) | 522 IPC_MESSAGE_CONTROL1(ExtensionHostMsg_ResumeRequests, int /* route_id */) |
OLD | NEW |