Dear All,
I would like to understand how each Windows Messages like WM_COMMAND are processed and handled by wine ? If i call a function SendMessage and pass one window handle to it with the appropriate message (i.e WM_GETTEXT ) how it will be processed ? Is it going through the wine-server ?
I'm basically interested in learning about window messages processing and how each window/dialog/controls creation/updation/manipulation are handled in wine ? Is this such that all window messages are going through wine-server ?
If i wanted to trace/hook the window message, is there any --debugmsg params available ?
Is there any documentation (developer) available for wine-server ?. I would like to understand the architecture/functionality of the wine-server. It would be better if there is a document which explains the incoming/outgoing packets (Requests/Responses) between client and then wine-server ? when i looked at the wine-devel documentation on wine-server, it says that 'wineserver is the confusing concept in wine ' ? Is it so ...?
If i didn't framed my questions properly, please forgive me as i'm very novice is wine and hopefully show some progress when i feel comfortable with my wine study...!
Thanks and Best Regards, S. Sukumar
-----Original Message----- From: wine-devel-admin@winehq.org [mailto:wine-devel-admin@winehq.org]On Behalf Of Sukumar .S Sent: 08 September 2003 08:19 To: wine-devel@winehq.org Subject: Wine and Windows Hooks
I would like to understand how each Windows Messages like WM_COMMAND are processed and handled by wine ? If i call a function SendMessage and pass one window handle to it with the appropriate message (i.e WM_GETTEXT ) how it will be processed ? Is it going through the wine-server ?
Yes. It is put into a queue and then retrieved by the GetMessage (or similar) function.
I'm basically interested in learning about window messages processing and how each window/dialog/controls creation/updation/manipulation are handled in wine ? Is this such that all window messages are going through wine-server ?
Yes. All of our common controls use the standard Win32 API.
If i wanted to trace/hook the window message, is there any --debugmsg params available ?
I believe "--debugmsg +message" would do what you want.
Is there any documentation (developer) available for wine-server ?.
Unfortunately not. I've wanted to write some for a time, but I haven't had the time.
I would like to understand the architecture/functionality of the wine-server. It would be better if there is a document which explains the incoming/outgoing packets (Requests/Responses) between client and then wine-server ? when i looked at the wine-devel documentation on wine-server, it says that 'wineserver is the confusing concept in wine ' ? Is it so ...?
Not really. It uses a client-server model over Unix sockets. The server process is a one thread loop which serves requests one-by-one and performs necessary checks for expiring timers. The server usually doesn't send its reply until it has finished whatever processing it needs to do (e.g. waking threads). The protocol is defined in wine/include/wine/server_protocol.h, which is auto-generated from wine/server/protocol.def.
If i didn't framed my questions properly, please forgive me as i'm very novice is wine and hopefully show some progress when i feel comfortable with my wine study...!
Your questions were fine. Let me know if you want any more detail on anything. Looking forward to your first patch!
Rob
On Mon, 08 Sep 2003 12:49:14 +0530, Sir Sukumar .S scribed thus:
I would like to understand how each Windows Messages like WM_COMMAND are processed and handled by wine ? If i call a function SendMessage and pass one window handle to it with the appropriate message (i.e WM_GETTEXT ) how it will be processed ? Is it going through the wine-server ?
The Wine architecture is loosely modelled after the architecture of Windows itself. In Windows, messages are usually switched via the kernel, so yes, a wineserver call will be involved in that as the wineserver typically represents the Windows kernel.
You can see the message queue/switch code in server/queue.c
Useful debug channels here are +message and +msg, which give different views onto message flow. Be careful, in complex GUI apps they can generate large amounts of data.
thanks -mike