43#define WM_SENDTOOTHERTHREAD (WM_USER + 14)
45#define KILL_THREAD1_FLAG 0x40000000
46#define KILL_THREAD2_FLAG 0x20000000
47#define KILL_THREAD_FLAGS (KILL_THREAD1_FLAG | KILL_THREAD2_FLAG)
110 hWndThread1 =
CreateWindowExW(0,
L"SendTest",
NULL, 0, 10, 10, 20, 20,
NULL,
NULL, 0,
NULL);
153 hWndThread2 =
CreateWindowExW(0,
L"SendTest",
NULL, 0, 10, 10, 20, 20,
NULL,
NULL, 0,
NULL);
210 ok(ExitCode == 456,
"Thread1 exit code is %lu\n", ExitCode);
212 ok(ExitCode == 6,
"Thread1 exit code is %lu\n", ExitCode);
217 ok(ExitCode == 123,
"Thread2 exit code is %lu\n", ExitCode);
219 ok(ExitCode == 7,
"Thread2 exit code is %lu\n", ExitCode);
static LRESULT CALLBACK WndProc(_In_ HWND hWnd, _In_ UINT message, _In_ WPARAM wParam, _In_ LPARAM lParam)
static DWORD WINAPI Thread2(_Inout_opt_ PVOID Parameter)
static void TestSendMessageTimeout(_In_ HWND hWnd, _In_ UINT Msg)
#define KILL_THREAD2_FLAG
static void TestRecursiveInterThreadMessages(_In_ BOOL KillThread1, _In_ BOOL KillThread2)
static DWORD WINAPI Thread1(_Inout_opt_ PVOID Parameter)
#define KILL_THREAD1_FLAG
#define WM_SENDTOOTHERTHREAD
#define KILL_THREAD_FLAGS
DWORD WINAPI ResumeThread(IN HANDLE hThread)
HANDLE WINAPI DECLSPEC_HOTPATCH CreateThread(IN LPSECURITY_ATTRIBUTES lpThreadAttributes, IN DWORD dwStackSize, IN LPTHREAD_START_ROUTINE lpStartAddress, IN LPVOID lpParameter, IN DWORD dwCreationFlags, OUT LPDWORD lpThreadId)
BOOL WINAPI TerminateThread(IN HANDLE hThread, IN DWORD dwExitCode)
BOOL WINAPI GetExitCodeThread(IN HANDLE hThread, OUT LPDWORD lpExitCode)
static BOOL IsDWmMsg(UINT msg)
#define RECORD_MESSAGE(...)
static BOOL IseKeyMsg(UINT msg)
DWORD WINAPI WaitForMultipleObjects(IN DWORD nCount, IN CONST HANDLE *lpHandles, IN BOOL bWaitAll, IN DWORD dwMilliseconds)
TW_UINT32 TW_UINT16 TW_UINT16 MSG
static __inline ATOM RegisterSimpleClass(WNDPROC lpfnWndProc, LPCWSTR lpszClassName)
DWORD WINAPI GetLastError(void)
DWORD WINAPI GetCurrentThreadId(void)
LRESULT WINAPI DispatchMessageA(_In_ const MSG *)
#define SendMessageTimeout
LRESULT WINAPI DefWindowProcW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
LRESULT WINAPI SendMessageTimeoutW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM, _In_ UINT, _In_ UINT, _Out_opt_ PDWORD_PTR)
DWORD WINAPI MsgWaitForMultipleObjectsEx(_In_ DWORD nCount, _In_reads_opt_(nCount) CONST HANDLE *pHandles, _In_ DWORD dwMilliseconds, _In_ DWORD dwWakeMask, _In_ DWORD dwFlags)
LRESULT WINAPI SendMessageTimeoutA(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM, _In_ UINT, _In_ UINT, _Out_opt_ PDWORD_PTR)
HWND WINAPI CreateWindowExW(_In_ DWORD dwExStyle, _In_opt_ LPCWSTR lpClassName, _In_opt_ LPCWSTR lpWindowName, _In_ DWORD dwStyle, _In_ int X, _In_ int Y, _In_ int nWidth, _In_ int nHeight, _In_opt_ HWND hWndParent, _In_opt_ HMENU hMenu, _In_opt_ HINSTANCE hInstance, _In_opt_ LPVOID lpParam)
BOOL WINAPI DestroyWindow(_In_ HWND)
_Inout_opt_ PVOID Parameter