[Qt-interest] Detecting operating system shutdown

Bob Hood bhood2 at comcast.net
Thu Jul 16 23:35:01 CEST 2009


Yes, it did.  I sub-classed QApplication, overridding commitData(). 
When it is called, I tell my MainWindow to save it's settings (the same
as it does on a normal application exit).  I tested this with a shutdown
of my Vista64, and pending settings data was correctly written to disc
before the machine switched off.

Just what I needed.


Chris Probst wrote:
> You're most very welcome. Out of curiosity, did 
> QApplication::commitData help you? I was doing my work under Windows
> when faced with this problem.
>
> Bob Hood wrote:
>> Excellent.  Thank you, Bartosh.  That serves my needs nicely.
>>
>>
>> Bartosh Wroblevksy wrote:
>>> I had a similar problem and used info found here
>>> http://doc.trolltech.com/4.5/session.html
>>
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> Qt-interest mailing list
>> Qt-interest at trolltech.com
>> http://lists.trolltech.com/mailman/listinfo/qt-interest
>>   

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090716/5074d788/attachment.html 


More information about the Qt-interest-old mailing list