1996-03-14 19:08:34 +01:00
|
|
|
/*
|
|
|
|
* Message queues definitions
|
|
|
|
*
|
|
|
|
* Copyright 1993 Alexandre Julliard
|
2002-03-10 00:29:33 +01:00
|
|
|
*
|
|
|
|
* This library is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
|
|
* License as published by the Free Software Foundation; either
|
|
|
|
* version 2.1 of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This library is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
* Lesser General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
|
|
* License along with this library; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
1996-03-14 19:08:34 +01:00
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __WINE_QUEUE_H
|
|
|
|
#define __WINE_QUEUE_H
|
|
|
|
|
1999-03-14 17:35:05 +01:00
|
|
|
#include "windef.h"
|
2000-03-08 19:26:56 +01:00
|
|
|
#include "winbase.h"
|
2000-02-10 20:03:02 +01:00
|
|
|
#include "wingdi.h"
|
1999-02-21 19:23:26 +01:00
|
|
|
#include "winuser.h"
|
1999-01-26 10:30:05 +01:00
|
|
|
#include "thread.h"
|
|
|
|
|
2001-10-17 19:50:02 +02:00
|
|
|
#define WH_NB_HOOKS (WH_MAXHOOK-WH_MINHOOK+1)
|
1996-03-14 19:08:34 +01:00
|
|
|
|
2001-08-07 21:19:08 +02:00
|
|
|
struct received_message_info;
|
|
|
|
|
1999-02-05 11:37:53 +01:00
|
|
|
/* Message queue */
|
1996-03-14 19:08:34 +01:00
|
|
|
typedef struct tagMESSAGEQUEUE
|
|
|
|
{
|
1999-01-26 10:30:05 +01:00
|
|
|
HQUEUE16 self; /* Handle to self (was: reserved) */
|
1999-06-22 13:43:42 +02:00
|
|
|
TEB* teb; /* Thread owning queue */
|
2000-05-30 21:48:18 +02:00
|
|
|
HANDLE server_queue; /* Handle to server-side queue */
|
2002-10-09 22:36:15 +02:00
|
|
|
DWORD recursion_count; /* Counter to prevent infinite SendMessage recursion */
|
2001-08-07 21:19:08 +02:00
|
|
|
struct received_message_info *receive_info; /* Info about message being currently received */
|
1999-01-26 10:30:05 +01:00
|
|
|
|
1999-01-28 11:54:11 +01:00
|
|
|
DWORD magic; /* magic number should be QUEUE_MAGIC */
|
|
|
|
DWORD lockCount; /* reference counter */
|
1999-01-26 10:30:05 +01:00
|
|
|
|
|
|
|
DWORD GetMessageTimeVal; /* Value for GetMessageTime */
|
|
|
|
DWORD GetMessagePosVal; /* Value for GetMessagePos */
|
|
|
|
DWORD GetMessageExtraInfoVal; /* Value for GetMessageExtraInfo */
|
2001-05-19 00:51:56 +02:00
|
|
|
|
2002-06-14 02:07:05 +02:00
|
|
|
HCURSOR cursor; /* current cursor */
|
|
|
|
INT cursor_count; /* cursor show count */
|
|
|
|
|
1999-01-26 10:30:05 +01:00
|
|
|
HANDLE16 hCurHook; /* Current hook */
|
|
|
|
HANDLE16 hooks[WH_NB_HOOKS]; /* Task hooks list */
|
1996-03-14 19:08:34 +01:00
|
|
|
} MESSAGEQUEUE;
|
|
|
|
|
|
|
|
|
2002-10-09 22:36:15 +02:00
|
|
|
#define QUEUE_MAGIC 0xD46E80AF
|
|
|
|
#define MAX_SENDMSG_RECURSION 64
|
1999-01-28 11:54:11 +01:00
|
|
|
|
1999-02-05 11:37:53 +01:00
|
|
|
/* Message queue management methods */
|
2001-07-26 22:12:22 +02:00
|
|
|
extern MESSAGEQUEUE *QUEUE_Current(void);
|
1999-01-28 11:54:11 +01:00
|
|
|
extern MESSAGEQUEUE *QUEUE_Lock( HQUEUE16 hQueue );
|
|
|
|
extern void QUEUE_Unlock( MESSAGEQUEUE *queue );
|
2001-07-26 22:12:22 +02:00
|
|
|
extern void QUEUE_DeleteMsgQueue(void);
|
1996-03-14 19:08:34 +01:00
|
|
|
|
|
|
|
#endif /* __WINE_QUEUE_H */
|