Usermode/AxWin3 - Adding widget mouse input handlers
[tpg/acess2.git] / Usermode / Applications / axwin3_src / include / widget_messages.h
1 /*
2  * Acess2 Window Manager v3
3  * - By John Hodge (thePowersGang)
4  *
5  * widget_messages.h
6  * - AxWin2 Widget port
7  */
8 #ifndef _WIDGET_MESSAGES_H_
9 #define _WIDGET_MESSAGES_H_
10
11 enum
12 {
13         // Control (Client->Server) messages
14         MSG_WIDGET_CREATE = 0x1000,
15         MSG_WIDGET_DELETE,
16         MSG_WIDGET_SETFLAGS,
17         MSG_WIDGET_SETSIZE,
18         MSG_WIDGET_SETTEXT,
19         MSG_WIDGET_SETCOLOUR,
20         
21         // Event (Server->Client) messages
22         MSG_WIDGET_FIRE,
23         MSG_WIDGET_KEYPRESS,
24         MSG_WIDGET_MOUSEBTN,
25 };
26
27
28 typedef struct
29 {
30         uint32_t        Parent;
31         uint32_t        NewID;
32         uint32_t        Type;
33         uint32_t        Flags;
34         char    DebugName[];
35 } tWidgetMsg_Create;
36
37 typedef struct
38 {
39         uint32_t        WidgetID;
40 } tWidgetMsg_Delete;
41
42 typedef struct
43 {
44         uint32_t        WidgetID;
45         uint32_t        Value;
46         uint32_t        Mask;
47 } tWidgetMsg_SetFlags;
48
49 typedef struct
50 {
51         uint32_t        WidgetID;
52         uint32_t        Value;
53 } tWidgetMsg_SetSize;
54
55 typedef struct
56 {
57         uint32_t        WidgetID;
58         char    Text[];
59 } tWidgetMsg_SetText;
60
61 typedef struct
62 {
63         uint32_t        WidgetID;
64         uint32_t        Index;
65         uint32_t        Colour;
66 } tWidgetMsg_SetColour;
67
68 typedef struct
69 {
70         uint32_t        WidgetID;
71 } tWidgetMsg_Fire;
72
73 typedef struct
74 {
75         uint32_t        WidgetID;
76         uint32_t        KeySym;
77         uint32_t        Character;
78 } tWidgetMsg_KeyEvent;
79
80 typedef struct
81 {
82         uint32_t        WidgetID;
83         uint16_t        X;
84         uint16_t        Y;
85         uint8_t         Button;
86         uint8_t         bPressed;
87 } tWidgetMsg_MouseBtn;
88
89 #endif
90

UCC git Repository :: git.ucc.asn.au