| OLD | NEW |
| 1 /* Copyright 2014 The Chromium Authors. All rights reserved. | 1 /* Copyright 2014 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 | 5 |
| 6 /** | 6 /** |
| 7 * This file defines the <code>PPP_MessageHandler</code> interface that plugins | 7 * This file defines the <code>PPP_MessageHandler</code> interface that plugins |
| 8 * can implement and register using PPB_Messaging::RegisterMessageHandler in | 8 * can implement and register using PPB_Messaging::RegisterMessageHandler in |
| 9 * order to handle messages sent from JavaScript via postMessage() or | 9 * order to handle messages sent from JavaScript via postMessage() or |
| 10 * postMessageAndAwaitResponse(). | 10 * postMessageAndAwaitResponse(). |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 * DOM element. | 30 * DOM element. |
| 31 * | 31 * |
| 32 * @param[in] instance A <code>PP_Instance</code> identifying one instance | 32 * @param[in] instance A <code>PP_Instance</code> identifying one instance |
| 33 * of a module. | 33 * of a module. |
| 34 * @param[in] user_data is the same pointer which was provided by a call to | 34 * @param[in] user_data is the same pointer which was provided by a call to |
| 35 * RegisterMessageHandler. | 35 * RegisterMessageHandler. |
| 36 * @param[in] message A copy of the parameter that JavaScript provided to | 36 * @param[in] message A copy of the parameter that JavaScript provided to |
| 37 * postMessage(). | 37 * postMessage(). |
| 38 */ | 38 */ |
| 39 void HandleMessage([in] PP_Instance instance, | 39 void HandleMessage([in] PP_Instance instance, |
| 40 [in] mem_t user_data, | 40 [inout] mem_t user_data, |
| 41 [in] PP_Var message); | 41 [in] PP_Var message); |
| 42 /** | 42 /** |
| 43 * Invoked as a result of JavaScript invoking postMessageAndAwaitResponse() | 43 * Invoked as a result of JavaScript invoking postMessageAndAwaitResponse() |
| 44 * on the plugin's DOM element. | 44 * on the plugin's DOM element. |
| 45 * | 45 * |
| 46 * @param[in] instance A <code>PP_Instance</code> identifying one instance | 46 * @param[in] instance A <code>PP_Instance</code> identifying one instance |
| 47 * of a module. | 47 * of a module. |
| 48 * @param[in] user_data is the same pointer which was provided by a call to | 48 * @param[in] user_data is the same pointer which was provided by a call to |
| 49 * RegisterMessageHandler. | 49 * RegisterMessageHandler. |
| 50 * @param[in] message is a copy of the parameter that JavaScript provided | 50 * @param[in] message is a copy of the parameter that JavaScript provided |
| (...skipping 10 matching lines...) Expand all Loading... |
| 61 * and <code>user_data</code>. | 61 * and <code>user_data</code>. |
| 62 * | 62 * |
| 63 * @param[in] instance A <code>PP_Instance</code> identifying one instance | 63 * @param[in] instance A <code>PP_Instance</code> identifying one instance |
| 64 * of a module. | 64 * of a module. |
| 65 * @param[in] user_data is the same pointer which was provided by a call to | 65 * @param[in] user_data is the same pointer which was provided by a call to |
| 66 * RegisterMessageHandler. | 66 * RegisterMessageHandler. |
| 67 */ | 67 */ |
| 68 void Destroy([in] PP_Instance instance, [inout] mem_t user_data); | 68 void Destroy([in] PP_Instance instance, [inout] mem_t user_data); |
| 69 }; | 69 }; |
| 70 | 70 |
| OLD | NEW |