2 * FreeRDP: A Remote Desktop Protocol Client
3 * Pointer Updates Interface API
5 * Copyright 2011 Marc-Andre Moreau <marcandre.moreau@gmail.com>
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
20 #ifndef __UPDATE_POINTER_H
21 #define __UPDATE_POINTER_H
23 #include <freerdp/types.h>
25 #define PTR_MSG_TYPE_SYSTEM 0x0001
26 #define PTR_MSG_TYPE_POSITION 0x0003
27 #define PTR_MSG_TYPE_COLOR 0x0006
28 #define PTR_MSG_TYPE_CACHED 0x0007
29 #define PTR_MSG_TYPE_POINTER 0x0008
31 #define SYSPTR_NULL 0x00000000
32 #define SYSPTR_DEFAULT 0x00007F00
34 struct _POINTER_POSITION_UPDATE
39 typedef struct _POINTER_POSITION_UPDATE POINTER_POSITION_UPDATE;
41 struct _POINTER_SYSTEM_UPDATE
45 typedef struct _POINTER_SYSTEM_UPDATE POINTER_SYSTEM_UPDATE;
47 struct _POINTER_COLOR_UPDATE
59 typedef struct _POINTER_COLOR_UPDATE POINTER_COLOR_UPDATE;
61 struct _POINTER_NEW_UPDATE
64 POINTER_COLOR_UPDATE colorPtrAttr;
66 typedef struct _POINTER_NEW_UPDATE POINTER_NEW_UPDATE;
68 struct _POINTER_CACHED_UPDATE
72 typedef struct _POINTER_CACHED_UPDATE POINTER_CACHED_UPDATE;
74 typedef void (*pPointerPosition)(rdpContext* context, POINTER_POSITION_UPDATE* pointer_position);
75 typedef void (*pPointerSystem)(rdpContext* context, POINTER_SYSTEM_UPDATE* pointer_system);
76 typedef void (*pPointerColor)(rdpContext* context, POINTER_COLOR_UPDATE* pointer_color);
77 typedef void (*pPointerNew)(rdpContext* context, POINTER_NEW_UPDATE* pointer_new);
78 typedef void (*pPointerCached)(rdpContext* context, POINTER_CACHED_UPDATE* pointer_cached);
80 struct rdp_pointer_update
82 rdpContext* context; /* 0 */
83 uint32 paddingA[16 - 1]; /* 1 */
85 pPointerPosition PointerPosition; /* 16 */
86 pPointerSystem PointerSystem; /* 17 */
87 pPointerColor PointerColor; /* 18 */
88 pPointerNew PointerNew; /* 19 */
89 pPointerCached PointerCached; /* 20 */
90 uint32 paddingB[32 - 21]; /* 21 */
94 POINTER_POSITION_UPDATE pointer_position;
95 POINTER_SYSTEM_UPDATE pointer_system;
96 POINTER_COLOR_UPDATE pointer_color;
97 POINTER_NEW_UPDATE pointer_new;
98 POINTER_CACHED_UPDATE pointer_cached;
100 typedef struct rdp_pointer_update rdpPointerUpdate;
102 #endif /* __UPDATE_POINTER_H */