include: refactor FRDP_ types to RDP_

This commit is contained in:
Marc-André Moreau 2011-08-17 17:28:26 -04:00
parent c2bc695d39
commit 09980c8a7c
41 changed files with 254 additions and 293 deletions

View File

@ -36,7 +36,7 @@
#define CFSTR_JPEG "J\0F\0I\0F\0\0"
#define CFSTR_GIF "G\0I\0F\0\0"
void cliprdr_process_format_list_event(cliprdrPlugin* cliprdr, FRDP_CB_FORMAT_LIST_EVENT* cb_event)
void cliprdr_process_format_list_event(cliprdrPlugin* cliprdr, RDP_CB_FORMAT_LIST_EVENT* cb_event)
{
STREAM* data_out;
int i;
@ -77,14 +77,14 @@ static void cliprdr_send_format_list_response(cliprdrPlugin* cliprdr)
void cliprdr_process_format_list(cliprdrPlugin* cliprdr, STREAM* data_in, uint32 dataLen)
{
FRDP_CB_FORMAT_LIST_EVENT* cb_event;
RDP_CB_FORMAT_LIST_EVENT* cb_event;
uint32 format;
int num_formats;
int supported;
int i;
cb_event = (FRDP_CB_FORMAT_LIST_EVENT*)freerdp_event_new(FRDP_EVENT_CLASS_CLIPRDR,
FRDP_EVENT_TYPE_CB_FORMAT_LIST, NULL, NULL);
cb_event = (RDP_CB_FORMAT_LIST_EVENT*)freerdp_event_new(RDP_EVENT_CLASS_CLIPRDR,
RDP_EVENT_TYPE_CB_FORMAT_LIST, NULL, NULL);
num_formats = dataLen / 36;
cb_event->formats = (uint32*)xmalloc(sizeof(uint32) * num_formats);
cb_event->num_formats = 0;
@ -131,21 +131,21 @@ void cliprdr_process_format_list(cliprdrPlugin* cliprdr, STREAM* data_in, uint32
cb_event->formats[cb_event->num_formats++] = format;
}
svc_plugin_send_event((rdpSvcPlugin*)cliprdr, (FRDP_EVENT*)cb_event);
svc_plugin_send_event((rdpSvcPlugin*)cliprdr, (RDP_EVENT*)cb_event);
cliprdr_send_format_list_response(cliprdr);
}
void cliprdr_process_format_data_request(cliprdrPlugin* cliprdr, STREAM* data_in)
{
FRDP_CB_DATA_REQUEST_EVENT* cb_event;
RDP_CB_DATA_REQUEST_EVENT* cb_event;
cb_event = (FRDP_CB_DATA_REQUEST_EVENT*)freerdp_event_new(FRDP_EVENT_CLASS_CLIPRDR,
FRDP_EVENT_TYPE_CB_DATA_REQUEST, NULL, NULL);
cb_event = (RDP_CB_DATA_REQUEST_EVENT*)freerdp_event_new(RDP_EVENT_CLASS_CLIPRDR,
RDP_EVENT_TYPE_CB_DATA_REQUEST, NULL, NULL);
stream_read_uint32(data_in, cb_event->format);
svc_plugin_send_event((rdpSvcPlugin*)cliprdr, (FRDP_EVENT*)cb_event);
svc_plugin_send_event((rdpSvcPlugin*)cliprdr, (RDP_EVENT*)cb_event);
}
void cliprdr_process_format_data_response_event(cliprdrPlugin* cliprdr, FRDP_CB_DATA_RESPONSE_EVENT* cb_event)
void cliprdr_process_format_data_response_event(cliprdrPlugin* cliprdr, RDP_CB_DATA_RESPONSE_EVENT* cb_event)
{
STREAM* data_out;
@ -154,7 +154,7 @@ void cliprdr_process_format_data_response_event(cliprdrPlugin* cliprdr, FRDP_CB_
cliprdr_packet_send(cliprdr, data_out);
}
void cliprdr_process_format_data_request_event(cliprdrPlugin* cliprdr, FRDP_CB_DATA_REQUEST_EVENT* cb_event)
void cliprdr_process_format_data_request_event(cliprdrPlugin* cliprdr, RDP_CB_DATA_REQUEST_EVENT* cb_event)
{
STREAM* data_out;
@ -165,12 +165,12 @@ void cliprdr_process_format_data_request_event(cliprdrPlugin* cliprdr, FRDP_CB_D
void cliprdr_process_format_data_response(cliprdrPlugin* cliprdr, STREAM* data_in, uint32 dataLen)
{
FRDP_CB_DATA_RESPONSE_EVENT* cb_event;
RDP_CB_DATA_RESPONSE_EVENT* cb_event;
cb_event = (FRDP_CB_DATA_RESPONSE_EVENT*)freerdp_event_new(FRDP_EVENT_CLASS_CLIPRDR,
FRDP_EVENT_TYPE_CB_DATA_RESPONSE, NULL, NULL);
cb_event = (RDP_CB_DATA_RESPONSE_EVENT*)freerdp_event_new(RDP_EVENT_CLASS_CLIPRDR,
RDP_EVENT_TYPE_CB_DATA_RESPONSE, NULL, NULL);
cb_event->size = dataLen;
cb_event->data = (uint8*)xmalloc(dataLen);
memcpy(cb_event->data, stream_get_tail(data_in), dataLen);
svc_plugin_send_event((rdpSvcPlugin*)cliprdr, (FRDP_EVENT*)cb_event);
svc_plugin_send_event((rdpSvcPlugin*)cliprdr, (RDP_EVENT*)cb_event);
}

View File

@ -21,13 +21,13 @@
#ifndef __CLIPRDR_FORMAT_H
#define __CLIPRDR_FORMAT_H
void cliprdr_process_format_list_event(cliprdrPlugin* cliprdr, FRDP_CB_FORMAT_LIST_EVENT* cb_event);
void cliprdr_process_format_list_event(cliprdrPlugin* cliprdr, RDP_CB_FORMAT_LIST_EVENT* cb_event);
void cliprdr_process_format_list(cliprdrPlugin* cliprdr, STREAM* data_in, uint32 dataLen);
void cliprdr_process_format_data_request(cliprdrPlugin* cliprdr, STREAM* data_in);
void cliprdr_process_format_data_response_event(cliprdrPlugin* cliprdr, FRDP_CB_DATA_RESPONSE_EVENT* cb_event);
void cliprdr_process_format_data_response_event(cliprdrPlugin* cliprdr, RDP_CB_DATA_RESPONSE_EVENT* cb_event);
void cliprdr_process_format_data_request_event(cliprdrPlugin* cliprdr, FRDP_CB_DATA_REQUEST_EVENT* cb_event);
void cliprdr_process_format_data_request_event(cliprdrPlugin* cliprdr, RDP_CB_DATA_REQUEST_EVENT* cb_event);
void cliprdr_process_format_data_response(cliprdrPlugin* cliprdr, STREAM* data_in, uint32 dataLen);
#endif /* __CLIPRDR_FORMAT_H */

View File

@ -89,11 +89,11 @@ static void cliprdr_send_clip_caps(cliprdrPlugin* cliprdr)
static void cliprdr_process_monitor_ready(cliprdrPlugin* cliprdr)
{
FRDP_EVENT* event;
RDP_EVENT* event;
cliprdr_send_clip_caps(cliprdr);
event = freerdp_event_new(FRDP_EVENT_CLASS_CLIPRDR, FRDP_EVENT_TYPE_CB_SYNC, NULL, NULL);
event = freerdp_event_new(RDP_EVENT_CLASS_CLIPRDR, RDP_EVENT_TYPE_CB_SYNC, NULL, NULL);
svc_plugin_send_event((rdpSvcPlugin*)cliprdr, event);
}
@ -143,20 +143,20 @@ static void cliprdr_process_receive(rdpSvcPlugin* plugin, STREAM* data_in)
stream_free(data_in);
}
static void cliprdr_process_event(rdpSvcPlugin* plugin, FRDP_EVENT* event)
static void cliprdr_process_event(rdpSvcPlugin* plugin, RDP_EVENT* event)
{
switch (event->event_type)
{
case FRDP_EVENT_TYPE_CB_FORMAT_LIST:
cliprdr_process_format_list_event((cliprdrPlugin*)plugin, (FRDP_CB_FORMAT_LIST_EVENT*)event);
case RDP_EVENT_TYPE_CB_FORMAT_LIST:
cliprdr_process_format_list_event((cliprdrPlugin*)plugin, (RDP_CB_FORMAT_LIST_EVENT*)event);
break;
case FRDP_EVENT_TYPE_CB_DATA_REQUEST:
cliprdr_process_format_data_request_event((cliprdrPlugin*)plugin, (FRDP_CB_DATA_REQUEST_EVENT*)event);
case RDP_EVENT_TYPE_CB_DATA_REQUEST:
cliprdr_process_format_data_request_event((cliprdrPlugin*)plugin, (RDP_CB_DATA_REQUEST_EVENT*)event);
break;
case FRDP_EVENT_TYPE_CB_DATA_RESPONSE:
cliprdr_process_format_data_response_event((cliprdrPlugin*)plugin, (FRDP_CB_DATA_RESPONSE_EVENT*)event);
case RDP_EVENT_TYPE_CB_DATA_RESPONSE:
cliprdr_process_format_data_response_event((cliprdrPlugin*)plugin, (RDP_CB_DATA_RESPONSE_EVENT*)event);
break;
default:

View File

@ -137,7 +137,7 @@ int drdynvc_write_data(drdynvcPlugin* drdynvc, uint32 ChannelId, char* data, uin
return 0;
}
int drdynvc_push_event(drdynvcPlugin* drdynvc, FRDP_EVENT* event)
int drdynvc_push_event(drdynvcPlugin* drdynvc, RDP_EVENT* event)
{
int error;
@ -332,7 +332,7 @@ static void drdynvc_process_connect(rdpSvcPlugin* plugin)
dvcman_init(drdynvc->channel_mgr);
}
static void drdynvc_process_event(rdpSvcPlugin* plugin, FRDP_EVENT* event)
static void drdynvc_process_event(rdpSvcPlugin* plugin, RDP_EVENT* event)
{
freerdp_event_free(event);
}

View File

@ -25,6 +25,6 @@
typedef struct drdynvc_plugin drdynvcPlugin;
int drdynvc_write_data(drdynvcPlugin* plugin, uint32 ChannelId, char* data, uint32 data_size);
int drdynvc_push_event(drdynvcPlugin* plugin, FRDP_EVENT* event);
int drdynvc_push_event(drdynvcPlugin* plugin, RDP_EVENT* event);
#endif

View File

@ -64,7 +64,7 @@ struct _DVCMAN_ENTRY_POINTS
IDRDYNVC_ENTRY_POINTS iface;
DVCMAN* dvcman;
FRDP_PLUGIN_DATA* plugin_data;
RDP_PLUGIN_DATA* plugin_data;
};
typedef struct _DVCMAN_CHANNEL DVCMAN_CHANNEL;
@ -119,7 +119,7 @@ static int dvcman_create_listener(IWTSVirtualChannelManager* pChannelMgr,
}
static int dvcman_push_event(IWTSVirtualChannelManager* pChannelMgr,
FRDP_EVENT* pEvent)
RDP_EVENT* pEvent)
{
DVCMAN* dvcman = (DVCMAN*)pChannelMgr;
int error;
@ -172,7 +172,7 @@ IWTSPlugin* dvcman_get_plugin(IDRDYNVC_ENTRY_POINTS* pEntryPoints,
return NULL;
}
FRDP_PLUGIN_DATA* dvcman_get_plugin_data(IDRDYNVC_ENTRY_POINTS* pEntryPoints)
RDP_PLUGIN_DATA* dvcman_get_plugin_data(IDRDYNVC_ENTRY_POINTS* pEntryPoints)
{
return ((DVCMAN_ENTRY_POINTS*)pEntryPoints)->plugin_data;
}
@ -190,7 +190,7 @@ IWTSVirtualChannelManager* dvcman_new(drdynvcPlugin* plugin)
return (IWTSVirtualChannelManager*)dvcman;
}
int dvcman_load_plugin(IWTSVirtualChannelManager* pChannelMgr, FRDP_PLUGIN_DATA* data)
int dvcman_load_plugin(IWTSVirtualChannelManager* pChannelMgr, RDP_PLUGIN_DATA* data)
{
DVCMAN_ENTRY_POINTS entryPoints;
PDVC_PLUGIN_ENTRY pDVCPluginEntry = NULL;

View File

@ -24,7 +24,7 @@
#include "drdynvc_main.h"
IWTSVirtualChannelManager* dvcman_new(drdynvcPlugin* plugin);
int dvcman_load_plugin(IWTSVirtualChannelManager* pChannelMgr, FRDP_PLUGIN_DATA* data);
int dvcman_load_plugin(IWTSVirtualChannelManager* pChannelMgr, RDP_PLUGIN_DATA* data);
void dvcman_free(IWTSVirtualChannelManager* pChannelMgr);
int dvcman_init(IWTSVirtualChannelManager* pChannelMgr);
int dvcman_create_channel(IWTSVirtualChannelManager* pChannelMgr, uint32 ChannelId, const char* ChannelName);

View File

@ -31,7 +31,7 @@
#include "rail_orders.h"
#include "rail_main.h"
static void rail_send_vchannel_data(void* rail_object, void* data, size_t length)
static void rail_send_channel_data(void* rail_object, void* data, size_t length)
{
STREAM* s = NULL;
railPlugin* plugin = (railPlugin*) rail_object;
@ -42,22 +42,22 @@ static void rail_send_vchannel_data(void* rail_object, void* data, size_t length
svc_plugin_send((rdpSvcPlugin*) plugin, s);
}
static void on_free_rail_vchannel_event(FRDP_EVENT* event)
static void on_free_rail_channel_event(RDP_EVENT* event)
{
}
static void rail_send_vchannel_event(void* rail_object, RAIL_VCHANNEL_EVENT* event)
static void rail_send_channel_event(void* rail_object, RAIL_CHANNEL_EVENT* event)
{
railPlugin* plugin = (railPlugin*) rail_object;
RAIL_VCHANNEL_EVENT* payload = NULL;
FRDP_EVENT* out_event = NULL;
RAIL_CHANNEL_EVENT* payload = NULL;
RDP_EVENT* out_event = NULL;
payload = xnew(RAIL_VCHANNEL_EVENT);
memset(payload, 0, sizeof(RAIL_VCHANNEL_EVENT));
memcpy(payload, event, sizeof(RAIL_VCHANNEL_EVENT));
payload = xnew(RAIL_CHANNEL_EVENT);
memset(payload, 0, sizeof(RAIL_CHANNEL_EVENT));
memcpy(payload, event, sizeof(RAIL_CHANNEL_EVENT));
out_event = freerdp_event_new(FRDP_EVENT_CLASS_RAIL, FRDP_EVENT_TYPE_RAIL_VCHANNEL_2_UI, on_free_rail_vchannel_event, payload);
out_event = freerdp_event_new(RDP_EVENT_CLASS_RAIL, RDP_EVENT_TYPE_RAIL_CHANNEL, on_free_rail_channel_event, payload);
svc_plugin_send_event((rdpSvcPlugin*) plugin, out_event);
}
@ -67,13 +67,13 @@ static void rail_process_connect(rdpSvcPlugin* plugin)
railPlugin* rail = (railPlugin*) plugin;
rail->rail_event_sender.event_sender_object = rail;
rail->rail_event_sender.send_rail_vchannel_event = rail_send_vchannel_event;
rail->rail_event_sender.send_rail_vchannel_event = rail_send_channel_event;
rail->rail_data_sender.data_sender_object = rail;
rail->rail_data_sender.send_rail_vchannel_data = rail_send_vchannel_data;
rail->rail_data_sender.send_rail_vchannel_data = rail_send_channel_data;
rail->rail_order = rail_order_new();
rail->rail_order->plugin_data = (FRDP_PLUGIN_DATA*)plugin->channel_entry_points.pExtendedData;
rail->rail_order->plugin_data = (RDP_PLUGIN_DATA*)plugin->channel_entry_points.pExtendedData;
rail->rail_order->data_sender = &(rail->rail_data_sender);
rail->rail_order->event_sender = &(rail->rail_event_sender);
}
@ -90,13 +90,13 @@ static void rail_process_receive(rdpSvcPlugin* plugin, STREAM* s)
stream_free(s);
}
static void rail_process_event(rdpSvcPlugin* plugin, FRDP_EVENT* event)
static void rail_process_event(rdpSvcPlugin* plugin, RDP_EVENT* event)
{
RAIL_UI_EVENT* rail_ui_event = NULL;
RAIL_CLIENT_EVENT* rail_ui_event = NULL;
railPlugin* rail = NULL;
rail = (railPlugin*)plugin;
rail_ui_event = (RAIL_UI_EVENT*)event->user_data;
rail_ui_event = (RAIL_CLIENT_EVENT*)event->user_data;
freerdp_event_free(event);
}

View File

@ -38,13 +38,13 @@ struct _RAIL_VCHANNEL_DATA_SENDER
struct _RAIL_VCHANNEL_EVENT_SENDER
{
void * event_sender_object;
void (*send_rail_vchannel_event)(void* ui_event_sender_object, RAIL_VCHANNEL_EVENT* event);
void (*send_rail_vchannel_event)(void* ui_event_sender_object, RAIL_CHANNEL_EVENT* event);
};
struct rdp_rail_order
{
UNICONV* uniconv;
FRDP_PLUGIN_DATA* plugin_data;
RDP_PLUGIN_DATA* plugin_data;
RAIL_HANDSHAKE_ORDER handshake;
RAIL_CLIENT_STATUS_ORDER client_status;
RAIL_EXEC_ORDER exec;

View File

@ -285,7 +285,7 @@ void rail_write_langbar_info_order(STREAM* s, RAIL_LANGBAR_INFO_ORDER* langbar_i
void rail_recv_handshake_order(rdpRailOrder* rail_order, STREAM* s)
{
FRDP_PLUGIN_DATA* data;
RDP_PLUGIN_DATA* data;
rail_read_handshake_order(s, &rail_order->handshake);
@ -348,7 +348,7 @@ void rail_recv_handshake_order(rdpRailOrder* rail_order, STREAM* s)
rail_send_client_exec_order(rail_order);
data = (FRDP_PLUGIN_DATA*)(((void*)data) + data->size);
data = (RDP_PLUGIN_DATA*)(((void*)data) + data->size);
}
}

View File

@ -49,12 +49,12 @@ static void rdpdbg_process_receive(rdpSvcPlugin* plugin, STREAM* data_in)
svc_plugin_send(plugin, data_out);
}
static void rdpdbg_process_event(rdpSvcPlugin* plugin, FRDP_EVENT* event)
static void rdpdbg_process_event(rdpSvcPlugin* plugin, RDP_EVENT* event)
{
DEBUG_WARN("event_type %d", event->event_type);
freerdp_event_free(event);
event = freerdp_event_new(FRDP_EVENT_CLASS_DEBUG, 0, NULL, NULL);
event = freerdp_event_new(RDP_EVENT_CLASS_DEBUG, 0, NULL, NULL);
svc_plugin_send_event(plugin, event);
}

View File

@ -69,7 +69,7 @@ static void devman_unregister_device(DEVMAN* devman, DEVICE* device)
DEBUG_SVC("device %d.%s unregistered", device->id, device->name);
}
boolean devman_load_device_service(DEVMAN* devman, FRDP_PLUGIN_DATA* plugin_data)
boolean devman_load_device_service(DEVMAN* devman, RDP_PLUGIN_DATA* plugin_data)
{
DEVICE_SERVICE_ENTRY_POINTS ep;
PDEVICE_SERVICE_ENTRY entry;

View File

@ -23,7 +23,7 @@
DEVMAN* devman_new(rdpSvcPlugin* plugin);
void devman_free(DEVMAN* devman);
boolean devman_load_device_service(DEVMAN* devman, FRDP_PLUGIN_DATA* plugin_data);
boolean devman_load_device_service(DEVMAN* devman, RDP_PLUGIN_DATA* plugin_data);
DEVICE* devman_get_device_by_id(DEVMAN* devman, uint32 id);
#endif /* __DEVMAN_H */

View File

@ -43,10 +43,10 @@
static void rdpdr_process_connect(rdpSvcPlugin* plugin)
{
rdpdrPlugin* rdpdr = (rdpdrPlugin*)plugin;
FRDP_PLUGIN_DATA* data;
RDP_PLUGIN_DATA* data;
rdpdr->devman = devman_new(plugin);
data = (FRDP_PLUGIN_DATA*)plugin->channel_entry_points.pExtendedData;
data = (RDP_PLUGIN_DATA*)plugin->channel_entry_points.pExtendedData;
while (data && data->size > 0)
{
if (strcmp((char*)data->data[0], "clientname") == 0)
@ -58,7 +58,7 @@ static void rdpdr_process_connect(rdpSvcPlugin* plugin)
{
devman_load_device_service(rdpdr->devman, data);
}
data = (FRDP_PLUGIN_DATA*)(((void*)data) + data->size);
data = (RDP_PLUGIN_DATA*)(((void*)data) + data->size);
}
}
@ -291,7 +291,7 @@ static void rdpdr_process_receive(rdpSvcPlugin* plugin, STREAM* data_in)
stream_free(data_in);
}
static void rdpdr_process_event(rdpSvcPlugin* plugin, FRDP_EVENT* event)
static void rdpdr_process_event(rdpSvcPlugin* plugin, RDP_EVENT* event)
{
freerdp_event_free(event);
}

View File

@ -79,7 +79,7 @@ struct _DEVICE_SERVICE_ENTRY_POINTS
pcRegisterDevice RegisterDevice;
pcRegisterDevice UnregisterDevice;
FRDP_PLUGIN_DATA* plugin_data;
RDP_PLUGIN_DATA* plugin_data;
};
typedef struct _DEVICE_SERVICE_ENTRY_POINTS DEVICE_SERVICE_ENTRY_POINTS;
typedef DEVICE_SERVICE_ENTRY_POINTS* PDEVICE_SERVICE_ENTRY_POINTS;

View File

@ -311,7 +311,7 @@ static void rdpsnd_alsa_start(rdpsndDevicePlugin* device)
int FreeRDPRdpsndDeviceEntry(PFREERDP_RDPSND_DEVICE_ENTRY_POINTS pEntryPoints)
{
rdpsndAlsaPlugin* alsa;
FRDP_PLUGIN_DATA* data;
RDP_PLUGIN_DATA* data;
alsa = xnew(rdpsndAlsaPlugin);

View File

@ -434,7 +434,7 @@ static void rdpsnd_pulse_start(rdpsndDevicePlugin* device)
int FreeRDPRdpsndDeviceEntry(PFREERDP_RDPSND_DEVICE_ENTRY_POINTS pEntryPoints)
{
rdpsndPulsePlugin* pulse;
FRDP_PLUGIN_DATA* data;
RDP_PLUGIN_DATA* data;
pulse = xnew(rdpsndPulsePlugin);

View File

@ -434,7 +434,7 @@ static void rdpsnd_register_device_plugin(rdpsndPlugin* rdpsnd, rdpsndDevicePlug
rdpsnd->device = device;
}
static boolean rdpsnd_load_device_plugin(rdpsndPlugin* rdpsnd, const char* name, FRDP_PLUGIN_DATA* data)
static boolean rdpsnd_load_device_plugin(rdpsndPlugin* rdpsnd, const char* name, RDP_PLUGIN_DATA* data)
{
FREERDP_RDPSND_DEVICE_ENTRY_POINTS entryPoints;
PFREERDP_RDPSND_DEVICE_ENTRY entry;
@ -466,7 +466,7 @@ static boolean rdpsnd_load_device_plugin(rdpsndPlugin* rdpsnd, const char* name,
return True;
}
static void rdpsnd_process_plugin_data(rdpsndPlugin* rdpsnd, FRDP_PLUGIN_DATA* data)
static void rdpsnd_process_plugin_data(rdpsndPlugin* rdpsnd, RDP_PLUGIN_DATA* data)
{
if (strcmp((char*)data->data[0], "format") == 0)
{
@ -489,8 +489,8 @@ static void rdpsnd_process_plugin_data(rdpsndPlugin* rdpsnd, FRDP_PLUGIN_DATA* d
static void rdpsnd_process_connect(rdpSvcPlugin* plugin)
{
rdpsndPlugin* rdpsnd = (rdpsndPlugin*)plugin;
FRDP_PLUGIN_DATA* data;
FRDP_PLUGIN_DATA default_data[2] = { { 0 }, { 0 } };
RDP_PLUGIN_DATA* data;
RDP_PLUGIN_DATA default_data[2] = { { 0 }, { 0 } };
DEBUG_SVC("connecting");
@ -498,16 +498,16 @@ static void rdpsnd_process_connect(rdpSvcPlugin* plugin)
rdpsnd->data_out_list = list_new();
data = (FRDP_PLUGIN_DATA*)plugin->channel_entry_points.pExtendedData;
data = (RDP_PLUGIN_DATA*)plugin->channel_entry_points.pExtendedData;
while (data && data->size > 0)
{
rdpsnd_process_plugin_data(rdpsnd, data);
data = (FRDP_PLUGIN_DATA*) (((void*) data) + data->size);
data = (RDP_PLUGIN_DATA*) (((void*) data) + data->size);
}
if (rdpsnd->device == NULL)
{
default_data[0].size = sizeof(FRDP_PLUGIN_DATA);
default_data[0].size = sizeof(RDP_PLUGIN_DATA);
default_data[0].data[0] = "pulse";
default_data[0].data[1] = "";
if (!rdpsnd_load_device_plugin(rdpsnd, "pulse", default_data))
@ -523,7 +523,7 @@ static void rdpsnd_process_connect(rdpSvcPlugin* plugin)
}
}
static void rdpsnd_process_event(rdpSvcPlugin* plugin, FRDP_EVENT* event)
static void rdpsnd_process_event(rdpSvcPlugin* plugin, RDP_EVENT* event)
{
freerdp_event_free(event);
}

View File

@ -65,7 +65,7 @@ struct _FREERDP_RDPSND_DEVICE_ENTRY_POINTS
{
rdpsndPlugin* rdpsnd;
PREGISTERRDPSNDDEVICE pRegisterRdpsndDevice;
FRDP_PLUGIN_DATA* plugin_data;
RDP_PLUGIN_DATA* plugin_data;
};
typedef struct _FREERDP_RDPSND_DEVICE_ENTRY_POINTS FREERDP_RDPSND_DEVICE_ENTRY_POINTS;
typedef FREERDP_RDPSND_DEVICE_ENTRY_POINTS* PFREERDP_RDPSND_DEVICE_ENTRY_POINTS;

View File

@ -191,7 +191,7 @@ boolean df_post_connect(freerdp* instance)
}
static int df_process_plugin_args(rdpSettings* settings, const char* name,
FRDP_PLUGIN_DATA* plugin_data, void* user_data)
RDP_PLUGIN_DATA* plugin_data, void* user_data)
{
rdpChanMan* chanman = (rdpChanMan*) user_data;
@ -210,12 +210,12 @@ df_receive_channel_data(freerdp* instance, int channelId, uint8* data, int size,
static void
df_process_cb_sync_event(rdpChanMan* chanman, freerdp* instance)
{
FRDP_EVENT* event;
FRDP_CB_FORMAT_LIST_EVENT* format_list_event;
RDP_EVENT* event;
RDP_CB_FORMAT_LIST_EVENT* format_list_event;
event = freerdp_event_new(FRDP_EVENT_CLASS_CLIPRDR, FRDP_EVENT_TYPE_CB_FORMAT_LIST, NULL, NULL);
event = freerdp_event_new(RDP_EVENT_CLASS_CLIPRDR, RDP_EVENT_TYPE_CB_FORMAT_LIST, NULL, NULL);
format_list_event = (FRDP_CB_FORMAT_LIST_EVENT*)event;
format_list_event = (RDP_CB_FORMAT_LIST_EVENT*)event;
format_list_event->num_formats = 0;
freerdp_chanman_send_event(chanman, event);
@ -224,14 +224,14 @@ df_process_cb_sync_event(rdpChanMan* chanman, freerdp* instance)
static void
df_process_channel_event(rdpChanMan* chanman, freerdp* instance)
{
FRDP_EVENT* event;
RDP_EVENT* event;
event = freerdp_chanman_pop_event(chanman);
if (event)
{
switch (event->event_type)
{
case FRDP_EVENT_TYPE_CB_SYNC:
case RDP_EVENT_TYPE_CB_SYNC:
df_process_cb_sync_event(chanman, instance);
break;
default:

View File

@ -333,7 +333,7 @@ boolean xf_post_connect(freerdp* instance)
return True;
}
int xf_process_plugin_args(rdpSettings* settings, const char* name, FRDP_PLUGIN_DATA* plugin_data, void* user_data)
int xf_process_plugin_args(rdpSettings* settings, const char* name, RDP_PLUGIN_DATA* plugin_data, void* user_data)
{
rdpChanMan* chanman = (rdpChanMan*) user_data;
@ -350,12 +350,12 @@ int xf_receive_channel_data(freerdp* instance, int channelId, uint8* data, int s
void xf_process_cb_sync_event(rdpChanMan* chanman, freerdp* instance)
{
FRDP_EVENT* event;
FRDP_CB_FORMAT_LIST_EVENT* format_list_event;
RDP_EVENT* event;
RDP_CB_FORMAT_LIST_EVENT* format_list_event;
event = freerdp_event_new(FRDP_EVENT_CLASS_CLIPRDR, FRDP_EVENT_TYPE_CB_FORMAT_LIST, NULL, NULL);
event = freerdp_event_new(RDP_EVENT_CLASS_CLIPRDR, RDP_EVENT_TYPE_CB_FORMAT_LIST, NULL, NULL);
format_list_event = (FRDP_CB_FORMAT_LIST_EVENT*)event;
format_list_event = (RDP_CB_FORMAT_LIST_EVENT*)event;
format_list_event->num_formats = 0;
freerdp_chanman_send_event(chanman, event);
@ -363,17 +363,17 @@ void xf_process_cb_sync_event(rdpChanMan* chanman, freerdp* instance)
void xf_process_channel_event(rdpChanMan* chanman, freerdp* instance)
{
FRDP_EVENT* event;
RDP_EVENT* event;
event = freerdp_chanman_pop_event(chanman);
if (event)
{
switch (event->event_type)
{
case FRDP_EVENT_TYPE_CB_SYNC:
case RDP_EVENT_TYPE_CB_SYNC:
xf_process_cb_sync_event(chanman, instance);
break;
case FRDP_EVENT_TYPE_RAIL_VCHANNEL_2_UI:
case RDP_EVENT_TYPE_RAIL_CHANNEL:
xf_process_rail_event(chanman, instance);
break;
default:

View File

@ -85,7 +85,7 @@ int tf_receive_channel_data(freerdp* instance, int channelId, uint8* data, int s
return freerdp_chanman_data(instance, channelId, data, size, flags, total_size);
}
int tf_process_plugin_args(rdpSettings* settings, const char* name, FRDP_PLUGIN_DATA* plugin_data, void* user_data)
int tf_process_plugin_args(rdpSettings* settings, const char* name, RDP_PLUGIN_DATA* plugin_data, void* user_data)
{
rdpChanMan* chanman = (rdpChanMan*) user_data;
@ -97,12 +97,12 @@ int tf_process_plugin_args(rdpSettings* settings, const char* name, FRDP_PLUGIN_
void tf_process_cb_sync_event(rdpChanMan* chanman, freerdp* instance)
{
FRDP_EVENT* event;
FRDP_CB_FORMAT_LIST_EVENT* format_list_event;
RDP_EVENT* event;
RDP_CB_FORMAT_LIST_EVENT* format_list_event;
event = freerdp_event_new(FRDP_EVENT_CLASS_CLIPRDR, FRDP_EVENT_TYPE_CB_FORMAT_LIST, NULL, NULL);
event = freerdp_event_new(RDP_EVENT_CLASS_CLIPRDR, RDP_EVENT_TYPE_CB_FORMAT_LIST, NULL, NULL);
format_list_event = (FRDP_CB_FORMAT_LIST_EVENT*)event;
format_list_event = (RDP_CB_FORMAT_LIST_EVENT*)event;
format_list_event->num_formats = 0;
freerdp_chanman_send_event(chanman, event);
@ -110,14 +110,14 @@ void tf_process_cb_sync_event(rdpChanMan* chanman, freerdp* instance)
void tf_process_channel_event(rdpChanMan* chanman, freerdp* instance)
{
FRDP_EVENT* event;
RDP_EVENT* event;
event = freerdp_chanman_pop_event(chanman);
if (event)
{
switch (event->event_type)
{
case FRDP_EVENT_TYPE_CB_SYNC:
case RDP_EVENT_TYPE_CB_SYNC:
tf_process_cb_sync_event(chanman, instance);
break;
default:

View File

@ -59,7 +59,7 @@ void test_chanman(void)
rdpChanMan* chan_man;
rdpSettings settings = { 0 };
freerdp instance = { 0 };
FRDP_EVENT* event;
RDP_EVENT* event;
settings.hostname = "testhost";
instance.settings = &settings;
@ -76,7 +76,7 @@ void test_chanman(void)
freerdp_chanman_data(&instance, 0, "testdata11", 10, CHANNEL_FLAG_FIRST | CHANNEL_FLAG_LAST, 10);
freerdp_chanman_data(&instance, 0, "testdata111", 11, CHANNEL_FLAG_FIRST | CHANNEL_FLAG_LAST, 11);
event = freerdp_event_new(FRDP_EVENT_CLASS_DEBUG, 0, NULL, NULL);
event = freerdp_event_new(RDP_EVENT_CLASS_DEBUG, 0, NULL, NULL);
freerdp_chanman_send_event(chan_man, event);
while ((event = freerdp_chanman_pop_event(chan_man)) == NULL)

View File

@ -96,7 +96,7 @@ static int test_rdp_channel_data(freerdp* instance, int chan_id, uint8* data, in
static int event_processed;
static void event_process_callback(FRDP_EVENT* event)
static void event_process_callback(RDP_EVENT* event)
{
printf("Event %d processed.\n", event->event_type);
event_processed = 1;
@ -108,10 +108,10 @@ void test_cliprdr(void)
rdpChanMan* chan_man;
rdpSettings settings = { 0 };
freerdp instance = { 0 };
FRDP_EVENT* event;
FRDP_CB_FORMAT_LIST_EVENT* format_list_event;
FRDP_CB_DATA_REQUEST_EVENT* data_request_event;
FRDP_CB_DATA_RESPONSE_EVENT* data_response_event;
RDP_EVENT* event;
RDP_CB_FORMAT_LIST_EVENT* format_list_event;
RDP_CB_DATA_REQUEST_EVENT* data_request_event;
RDP_CB_DATA_RESPONSE_EVENT* data_response_event;
settings.hostname = "testhost";
instance.settings = &settings;
@ -136,12 +136,12 @@ void test_cliprdr(void)
freerdp_chanman_check_fds(chan_man, &instance);
}
printf("Got event %d\n", event->event_type);
CU_ASSERT(event->event_type == FRDP_EVENT_TYPE_CB_SYNC);
CU_ASSERT(event->event_type == RDP_EVENT_TYPE_CB_SYNC);
freerdp_event_free(event);
/* UI sends format_list event to cliprdr */
event = freerdp_event_new(FRDP_EVENT_CLASS_CLIPRDR, FRDP_EVENT_TYPE_CB_FORMAT_LIST, event_process_callback, NULL);
format_list_event = (FRDP_CB_FORMAT_LIST_EVENT*)event;
event = freerdp_event_new(RDP_EVENT_CLASS_CLIPRDR, RDP_EVENT_TYPE_CB_FORMAT_LIST, event_process_callback, NULL);
format_list_event = (RDP_CB_FORMAT_LIST_EVENT*)event;
format_list_event->num_formats = 2;
format_list_event->formats = (uint32*)xmalloc(sizeof(uint32) * 2);
format_list_event->formats[0] = CB_FORMAT_TEXT;
@ -169,10 +169,10 @@ void test_cliprdr(void)
freerdp_chanman_check_fds(chan_man, &instance);
}
printf("Got event %d\n", event->event_type);
CU_ASSERT(event->event_type == FRDP_EVENT_TYPE_CB_FORMAT_LIST);
if (event->event_type == FRDP_EVENT_TYPE_CB_FORMAT_LIST)
CU_ASSERT(event->event_type == RDP_EVENT_TYPE_CB_FORMAT_LIST);
if (event->event_type == RDP_EVENT_TYPE_CB_FORMAT_LIST)
{
format_list_event = (FRDP_CB_FORMAT_LIST_EVENT*)event;
format_list_event = (RDP_CB_FORMAT_LIST_EVENT*)event;
for (i = 0; i < format_list_event->num_formats; i++)
printf("Format: 0x%X\n", format_list_event->formats[i]);
}
@ -188,17 +188,17 @@ void test_cliprdr(void)
freerdp_chanman_check_fds(chan_man, &instance);
}
printf("Got event %d\n", event->event_type);
CU_ASSERT(event->event_type == FRDP_EVENT_TYPE_CB_DATA_REQUEST);
if (event->event_type == FRDP_EVENT_TYPE_CB_DATA_REQUEST)
CU_ASSERT(event->event_type == RDP_EVENT_TYPE_CB_DATA_REQUEST);
if (event->event_type == RDP_EVENT_TYPE_CB_DATA_REQUEST)
{
data_request_event = (FRDP_CB_DATA_REQUEST_EVENT*)event;
data_request_event = (RDP_CB_DATA_REQUEST_EVENT*)event;
printf("Requested format: 0x%X\n", data_request_event->format);
}
freerdp_event_free(event);
/* UI sends data response event to cliprdr */
event = freerdp_event_new(FRDP_EVENT_CLASS_CLIPRDR, FRDP_EVENT_TYPE_CB_DATA_RESPONSE, event_process_callback, NULL);
data_response_event = (FRDP_CB_DATA_RESPONSE_EVENT*)event;
event = freerdp_event_new(RDP_EVENT_CLASS_CLIPRDR, RDP_EVENT_TYPE_CB_DATA_RESPONSE, event_process_callback, NULL);
data_response_event = (RDP_CB_DATA_RESPONSE_EVENT*)event;
data_response_event->data = (uint8*)xmalloc(6);
strcpy((char*)data_response_event->data, "hello");
data_response_event->size = 6;
@ -212,8 +212,8 @@ void test_cliprdr(void)
}
/* UI sends data request event to cliprdr */
event = freerdp_event_new(FRDP_EVENT_CLASS_CLIPRDR, FRDP_EVENT_TYPE_CB_DATA_REQUEST, event_process_callback, NULL);
data_request_event = (FRDP_CB_DATA_REQUEST_EVENT*)event;
event = freerdp_event_new(RDP_EVENT_CLASS_CLIPRDR, RDP_EVENT_TYPE_CB_DATA_REQUEST, event_process_callback, NULL);
data_request_event = (RDP_CB_DATA_REQUEST_EVENT*)event;
data_request_event->format = CB_FORMAT_UNICODETEXT;
event_processed = 0;
freerdp_chanman_send_event(chan_man, event);
@ -234,10 +234,10 @@ void test_cliprdr(void)
freerdp_chanman_check_fds(chan_man, &instance);
}
printf("Got event %d\n", event->event_type);
CU_ASSERT(event->event_type == FRDP_EVENT_TYPE_CB_DATA_RESPONSE);
if (event->event_type == FRDP_EVENT_TYPE_CB_DATA_RESPONSE)
CU_ASSERT(event->event_type == RDP_EVENT_TYPE_CB_DATA_RESPONSE);
if (event->event_type == RDP_EVENT_TYPE_CB_DATA_RESPONSE)
{
data_response_event = (FRDP_CB_DATA_RESPONSE_EVENT*)event;
data_response_event = (RDP_CB_DATA_RESPONSE_EVENT*)event;
printf("Data response size: %d\n", data_response_event->size);
freerdp_hexdump(data_response_event->data, data_response_event->size);
}

View File

@ -1510,7 +1510,7 @@ void test_gdi_LineTo(void)
HGDI_BITMAP hBmp_LineTo_R2_MERGEPENNOT;
HGDI_BITMAP hBmp_LineTo_R2_MERGEPEN;
HGDI_BITMAP hBmp_LineTo_R2_WHITE;
FRDP_PALETTE* hPalette;
RDP_PALETTE* hPalette;
HCLRCONV clrconv;
int bitsPerPixel = 8;
int bytesPerPixel = 1;
@ -1526,7 +1526,7 @@ void test_gdi_LineTo(void)
hBmp = gdi_CreateCompatibleBitmap(hdc, 16, 16);
gdi_SelectObject(hdc, (HGDIOBJECT) hBmp);
hPalette = (FRDP_PALETTE*) gdi_GetSystemPalette();
hPalette = (RDP_PALETTE*) gdi_GetSystemPalette();
clrconv = (HCLRCONV) malloc(sizeof(CLRCONV));
clrconv->alpha = 1;
@ -1828,7 +1828,7 @@ void test_gdi_Ellipse(void)
HGDI_BITMAP hBmp_Ellipse_1;
HGDI_BITMAP hBmp_Ellipse_2;
HGDI_BITMAP hBmp_Ellipse_3;
FRDP_PALETTE* hPalette;
RDP_PALETTE* hPalette;
HCLRCONV clrconv;
int bitsPerPixel = 8;
int bytesPerPixel = 1;
@ -1844,7 +1844,7 @@ void test_gdi_Ellipse(void)
hBmp = gdi_CreateCompatibleBitmap(hdc, 16, 16);
gdi_SelectObject(hdc, (HGDIOBJECT) hBmp);
hPalette = (FRDP_PALETTE*) gdi_GetSystemPalette();
hPalette = (RDP_PALETTE*) gdi_GetSystemPalette();
clrconv = (HCLRCONV) malloc(sizeof(CLRCONV));
clrconv->alpha = 1;
@ -1988,7 +1988,7 @@ void test_gdi_BitBlt_32bpp(void)
HGDI_BITMAP hBmp_PATPAINT;
HGDI_BITMAP hBmp_PATINVERT;
HGDI_BITMAP hBmpDstOriginal;
FRDP_PALETTE* hPalette;
RDP_PALETTE* hPalette;
HCLRCONV clrconv;
int bytesPerPixel = 4;
@ -2002,7 +2002,7 @@ void test_gdi_BitBlt_32bpp(void)
hdcDst->bytesPerPixel = bytesPerPixel;
hdcDst->bitsPerPixel = bitsPerPixel;
hPalette = (FRDP_PALETTE*) gdi_GetSystemPalette();
hPalette = (RDP_PALETTE*) gdi_GetSystemPalette();
clrconv = (HCLRCONV) malloc(sizeof(CLRCONV));
clrconv->alpha = 1;
@ -2242,7 +2242,7 @@ void test_gdi_BitBlt_16bpp(void)
HGDI_BITMAP hBmp_PATPAINT;
HGDI_BITMAP hBmp_PATINVERT;
HGDI_BITMAP hBmpDstOriginal;
FRDP_PALETTE* hPalette;
RDP_PALETTE* hPalette;
HCLRCONV clrconv;
int bytesPerPixel = 2;
@ -2256,7 +2256,7 @@ void test_gdi_BitBlt_16bpp(void)
hdcDst->bytesPerPixel = bytesPerPixel;
hdcDst->bitsPerPixel = bitsPerPixel;
hPalette = (FRDP_PALETTE*) gdi_GetSystemPalette();
hPalette = (RDP_PALETTE*) gdi_GetSystemPalette();
clrconv = (HCLRCONV) malloc(sizeof(CLRCONV));
clrconv->alpha = 1;
@ -2496,7 +2496,7 @@ void test_gdi_BitBlt_8bpp(void)
HGDI_BITMAP hBmp_PATPAINT;
HGDI_BITMAP hBmp_PATINVERT;
HGDI_BITMAP hBmpDstOriginal;
FRDP_PALETTE* hPalette;
RDP_PALETTE* hPalette;
HCLRCONV clrconv;
int bytesPerPixel = 1;
@ -2510,7 +2510,7 @@ void test_gdi_BitBlt_8bpp(void)
hdcDst->bytesPerPixel = bytesPerPixel;
hdcDst->bitsPerPixel = bitsPerPixel;
hPalette = (FRDP_PALETTE*) gdi_GetSystemPalette();
hPalette = (RDP_PALETTE*) gdi_GetSystemPalette();
clrconv = (HCLRCONV) malloc(sizeof(CLRCONV));
clrconv->alpha = 1;

View File

@ -109,7 +109,7 @@ void test_wait_obj(void)
}
static int process_plugin_args(rdpSettings* settings, const char* name,
FRDP_PLUGIN_DATA* plugin_data, void* user_data)
RDP_PLUGIN_DATA* plugin_data, void* user_data)
{
/*printf("load plugin: %s\n", name);*/
return 1;

View File

@ -40,11 +40,11 @@ FREERDP_API int freerdp_chanman_pre_connect(rdpChanMan* chan_man, freerdp* insta
FREERDP_API int freerdp_chanman_post_connect(rdpChanMan* chan_man, freerdp* instance);
FREERDP_API int freerdp_chanman_data(freerdp* instance, int chan_id, void* data, int data_size,
int flags, int total_size);
FREERDP_API int freerdp_chanman_send_event(rdpChanMan* chan_man, FRDP_EVENT* event);
FREERDP_API int freerdp_chanman_send_event(rdpChanMan* chan_man, RDP_EVENT* event);
FREERDP_API boolean freerdp_chanman_get_fds(rdpChanMan* chan_man, freerdp* instance, void** read_fds,
int* read_count, void** write_fds, int* write_count);
FREERDP_API boolean freerdp_chanman_check_fds(rdpChanMan* chan_man, freerdp* instance);
FREERDP_API FRDP_EVENT* freerdp_chanman_pop_event(rdpChanMan* chan_man);
FREERDP_API RDP_EVENT* freerdp_chanman_pop_event(rdpChanMan* chan_man);
FREERDP_API void freerdp_chanman_close(rdpChanMan* chan_man, freerdp* instance);
#ifdef __cplusplus

View File

@ -91,7 +91,7 @@ struct _IWTSVirtualChannelManager
/* Push a virtual channel event.
This is a FreeRDP extension to standard MS API. */
int (*PushEvent) (IWTSVirtualChannelManager* pChannelMgr,
FRDP_EVENT* pEvent);
RDP_EVENT* pEvent);
};
struct _IWTSPlugin
@ -141,7 +141,7 @@ struct _IDRDYNVC_ENTRY_POINTS
const char* name, IWTSPlugin* pPlugin);
IWTSPlugin* (*GetPlugin) (IDRDYNVC_ENTRY_POINTS* pEntryPoints,
const char* name);
FRDP_PLUGIN_DATA* (*GetPluginData) (IDRDYNVC_ENTRY_POINTS* pEntryPoints);
RDP_PLUGIN_DATA* (*GetPluginData) (IDRDYNVC_ENTRY_POINTS* pEntryPoints);
};
typedef int (*PDVC_PLUGIN_ENTRY) (IDRDYNVC_ENTRY_POINTS*);

View File

@ -227,7 +227,7 @@ struct _CLRCONV
int alpha;
int invert;
int rgb555;
FRDP_PALETTE* palette;
RDP_PALETTE* palette;
};
typedef struct _CLRCONV CLRCONV;
typedef CLRCONV* HCLRCONV;

View File

@ -23,18 +23,18 @@
/**
* Event Types
*/
enum FRDP_EVENT_TYPE_CB
enum RDP_EVENT_TYPE_CB
{
FRDP_EVENT_TYPE_CB_SYNC = 1,
FRDP_EVENT_TYPE_CB_FORMAT_LIST,
FRDP_EVENT_TYPE_CB_DATA_REQUEST,
FRDP_EVENT_TYPE_CB_DATA_RESPONSE
RDP_EVENT_TYPE_CB_SYNC = 1,
RDP_EVENT_TYPE_CB_FORMAT_LIST,
RDP_EVENT_TYPE_CB_DATA_REQUEST,
RDP_EVENT_TYPE_CB_DATA_RESPONSE
};
/**
* Clipboard Formats
*/
enum FRDP_CB_FORMAT
enum RDP_CB_FORMAT
{
CB_FORMAT_RAW = 0,
CB_FORMAT_TEXT = 1,
@ -49,29 +49,29 @@ enum FRDP_CB_FORMAT
/**
* Clipboard Events
*/
typedef FRDP_EVENT FRDP_CB_SYNC_EVENT;
typedef RDP_EVENT RDP_CB_SYNC_EVENT;
struct _FRDP_CB_FORMAT_LIST_EVENT
struct _RDP_CB_FORMAT_LIST_EVENT
{
FRDP_EVENT event;
RDP_EVENT event;
uint32* formats;
uint16 num_formats;
};
typedef struct _FRDP_CB_FORMAT_LIST_EVENT FRDP_CB_FORMAT_LIST_EVENT;
typedef struct _RDP_CB_FORMAT_LIST_EVENT RDP_CB_FORMAT_LIST_EVENT;
struct _FRDP_CB_DATA_REQUEST_EVENT
struct _RDP_CB_DATA_REQUEST_EVENT
{
FRDP_EVENT event;
RDP_EVENT event;
uint32 format;
};
typedef struct _FRDP_CB_DATA_REQUEST_EVENT FRDP_CB_DATA_REQUEST_EVENT;
typedef struct _RDP_CB_DATA_REQUEST_EVENT RDP_CB_DATA_REQUEST_EVENT;
struct _FRDP_CB_DATA_RESPONSE_EVENT
struct _RDP_CB_DATA_RESPONSE_EVENT
{
FRDP_EVENT event;
RDP_EVENT event;
uint8* data;
uint32 size;
};
typedef struct _FRDP_CB_DATA_RESPONSE_EVENT FRDP_CB_DATA_RESPONSE_EVENT;
typedef struct _RDP_CB_DATA_RESPONSE_EVENT RDP_CB_DATA_RESPONSE_EVENT;
#endif /* __CLIPRDR_PLUGIN */

View File

@ -23,15 +23,15 @@
/**
* Event Types
*/
enum FRDP_EVENT_TYPE_TSMF
enum RDP_EVENT_TYPE_TSMF
{
FRDP_EVENT_TYPE_TSMF_VIDEO_FRAME = 1,
FRDP_EVENT_TYPE_TSMF_REDRAW
RDP_EVENT_TYPE_TSMF_VIDEO_FRAME = 1,
RDP_EVENT_TYPE_TSMF_REDRAW
};
struct _FRDP_VIDEO_FRAME_EVENT
struct _RDP_VIDEO_FRAME_EVENT
{
FRDP_EVENT event;
RDP_EVENT event;
uint8* frame_data;
uint32 frame_size;
uint32 frame_pixfmt;
@ -42,18 +42,18 @@ struct _FRDP_VIDEO_FRAME_EVENT
sint16 width;
sint16 height;
uint16 num_visible_rects;
FRDP_RECT* visible_rects;
RDP_RECT* visible_rects;
};
typedef struct _FRDP_VIDEO_FRAME_EVENT FRDP_VIDEO_FRAME_EVENT;
typedef struct _RDP_VIDEO_FRAME_EVENT RDP_VIDEO_FRAME_EVENT;
struct _FRDP_REDRAW_EVENT
struct _RDP_REDRAW_EVENT
{
FRDP_EVENT event;
RDP_EVENT event;
sint16 x;
sint16 y;
sint16 width;
sint16 height;
};
typedef struct _FRDP_REDRAW_EVENT FRDP_REDRAW_EVENT;
typedef struct _RDP_REDRAW_EVENT RDP_REDRAW_EVENT;
#endif /* __TSMF_PLUGIN */

View File

@ -303,27 +303,27 @@ enum RDP_RAIL_PDU_TYPE
RDP_RAIL_ORDER_GET_APPID_RESP = 0x000F
};
enum FRDP_EVENT_TYPE_RAIL
enum RDP_EVENT_TYPE_RAIL
{
FRDP_EVENT_TYPE_RAIL_UI_2_VCHANNEL = 1,
FRDP_EVENT_TYPE_RAIL_VCHANNEL_2_UI
RDP_EVENT_TYPE_RAIL_CLIENT = 1,
RDP_EVENT_TYPE_RAIL_CHANNEL
};
/* RAIL Common structures */
typedef struct _RAIL_VCHANNEL_EVENT
struct _RAIL_CHANNEL_EVENT
{
uint32 event_id;
uint32 id;
void* param;
}
RAIL_VCHANNEL_EVENT;
};
typedef struct _RAIL_CHANNEL_EVENT RAIL_CHANNEL_EVENT;
typedef struct _RAIL_UI_EVENT
struct _RAIL_CLIENT_EVENT
{
uint32 event_id;
uint32 id;
void* param;
}
RAIL_UI_EVENT;
};
typedef struct _RAIL_CLIENT_EVENT RAIL_CLIENT_EVENT;
#endif /* __RAIL_GLOBAL_H */

View File

@ -83,7 +83,7 @@ typedef uint32 (FREERDP_CC * PVIRTUALCHANNELWRITE)(uint32 openHandle,
void* pData, uint32 dataLength, void* pUserData);
typedef uint32 (FREERDP_CC * PVIRTUALCHANNELEVENTPUSH)(uint32 openHandle,
FRDP_EVENT* event);
RDP_EVENT* event);
struct _CHANNEL_ENTRY_POINTS
{

View File

@ -65,95 +65,56 @@ typedef int boolean;
#include <freerdp/settings.h>
typedef void* FRDP_HBITMAP;
typedef void* FRDP_HGLYPH;
typedef void* FRDP_HPALETTE;
typedef void* FRDP_HCURSOR;
struct _FRDP_POINT
{
sint16 x;
sint16 y;
};
typedef struct _FRDP_POINT FRDP_POINT;
struct _FRDP_PALETTEENTRY
struct _RDP_PALETTEENTRY
{
uint8 red;
uint8 green;
uint8 blue;
};
typedef struct _FRDP_PALETTEENTRY FRDP_PALETTEENTRY;
typedef struct _RDP_PALETTEENTRY RDP_PALETTEENTRY;
struct _FRDP_PALETTE
struct _RDP_PALETTE
{
uint16 count;
FRDP_PALETTEENTRY* entries;
RDP_PALETTEENTRY* entries;
};
typedef struct _FRDP_PALETTE FRDP_PALETTE;
typedef struct _RDP_PALETTE RDP_PALETTE;
struct _FRDP_PEN
{
uint8 style;
uint8 width;
uint32 color;
};
typedef struct _FRDP_PEN FRDP_PEN;
/* this is what is in the brush cache */
struct _FRDP_BRUSHDATA
{
uint32 color_code;
uint32 data_size;
uint8 *data;
};
typedef struct _FRDP_BRUSHDATA FRDP_BRUSHDATA;
struct _FRDP_BRUSH
{
uint8 xorigin;
uint8 yorigin;
uint8 style;
uint8 pattern[8];
FRDP_BRUSHDATA *bd;
};
typedef struct _FRDP_BRUSH FRDP_BRUSH;
struct _FRDP_PLUGIN_DATA
struct _RDP_PLUGIN_DATA
{
uint16 size;
void* data[4];
};
typedef struct _FRDP_PLUGIN_DATA FRDP_PLUGIN_DATA;
typedef struct _RDP_PLUGIN_DATA RDP_PLUGIN_DATA;
struct _FRDP_RECT
struct _RDP_RECT
{
sint16 x;
sint16 y;
sint16 width;
sint16 height;
};
typedef struct _FRDP_RECT FRDP_RECT;
typedef struct _RDP_RECT RDP_RECT;
/* Plugin events */
typedef struct _FRDP_EVENT FRDP_EVENT;
typedef struct _RDP_EVENT RDP_EVENT;
typedef void (*FRDP_EVENT_CALLBACK) (FRDP_EVENT* event);
typedef void (*RDP_EVENT_CALLBACK) (RDP_EVENT* event);
struct _FRDP_EVENT
struct _RDP_EVENT
{
uint16 event_class;
uint16 event_type;
FRDP_EVENT_CALLBACK on_event_free_callback;
RDP_EVENT_CALLBACK on_event_free_callback;
void* user_data;
};
enum FRDP_EVENT_CLASS
enum RDP_EVENT_CLASS
{
FRDP_EVENT_CLASS_DEBUG = 0,
FRDP_EVENT_CLASS_CLIPRDR,
FRDP_EVENT_CLASS_TSMF,
FRDP_EVENT_CLASS_RAIL
RDP_EVENT_CLASS_DEBUG = 0,
RDP_EVENT_CLASS_CLIPRDR,
RDP_EVENT_CLASS_TSMF,
RDP_EVENT_CLASS_RAIL
};
#endif /* __RDP_TYPES_H */

View File

@ -26,7 +26,7 @@
/* Returns 1 if succeed, otherwise returns zero */
typedef int (*ProcessPluginArgs) (rdpSettings* settings, const char* name,
FRDP_PLUGIN_DATA* plugin_data, void* user_data);
RDP_PLUGIN_DATA* plugin_data, void* user_data);
/* Returns number of arguments processed (1 or 2), otherwise returns zero */
typedef int (*ProcessUIArgs) (rdpSettings* settings, const char* opt,

View File

@ -23,8 +23,8 @@
#include <freerdp/api.h>
#include <freerdp/types.h>
FREERDP_API FRDP_EVENT* freerdp_event_new(uint16 event_class, uint16 event_type,
FRDP_EVENT_CALLBACK on_event_free_callback, void* user_data);
FREERDP_API void freerdp_event_free(FRDP_EVENT* event);
FREERDP_API RDP_EVENT* freerdp_event_new(uint16 event_class, uint16 event_type,
RDP_EVENT_CALLBACK on_event_free_callback, void* user_data);
FREERDP_API void freerdp_event_free(RDP_EVENT* event);
#endif

View File

@ -41,7 +41,7 @@ struct rdp_svc_plugin
void (*connect_callback)(rdpSvcPlugin* plugin);
void (*receive_callback)(rdpSvcPlugin* plugin, STREAM* data_in);
void (*event_callback)(rdpSvcPlugin* plugin, FRDP_EVENT* event);
void (*event_callback)(rdpSvcPlugin* plugin, RDP_EVENT* event);
void (*interval_callback)(rdpSvcPlugin* plugin);
void (*terminate_callback)(rdpSvcPlugin* plugin);
@ -50,9 +50,9 @@ struct rdp_svc_plugin
FREERDP_API void svc_plugin_init(rdpSvcPlugin* plugin, CHANNEL_ENTRY_POINTS* pEntryPoints);
FREERDP_API int svc_plugin_send(rdpSvcPlugin* plugin, STREAM* data_out);
FREERDP_API int svc_plugin_send_event(rdpSvcPlugin* plugin, FRDP_EVENT* event);
FREERDP_API int svc_plugin_send_event(rdpSvcPlugin* plugin, RDP_EVENT* event);
#define svc_plugin_get_data(_p) (FRDP_PLUGIN_DATA*)(((rdpSvcPlugin*)_p)->channel_entry_points.pExtendedData)
#define svc_plugin_get_data(_p) (RDP_PLUGIN_DATA*)(((rdpSvcPlugin*)_p)->channel_entry_points.pExtendedData)
#ifdef WITH_DEBUG_SVC
#define DEBUG_SVC(fmt, ...) DEBUG_CLASS(SVC, fmt, ## __VA_ARGS__)

View File

@ -117,7 +117,7 @@ struct rdp_chan_man
/* used for sync event */
freerdp_sem event_sem;
FRDP_EVENT* event;
RDP_EVENT* event;
};
/**
@ -480,7 +480,7 @@ static uint32 FREERDP_CC MyVirtualChannelWrite(uint32 openHandle, void* pData, u
return CHANNEL_RC_OK;
}
static uint32 FREERDP_CC MyVirtualChannelEventPush(uint32 openHandle, FRDP_EVENT* event)
static uint32 FREERDP_CC MyVirtualChannelEventPush(uint32 openHandle, RDP_EVENT* event)
{
rdpChanMan* chan_man;
struct chan_data* lchan;
@ -781,10 +781,10 @@ int freerdp_chanman_data(freerdp* instance, int chan_id, void* data, int data_si
static const char* event_class_to_name_table[] =
{
"rdpdbg", /* FRDP_EVENT_CLASS_DEBUG */
"cliprdr", /* FRDP_EVENT_CLASS_CLIPRDR */
"tsmf", /* FRDP_EVENT_CLASS_TSMF */
"rail", /* FRDP_EVENT_CLASS_RAIL */
"rdpdbg", /* RDP_EVENT_CLASS_DEBUG */
"cliprdr", /* RDP_EVENT_CLASS_CLIPRDR */
"tsmf", /* RDP_EVENT_CLASS_TSMF */
"rail", /* RDP_EVENT_CLASS_RAIL */
NULL
};
@ -794,7 +794,7 @@ static const char* event_class_to_name_table[] =
* @param chan_man the channel manager instance
* @param event an event object created by freerdp_event_new()
*/
FREERDP_API int freerdp_chanman_send_event(rdpChanMan* chan_man, FRDP_EVENT* event)
FREERDP_API int freerdp_chanman_send_event(rdpChanMan* chan_man, RDP_EVENT* event)
{
struct chan_data* lchan_data;
int index;
@ -817,7 +817,7 @@ FREERDP_API int freerdp_chanman_send_event(rdpChanMan* chan_man, FRDP_EVENT* eve
{
lchan_data->open_event_proc(lchan_data->open_handle,
CHANNEL_EVENT_USER,
event, sizeof(FRDP_EVENT), sizeof(FRDP_EVENT), 0);
event, sizeof(RDP_EVENT), sizeof(RDP_EVENT), 0);
}
return 0;
}
@ -877,9 +877,9 @@ boolean freerdp_chanman_check_fds(rdpChanMan * chan_man, freerdp* instance)
return True;
}
FRDP_EVENT* freerdp_chanman_pop_event(rdpChanMan* chan_man)
RDP_EVENT* freerdp_chanman_pop_event(rdpChanMan* chan_man)
{
FRDP_EVENT* event;
RDP_EVENT* event;
if (chan_man->event == NULL)
return NULL;

View File

@ -47,7 +47,7 @@ int freerdp_parse_args(rdpSettings* settings, int argc, char** argv,
int i, j;
int index = 1;
int num_extensions = 0;
FRDP_PLUGIN_DATA* plugin_data;
RDP_PLUGIN_DATA* plugin_data;
while (index < argc)
{
@ -298,8 +298,8 @@ int freerdp_parse_args(rdpSettings* settings, int argc, char** argv,
i = 0;
while (index < argc && strcmp("--", argv[index]) != 0)
{
plugin_data = (FRDP_PLUGIN_DATA*)xrealloc(plugin_data, sizeof(FRDP_PLUGIN_DATA) * (i + 2));
plugin_data[i].size = sizeof(FRDP_PLUGIN_DATA);
plugin_data = (RDP_PLUGIN_DATA*)xrealloc(plugin_data, sizeof(RDP_PLUGIN_DATA) * (i + 2));
plugin_data[i].size = sizeof(RDP_PLUGIN_DATA);
plugin_data[i].data[0] = NULL;
plugin_data[i].data[1] = NULL;
plugin_data[i].data[2] = NULL;

View File

@ -26,68 +26,68 @@
#include <freerdp/plugins/tsmf.h>
#include <freerdp/rail.h>
static FRDP_EVENT* freerdp_cliprdr_event_new(uint16 event_type)
static RDP_EVENT* freerdp_cliprdr_event_new(uint16 event_type)
{
FRDP_EVENT* event = NULL;
RDP_EVENT* event = NULL;
switch (event_type)
{
case FRDP_EVENT_TYPE_CB_SYNC:
event = (FRDP_EVENT*)xnew(FRDP_CB_SYNC_EVENT);
case RDP_EVENT_TYPE_CB_SYNC:
event = (RDP_EVENT*)xnew(RDP_CB_SYNC_EVENT);
break;
case FRDP_EVENT_TYPE_CB_FORMAT_LIST:
event = (FRDP_EVENT*)xnew(FRDP_CB_FORMAT_LIST_EVENT);
case RDP_EVENT_TYPE_CB_FORMAT_LIST:
event = (RDP_EVENT*)xnew(RDP_CB_FORMAT_LIST_EVENT);
break;
case FRDP_EVENT_TYPE_CB_DATA_REQUEST:
event = (FRDP_EVENT*)xnew(FRDP_CB_DATA_REQUEST_EVENT);
case RDP_EVENT_TYPE_CB_DATA_REQUEST:
event = (RDP_EVENT*)xnew(RDP_CB_DATA_REQUEST_EVENT);
break;
case FRDP_EVENT_TYPE_CB_DATA_RESPONSE:
event = (FRDP_EVENT*)xnew(FRDP_CB_DATA_RESPONSE_EVENT);
case RDP_EVENT_TYPE_CB_DATA_RESPONSE:
event = (RDP_EVENT*)xnew(RDP_CB_DATA_RESPONSE_EVENT);
break;
}
return event;
}
static FRDP_EVENT* freerdp_tsmf_event_new(uint16 event_type)
static RDP_EVENT* freerdp_tsmf_event_new(uint16 event_type)
{
FRDP_EVENT* event = NULL;
RDP_EVENT* event = NULL;
switch (event_type)
{
case FRDP_EVENT_TYPE_TSMF_VIDEO_FRAME:
event = (FRDP_EVENT*)xnew(FRDP_VIDEO_FRAME_EVENT);
case RDP_EVENT_TYPE_TSMF_VIDEO_FRAME:
event = (RDP_EVENT*)xnew(RDP_VIDEO_FRAME_EVENT);
break;
case FRDP_EVENT_TYPE_TSMF_REDRAW:
event = (FRDP_EVENT*)xnew(FRDP_REDRAW_EVENT);
case RDP_EVENT_TYPE_TSMF_REDRAW:
event = (RDP_EVENT*)xnew(RDP_REDRAW_EVENT);
break;
}
return event;
}
static FRDP_EVENT* freerdp_rail_event_new(uint16 event_type)
static RDP_EVENT* freerdp_rail_event_new(uint16 event_type)
{
return xnew(FRDP_EVENT);
return xnew(RDP_EVENT);
}
FRDP_EVENT* freerdp_event_new(uint16 event_class, uint16 event_type,
FRDP_EVENT_CALLBACK on_event_free_callback, void* user_data)
RDP_EVENT* freerdp_event_new(uint16 event_class, uint16 event_type,
RDP_EVENT_CALLBACK on_event_free_callback, void* user_data)
{
FRDP_EVENT* event = NULL;
RDP_EVENT* event = NULL;
switch (event_class)
{
case FRDP_EVENT_CLASS_DEBUG:
event = xnew(FRDP_EVENT);
case RDP_EVENT_CLASS_DEBUG:
event = xnew(RDP_EVENT);
break;
case FRDP_EVENT_CLASS_CLIPRDR:
case RDP_EVENT_CLASS_CLIPRDR:
event = freerdp_cliprdr_event_new(event_type);
break;
case FRDP_EVENT_CLASS_TSMF:
case RDP_EVENT_CLASS_TSMF:
event = freerdp_tsmf_event_new(event_type);
break;
case FRDP_EVENT_CLASS_RAIL:
case RDP_EVENT_CLASS_RAIL:
event = freerdp_rail_event_new(event_type);
break;
}
@ -102,32 +102,32 @@ FRDP_EVENT* freerdp_event_new(uint16 event_class, uint16 event_type,
return event;
}
static void freerdp_cliprdr_event_free(FRDP_EVENT* event)
static void freerdp_cliprdr_event_free(RDP_EVENT* event)
{
switch (event->event_type)
{
case FRDP_EVENT_TYPE_CB_FORMAT_LIST:
case RDP_EVENT_TYPE_CB_FORMAT_LIST:
{
FRDP_CB_FORMAT_LIST_EVENT* cb_event = (FRDP_CB_FORMAT_LIST_EVENT*)event;
RDP_CB_FORMAT_LIST_EVENT* cb_event = (RDP_CB_FORMAT_LIST_EVENT*)event;
xfree(cb_event->formats);
}
break;
case FRDP_EVENT_TYPE_CB_DATA_RESPONSE:
case RDP_EVENT_TYPE_CB_DATA_RESPONSE:
{
FRDP_CB_DATA_RESPONSE_EVENT* cb_event = (FRDP_CB_DATA_RESPONSE_EVENT*)event;
RDP_CB_DATA_RESPONSE_EVENT* cb_event = (RDP_CB_DATA_RESPONSE_EVENT*)event;
xfree(cb_event->data);
}
break;
}
}
static void freerdp_tsmf_event_free(FRDP_EVENT* event)
static void freerdp_tsmf_event_free(RDP_EVENT* event)
{
switch (event->event_type)
{
case FRDP_EVENT_TYPE_TSMF_VIDEO_FRAME:
case RDP_EVENT_TYPE_TSMF_VIDEO_FRAME:
{
FRDP_VIDEO_FRAME_EVENT* vevent = (FRDP_VIDEO_FRAME_EVENT*)event;
RDP_VIDEO_FRAME_EVENT* vevent = (RDP_VIDEO_FRAME_EVENT*)event;
xfree(vevent->frame_data);
xfree(vevent->visible_rects);
}
@ -135,11 +135,11 @@ static void freerdp_tsmf_event_free(FRDP_EVENT* event)
}
}
static void freerdp_rail_event_free(FRDP_EVENT* event)
static void freerdp_rail_event_free(RDP_EVENT* event)
{
}
void freerdp_event_free(FRDP_EVENT* event)
void freerdp_event_free(RDP_EVENT* event)
{
if (event != NULL)
{
@ -148,13 +148,13 @@ void freerdp_event_free(FRDP_EVENT* event)
switch (event->event_class)
{
case FRDP_EVENT_CLASS_CLIPRDR:
case RDP_EVENT_CLASS_CLIPRDR:
freerdp_cliprdr_event_free(event);
break;
case FRDP_EVENT_CLASS_TSMF:
case RDP_EVENT_CLASS_TSMF:
freerdp_tsmf_event_free(event);
break;
case FRDP_EVENT_CLASS_RAIL:
case RDP_EVENT_CLASS_RAIL:
freerdp_rail_event_free(event);
break;
}

View File

@ -49,7 +49,7 @@ static freerdp_mutex g_mutex = NULL;
struct _svc_data_in_item
{
STREAM* data_in;
FRDP_EVENT* event_in;
RDP_EVENT* event_in;
};
typedef struct _svc_data_in_item svc_data_in_item;
@ -177,7 +177,7 @@ static void svc_plugin_process_received(rdpSvcPlugin* plugin, void* pData, uint3
}
}
static void svc_plugin_process_event(rdpSvcPlugin* plugin, FRDP_EVENT* event_in)
static void svc_plugin_process_event(rdpSvcPlugin* plugin, RDP_EVENT* event_in)
{
svc_data_in_item* item;
@ -214,7 +214,7 @@ static void svc_plugin_open_event(uint32 openHandle, uint32 event, void* pData,
stream_free((STREAM*)pData);
break;
case CHANNEL_EVENT_USER:
svc_plugin_process_event(plugin, (FRDP_EVENT*)pData);
svc_plugin_process_event(plugin, (RDP_EVENT*)pData);
break;
}
}
@ -394,7 +394,7 @@ int svc_plugin_send(rdpSvcPlugin* plugin, STREAM* data_out)
return error;
}
int svc_plugin_send_event(rdpSvcPlugin* plugin, FRDP_EVENT* event)
int svc_plugin_send_event(rdpSvcPlugin* plugin, RDP_EVENT* event)
{
uint32 error = 0;