2 * Message queues definitions
4 * Copyright 1993 Alexandre Julliard
16 /* Message as stored in the queue (contains the extraInfo field) */
17 typedef struct tagQMSG
19 DWORD extraInfo
; /* Only in 3.1 */
24 typedef struct tagMESSAGEQUEUE
26 HANDLE next
; /* 00 Next queue */
27 HTASK hTask
; /* 02 hTask owning the queue */
28 WORD msgSize
; /* 04 Size of messages in the queue */
29 WORD msgCount
; /* 06 Number of waiting messages */
30 WORD nextMessage
; /* 08 Next message to be retrieved */
31 WORD nextFreeMessage
; /* 0a Next available slot in the queue */
32 WORD queueSize
; /* 0c Size of the queue */
33 DWORD GetMessageTimeVal WINE_PACKED
; /* 0e Value for GetMessageTime */
34 DWORD GetMessagePosVal WINE_PACKED
; /* 12 Value for GetMessagePos */
35 WORD reserved1
; /* 16 Unknown */
36 DWORD GetMessageExtraInfoVal
; /* 18 Value for GetMessageExtraInfo */
37 WORD reserved2
; /* 1c Unknown */
38 LPARAM lParam WINE_PACKED
; /* 1e Next 4 values set by SendMessage */
39 WPARAM wParam
; /* 22 */
42 DWORD SendMessageReturn
; /* 28 Return value for SendMessage */
43 WORD wPostQMsg
; /* 2c PostQuitMessage flag */
44 WORD wExitCode
; /* 2e PostQuitMessage exit code */
45 WORD reserved3
[3]; /* 30 Unknown */
46 WORD wWinVersion
; /* 36 Expected Windows version */
47 HQUEUE InSendMessageHandle
; /* 38 Queue of task that sent a message */
48 HTASK hSendingTask
; /* 3a Handle of task that sent a message */
49 HTASK hPrevSendingTask
; /* 3c Handle of previous sender */
50 WORD wPaintCount
; /* 3e Number of WM_PAINT needed */
51 WORD wTimerCount
; /* 40 Number of timers for this task */
52 WORD tempStatus
; /* 42 State reset by GetQueueStatus */
53 WORD status
; /* 44 Queue state */
54 WORD wakeMask
; /* 46 Task wake-up mask */
55 WORD SendMsgReturnPtrs
[3]; /* 48 Near ptr to return values (?) */
56 HANDLE hCurHook
; /* 4e Current hook */
57 HANDLE hooks
[WH_NB_HOOKS
]; /* 50 Task hooks list */
58 WORD reserved4
[3]; /* 68 Unknown */
59 QMSG messages
[1]; /* 6e Queue messages */
66 extern DWORD MSG_WineStartTicks
; /* Ticks at Wine startup */
68 extern void MSG_IncPaintCount( HANDLE hQueue
);
69 extern void MSG_DecPaintCount( HANDLE hQueue
);
70 extern void MSG_IncTimerCount( HANDLE hQueue
);
71 extern void MSG_DecTimerCount( HANDLE hQueue
);
72 extern void MSG_Synchronize();
73 extern BOOL
MSG_WaitXEvent( LONG maxWait
);
74 extern BOOL
MSG_CreateSysMsgQueue( int size
);
75 extern BOOL
MSG_DeleteMsgQueue( HANDLE hQueue
);
76 extern HTASK
MSG_GetQueueTask( HANDLE hQueue
);
77 extern void hardware_event( WORD message
, WORD wParam
, LONG lParam
,
78 int xPos
, int yPos
, DWORD time
, DWORD extraInfo
);
79 extern BOOL
MSG_GetHardwareMessage( LPMSG msg
);
80 extern BOOL
MSG_InternalGetMessage( SEGPTR msg
, HWND hwnd
, HWND hwndOwner
,
81 short code
, WORD flags
, BOOL sendIdle
);
83 #endif /* MESSAGE_H */