| Index: ppapi/c/private/ppb_talk_private.h
|
| diff --git a/ppapi/c/private/ppb_talk_private.h b/ppapi/c/private/ppb_talk_private.h
|
| index 5783d8b64a69520b19307551a1c695609c8a7ef3..5eff0da5ba518f611f946c9f984a4e3e8ea6468a 100644
|
| --- a/ppapi/c/private/ppb_talk_private.h
|
| +++ b/ppapi/c/private/ppb_talk_private.h
|
| @@ -3,7 +3,7 @@
|
| * found in the LICENSE file.
|
| */
|
|
|
| -/* From private/ppb_talk_private.idl modified Fri Nov 9 14:42:36 2012. */
|
| +/* From private/ppb_talk_private.idl modified Mon Jun 3 16:47:10 2013. */
|
|
|
| #ifndef PPAPI_C_PRIVATE_PPB_TALK_PRIVATE_H_
|
| #define PPAPI_C_PRIVATE_PPB_TALK_PRIVATE_H_
|
| @@ -15,28 +15,85 @@
|
| #include "ppapi/c/pp_stdint.h"
|
|
|
| #define PPB_TALK_PRIVATE_INTERFACE_1_0 "PPB_Talk_Private;1.0"
|
| -#define PPB_TALK_PRIVATE_INTERFACE PPB_TALK_PRIVATE_INTERFACE_1_0
|
| +#define PPB_TALK_PRIVATE_INTERFACE_2_0 "PPB_Talk_Private;2.0"
|
| +#define PPB_TALK_PRIVATE_INTERFACE PPB_TALK_PRIVATE_INTERFACE_2_0
|
|
|
| /**
|
| * @file
|
| - * This file contains the <code>PPB_Talk</code> interface.
|
| + * This file contains the <code>PPB_Talk_Private</code> interface.
|
| */
|
|
|
|
|
| /**
|
| + * @addtogroup Enums
|
| + * @{
|
| + */
|
| +/**
|
| + * The type of permissions that can be requested to the user.
|
| + */
|
| +typedef enum {
|
| + /**
|
| + * Request permission for screencast.
|
| + */
|
| + PP_TALKPERMISSION_SCREENCAST = 0,
|
| + /**
|
| + * Request permission for Remote Desktop.
|
| + */
|
| + PP_TALKPERMISSION_REMOTING = 1,
|
| + /**
|
| + * Request permission for continuing Remote Desktop.
|
| + */
|
| + PP_TALKPERMISSION_REMOTING_CONTINUE = 2
|
| +} PP_TalkPermission;
|
| +PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_TalkPermission, 4);
|
| +
|
| +/**
|
| + * Talk event types reported by the browser.
|
| + */
|
| +typedef enum {
|
| + /**
|
| + * Indicates that the user took action to terminate the remoting session.
|
| + */
|
| + PP_TALKEVENT_TERMINATE = 0,
|
| + /**
|
| + * Indicates that an error occurred (e.g. failed to show the UI).
|
| + */
|
| + PP_TALKEVENT_ERROR = 1
|
| +} PP_TalkEvent;
|
| +PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_TalkEvent, 4);
|
| +/**
|
| + * @}
|
| + */
|
| +
|
| +/**
|
| + * @addtogroup Typedefs
|
| + * @{
|
| + */
|
| +/**
|
| + * Callback for Talk events.
|
| + */
|
| +typedef void (*PP_TalkEventCallback)(void* user_data, PP_TalkEvent event);
|
| +/**
|
| + * @}
|
| + */
|
| +
|
| +/**
|
| * @addtogroup Interfaces
|
| * @{
|
| */
|
| /**
|
| * Extra interface for Talk.
|
| */
|
| -struct PPB_Talk_Private_1_0 {
|
| +struct PPB_Talk_Private_2_0 {
|
| /**
|
| * Creates a Talk_Private resource.
|
| */
|
| PP_Resource (*Create)(PP_Instance instance);
|
| /**
|
| - * Displays security UI.
|
| + * Requests permission to the user using a system modal dialog.
|
| + *
|
| + * <code>permission</code> specifies the type of permission to request to the
|
| + * user.
|
| *
|
| * The callback will be issued with 1 as the result if the user gave
|
| * permission, or 0 if the user denied.
|
| @@ -45,11 +102,36 @@ struct PPB_Talk_Private_1_0 {
|
| * if the request is queued, or PP_ERROR_INPROGRESS if there is already a
|
| * request in progress.
|
| */
|
| + int32_t (*RequestPermission)(PP_Resource talk_resource,
|
| + PP_TalkPermission permission,
|
| + struct PP_CompletionCallback callback);
|
| + /**
|
| + * Shows the remoting-in-progress UI and registers a callback for events.
|
| + * This function executes synchronously. Returns PP_OK if there were no
|
| + * errors.
|
| + *
|
| + * This must be called on the pepper main thread. Similarly, |event_callback|
|
| + * will be called on the pepper main thread.
|
| + */
|
| + int32_t (*StartRemoting)(PP_Resource talk_resource,
|
| + PP_TalkEventCallback event_callback,
|
| + void* user_data);
|
| + /**
|
| + * Hides the remoting-in-progress UI and unregisters the event callback.
|
| + *
|
| + * This must be called on the pepper main thread. Any pending notifications
|
| + * will be discarded.
|
| + */
|
| + void (*StopRemoting)(PP_Resource talk_resource);
|
| +};
|
| +
|
| +typedef struct PPB_Talk_Private_2_0 PPB_Talk_Private;
|
| +
|
| +struct PPB_Talk_Private_1_0 {
|
| + PP_Resource (*Create)(PP_Instance instance);
|
| int32_t (*GetPermission)(PP_Resource talk_resource,
|
| struct PP_CompletionCallback callback);
|
| };
|
| -
|
| -typedef struct PPB_Talk_Private_1_0 PPB_Talk_Private;
|
| /**
|
| * @}
|
| */
|
|
|