getting HWND and message loop without a window
so PeekMessage PostThreadMessage can be used by threads without having to create a window? Does the WINAPI WinMain create a thread automatically?
Technically speaking, WinMain usally isn't the entry point of a Windows program. When a program is executed, the Windows kernel creates the initial thread for the program and jumps into its entry point, which is usually a function in the c runtime which after setting up internals calls WinMain.
Quote:Original post by Mastaba
Technically speaking, WinMain usally isn't the entry point of a Windows program. When a program is executed, the Windows kernel creates the initial thread for the program and jumps into its entry point, which is usually a function in the c runtime which after setting up internals calls WinMain.
How can you get a handle to the application's thread then? cos i have seen a few windows functions which require you to supply a thread.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement