Test initialisation of MUIA_List_AdjustWidth and MUIA_List_AdjustHeight, and
[AROS.git] / arch / all-mingw32 / hidd / wingdi / gdi.h
blob321b27c99a99a708eb92598c176f09de51425f27
1 #ifndef HIDD_GDI_H
2 #define HIDD_GDI_H
4 /*
5 Copyright © 1995-2015, The AROS Development Team. All rights reserved.
6 $Id$
8 Desc: Include for the gdi HIDD.
9 Lang: English.
12 #ifndef WM_USER
13 #define WM_USER 1024
14 #endif
17 * GDI virtual hardware registers.
18 * !!! WARNING !!! This structure is shared between Windows-side .dll and AROS code.
19 * 64-bit versions of Windows and AROS have different alignment (Windows has 4 for backwards compatibility),
20 * and this must be taken into account. Take care when adding/removing members!
22 struct GDI_Control
24 /* Display */
25 void *Active; /* Set to struct gfx_data * when new display window is activated */
26 unsigned char GfxIrq; /* IRQ number */
27 unsigned char ShowDone; /* NOTY_SHOW completion flag */
29 /* Mouse */
30 unsigned short MouseEvent;
31 unsigned short MouseX;
32 unsigned short MouseY;
33 unsigned short Buttons;
34 unsigned short WheelDelta;
35 unsigned char MouseIrq;
37 /* Keyboard */
38 unsigned char KbdIrq;
39 unsigned short KbdEvent;
40 unsigned short KeyCode;
43 #ifdef __AROS__
45 #include <exec/libraries.h>
46 #include <oop/oop.h>
47 #include <exec/semaphores.h>
49 #include "winapi.h"
50 #include "gdi_class.h"
51 #include "gdi_hostlib.h"
53 /***** GDIMouse HIDD *******************/
55 /* Private data */
56 struct pHidd_Mouse_Event;
57 struct gdimouse_data
59 VOID (*mouse_callback)(APTR, struct pHidd_Mouse_Event *);
60 APTR callbackdata;
61 void *interrupt;
62 UWORD buttons;
65 /* IDs */
66 #define IID_Hidd_GDIMouse "hidd.mouse.gdi"
67 #define CLID_Hidd_GDIMouse "hidd.mouse.gdi"
69 /***** GDIKbd HIDD *******************/
71 /* Private data */
72 struct gdikbd_data
74 VOID (*kbd_callback)(APTR, UWORD);
75 APTR callbackdata;
76 void *interrupt;
79 /* IDs */
80 #define IID_Hidd_GDIKbd "hidd.kbd.gdi"
81 #define CLID_Hidd_GDIKbd "hidd.kbd.gdi"
84 /***** GDIGfx HIDD *******************/
86 struct gdi_staticdata
89 * These two members should be in the beginning because it's exposed
90 * outside (see gdi_class.h)
92 ULONG displaynum;
93 OOP_Class *basebm; /* baseclass for CreateObject */
95 OOP_Class *gfxclass;
97 OOP_Class *bmclass;
98 OOP_Class *mouseclass;
99 OOP_Class *kbdclass;
101 struct SignalSemaphore sema;
102 struct Task *showtask;
103 void *gfx_int;
105 OOP_Object *mousehidd;
106 OOP_Object *kbdhidd;
108 struct GDI_Control *ctl;
111 struct gdiclbase
113 struct Library library;
115 struct gdi_staticdata xsd;
118 #undef XSD
119 #define XSD(cl) (&((struct gdiclbase *)cl->UserData)->xsd)
121 extern OOP_AttrBase HiddAttrBase;
123 #else
125 #include <windows.h>
127 #define APTR void *
129 #ifdef __x86_64__
130 #define __aros __attribute__((sysv_abi))
131 #else
132 #define __aros
133 #endif
135 struct MinNode
137 struct MinNode * mln_Succ,
138 * mln_Pred;
141 struct MinList
143 struct MinNode * mlh_Head,
144 * mlh_Tail,
145 * mlh_TailPred;
148 #endif
150 #define NOTY_SHOW WM_USER
152 /* Private instance data for Gfx hidd class */
153 struct gfx_data
155 struct MinList bitmaps; /* Currently shown bitmap objects */
156 void *display; /* Windows system display object */
157 void *cursor; /* Windows mouse cursor object */
158 void (*cb)(void *data, void *bm); /* Display activation callback function */
159 void *cbdata; /* User data for activation callback */
160 void *fbwin; /* Display window */
163 #endif /* HIDD_GDI_H */