Hello, I see that in win32callback.inc, WM_QUERYENDSESSION filters by LParam=0. This allows me to block system shutdown or reboot (by setting cancel:=true in an ApplicationProperties OnQueryEndSession event) but *not* intercept session closing (since LParam is <>0 in that case, see http://msdn.microsoft.com/en-us/library/aa376890.aspx). Maybe the lcl should pass on the message even if LParam is <>0 (but it should give a wey to differentiate cases). BTW, the same happens for WM_ENDSESSION, so the app isn't notified that the session is being closed.
Bye -- Luca Olivetti Wetron Automatización S.A. http://www.wetron.es/ Tel. +34 93 5883004 Fax +34 93 5883007 _______________________________________________ Lazarus mailing list [email protected] http://www.lazarus.freepascal.org/mailman/listinfo/lazarus
