Difference between revisions of "Message System Rework"
(Import from old Wiki) |
(Mark outdated) |
||
Line 1: | Line 1: | ||
+ | {{Outdated}} | ||
+ | |||
We are currently reworking the windows message portion of ROS. | We are currently reworking the windows message portion of ROS. | ||
− | This heavily affects win32k/ntuser/message.c and win32k/ntuser/msgqueue.c | + | This heavily affects <tt>win32k/ntuser/message.c</tt> and <tt>win32k/ntuser/msgqueue.c</tt> |
− | |||
− | |||
− | + | == Introduction == | |
Windows Messages are the primary means of communication for user process and windows. | Windows Messages are the primary means of communication for user process and windows. | ||
Line 11: | Line 11: | ||
(I'm sure more should be said here) | (I'm sure more should be said here) | ||
− | + | == The System Event Queue == | |
The system event queue is managed by a thread running in kernel space. That thread is | The system event queue is managed by a thread running in kernel space. That thread is | ||
Line 19: | Line 19: | ||
http://www.fofx.org/ReactOs/Message_Diagram1.png | http://www.fofx.org/ReactOs/Message_Diagram1.png | ||
− | + | == Current (Re)Design Issues == | |
− | + | Q: Is the focus message queue stored in window station structures or is it local per message queue? | |
− | + | A: The GUITHREADINFO structure defined in the MS platform SDK gives us the answer: | |
typedef struct tagGUITHREADINFO | typedef struct tagGUITHREADINFO |
Revision as of 23:12, 9 January 2010
This page is probably outdated The information on this page might not be valid for the current state of ReactOS. |
We are currently reworking the windows message portion of ROS.
This heavily affects win32k/ntuser/message.c and win32k/ntuser/msgqueue.c
Introduction
Windows Messages are the primary means of communication for user process and windows.
(I'm sure more should be said here)
The System Event Queue
The system event queue is managed by a thread running in kernel space. That thread is responsible for dispatching events from the system event queue to message queues for user processes and windows.
http://www.fofx.org/ReactOs/Message_Diagram1.png
Current (Re)Design Issues
Q: Is the focus message queue stored in window station structures or is it local per message queue?
A: The GUITHREADINFO structure defined in the MS platform SDK gives us the answer:
typedef struct tagGUITHREADINFO { DWORD cbSize; DWORD flags; HWND hwndActive; HWND hwndFocus; HWND hwndCapture; HWND hwndMenuOwner; HWND hwndMoveSize; HWND hwndCaret; RECT rcCaret; } GUITHREADINFO, *PGUITHREADINFO;
So the message queue contains these values.
The Winstation must only keep a reference to the active message queue.
note from Filip: The special windows are stored inside message queue and the actual active queue (used for redirecting the keybord messages to the right queues) is set using SetForegroundWindow. This implementation is very similar to the Wine's one, so I think it's at least one possibility.