FreeRDP
shadow_remdesk.c
1 
21 #include <freerdp/config.h>
22 
23 #include "shadow.h"
24 
25 #include "shadow_remdesk.h"
26 
27 int shadow_client_remdesk_init(rdpShadowClient* client)
28 {
29  RemdeskServerContext* remdesk = NULL;
30 
31  remdesk = client->remdesk = remdesk_server_context_new(client->vcm);
32  remdesk->rdpcontext = &client->context;
33 
34  remdesk->custom = (void*)client;
35 
36  if (client->remdesk)
37  client->remdesk->Start(client->remdesk);
38 
39  return 1;
40 }
41 
42 void shadow_client_remdesk_uninit(rdpShadowClient* client)
43 {
44  if (client->remdesk)
45  {
46  client->remdesk->Stop(client->remdesk);
47  remdesk_server_context_free(client->remdesk);
48  client->remdesk = NULL;
49  }
50 }