View Single Post
Old 27th December 2011, 04:32   #558  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
Quote:
Originally Posted by LoRd_MuldeR View Post
When Windows is initiating a shutdown, it will send a WM_QUERYENDSESSION message followed by a WM_ENDSESSION message to all running applications.

I would assume that Qt processes these messages and closes the application's window (and thus exit the application) in order to allow the system to shutdown gracefully.

But I have not tested this yet. If it turns out that LameXP is blocking the system from shutting down, I will implement some workaround for this...
Update:

LameXP will not block Windows from shutting down, when the main window is showing or when the processing dialog is showing after all files have been processed.

However the processing dialog did block the shutdown when encoding is still in progress. This would be okay, if Windows didn't kill our encoder processes when the shutdown is initiated

It seems that Windows will rigidly kill all processes that have no own GUI window, so our encoder processes have no chance to react. Thus it makes no sense to keep the LameXP main process running.

For this reason I have hacked in a workaround that will force LameXP to quit as soon as possible, if the system is trying to shut down - even when encoding is not yet completed...
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊

Last edited by LoRd_MuldeR; 27th December 2011 at 14:40.
LoRd_MuldeR is offline   Reply With Quote