If try to use a common window procedure for all controls in the page then the Window Procedure could receive different number of parameters by the stack.
For example, mouse move over ListView forms 3 parameters in the stack per event, when the RadioBatton click (NSD_Check) or NSD_SetText w/ empty text - only 1!
The same things happens for SendMessage calls.
This all leads to terrible things like randomly stack underflow in random places after System::Store SR0R1R2R3 from Window Procedure has called.
I've used CommCtr.nsh library (http://nsis.sourceforge.net/Header_file_for_Listview) to handle the ListView, but seems the system sends such events itself.
Why you just does not to put always 4 parameters at the stack (as Win32 API does), even if they empty?
Why would you want the same window procedure for different types of controls?
nsDialogs is a very thin wrapper on top of Win32 but not that thin...
Last edit: Anders 2017-06-12
Because i want to process all messages from a page in a single procedure just like in raw Win32 applications. It makes code more clean and readable.
Last edit: andry81 2017-01-04