API Documentation for SendMessage, GetTickCount, PostQuitMessage,
GetMessagePos, GetMessageTime.
diff --git a/windows/message.c b/windows/message.c
index cd79d25..06c7819 100644
--- a/windows/message.c
+++ b/windows/message.c
@@ -1258,6 +1258,11 @@
/**********************************************************************
* PostThreadMessage32A (USER32.422)
+ *
+ * BUGS
+ *
+ * Thread-local message queues are not supported.
+ *
*/
BOOL32 WINAPI PostThreadMessage32A(DWORD idThread , UINT32 message,
WPARAM32 wParam, LPARAM lParam )
@@ -1321,11 +1326,32 @@
/***********************************************************************
- * SendMessage32W (USER32.459)
+ * SendMessage32W (USER32.459) Send Window Message
+ *
+ * Sends a message to the window procedure of the specified window.
+ * SendMessage() will not return until the called window procedure
+ * either returns or calls ReplyMessage().
+ *
+ * Use PostMessage() to send message and return immediately. A window
+ * procedure may use InSendMessage() to detect
+ * SendMessage()-originated messages.
+ *
+ * Applications which communicate via HWND_BROADCAST may use
+ * RegisterWindowMessage() to obtain a unique message to avoid conflicts
+ * with other applications.
+ *
+ * CONFORMANCE
+ *
+ * ECMA-234, Win32
*/
-LRESULT WINAPI SendMessage32W( HWND32 hwnd, UINT32 msg, WPARAM32 wParam,
- LPARAM lParam )
-{
+LRESULT WINAPI SendMessage32W(
+ HWND32 hwnd, /* Window to send message to. If HWND_BROADCAST,
+ the message will be sent to all top-level windows. */
+
+ UINT32 msg, /* message */
+ WPARAM32 wParam, /* message parameter */
+ LPARAM lParam /* additional message parameter */
+) {
WND * wndPtr;
WND **list, **ppWnd;
LRESULT ret;
@@ -1416,6 +1442,8 @@
*
* Is supposed to return BOOL under Win32.
*
+ * Thread-local message queues are not supported.
+ *
* CONFORMANCE
*
* ECMA-234, Win32
@@ -1755,7 +1783,7 @@
/***********************************************************************
- * DispatchMessage32W (USER32.142)
+ * DispatchMessage32W (USER32.142) Process Message
*
* Process the message specified in the structure *_msg_.
*
@@ -1850,7 +1878,13 @@
/***********************************************************************
- * GetTickCount (USER.13) (KERNEL32.299)
+ * GetTickCount (USER.13) (KERNEL32.299) System Time
+ * Returns the number of milliseconds, modulo 2^32, since the start
+ * of the current session.
+ *
+ * CONFORMANCE
+ *
+ * ECMA-234, Win32
*/
DWORD WINAPI GetTickCount(void)
{
diff --git a/windows/queue.c b/windows/queue.c
index de5c946..c8a83db 100644
--- a/windows/queue.c
+++ b/windows/queue.c
@@ -738,6 +738,17 @@
/***********************************************************************
* PostQuitMessage32 (USER32.421)
+ *
+ * PostQuitMessage() posts a message to the system requesting an
+ * application to terminate execution. As a result of this function,
+ * the WM_QUIT message is posted to the application, and
+ * PostQuitMessage() returns immediately. The exitCode parameter
+ * specifies an application-defined exit code, which appears in the
+ * _wParam_ parameter of the WM_QUIT message posted to the application.
+ *
+ * CONFORMANCE
+ *
+ * ECMA-234, Win32
*/
void WINAPI PostQuitMessage32( INT32 exitCode )
{
@@ -899,6 +910,24 @@
/***********************************************************************
* GetMessagePos (USER.119) (USER32.272)
+ *
+ * The GetMessagePos() function returns a long value representing a
+ * cursor position, in screen coordinates, when the last message
+ * retrieved by the GetMessage() function occurs. The x-coordinate is
+ * in the low-order word of the return value, the y-coordinate is in
+ * the high-order word. The application can use the MAKEPOINT()
+ * macro to obtain a POINT structure from the return value.
+ *
+ * For the current cursor position, use GetCursorPos().
+ *
+ * RETURNS
+ *
+ * Cursor position of last message on success, zero on failure.
+ *
+ * CONFORMANCE
+ *
+ * ECMA-234, Win32
+ *
*/
DWORD WINAPI GetMessagePos(void)
{
@@ -911,6 +940,22 @@
/***********************************************************************
* GetMessageTime (USER.120) (USER32.273)
+ *
+ * GetMessageTime() returns the message time for the last message
+ * retrieved by the function. The time is measured in milliseconds with
+ * the same offset as GetTickCount().
+ *
+ * Since the tick count wraps, this is only useful for moderately short
+ * relative time comparisons.
+ *
+ * RETURNS
+ *
+ * Time of last message on success, zero on failure.
+ *
+ * CONFORMANCE
+ *
+ * ECMA-234, Win32
+ *
*/
LONG WINAPI GetMessageTime(void)
{