[Win32 API] WindowProc
An application-defined function that processes messages sent to a window. the WNDPROC type define a pointer to this callback function. Syntax LRESULT CALLBACK WindowProc( __in HWND hwnd, __in UINT uMsg, __in WPARAM wParam, __in LPARAM lParam ); Parameters hwnd : a handle to the window. uMsg : The message For list of the system-provide messages. see System-Defined Message. wParam : Additional message information. The contents of this parameter depend on the value of th uMsg parameter. lParam : Additional message information. The contents of this parameter depend on the value of th uMsg parameter. Return Value The return value is the result of the message processing and depend on the message sent. Reference : http://msdn.microsoft.com/en-us/library/ms633573(VS.85).aspx