Summary: | Closing any window while KMail is minimized to the tray will quit the app | ||
---|---|---|---|
Product: | [Unmaintained] kmail | Reporter: | Andrew Belitsky <belitsky.a> |
Component: | general | Assignee: | kdepim bugs <kdepim-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | major | CC: | faure, marcus, mss, schwarzer |
Priority: | NOR | ||
Version: | 1.9.51 | ||
Target Milestone: | --- | ||
Platform: | unspecified | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
Andrew Belitsky
2008-06-07 20:24:54 UTC
*** Bug 163154 has been marked as a duplicate of this bug. *** Confirmed. Probably a regression in Qt4.4, the behaviour of quitOnLastWindowClosed() seems to have changed. OK, here's what dfaure suggested on IRC: 1. disable Qt's quitOnLastWindowClosed() in KMail and Kontact 2. Make it optional that KJobs do KGlobal::ref()/deref() -> KJob::allowQuitWhileJobsAreRunning(bool) 3. KGlobal::deref() will then take care of quitting the event loop. Both the mainwindows and the systemtray hold refs. Instead of 1), it might also be possible to disable the WA_QuitOnClose flags for KDE mainwindows. I'll need to investigate which jobs shouldn't be killed when quitting KMail, those jobs should call ref(). 2) is not needed after all; the abortMailCheck and cancelMailCheck in the kmmainwin and kmailpart destructors take care of allowing kmail to quit even while a mailcheck is happening. SVN commit 830027 by tmcguire: Fix detection when to quit the main loop, by disabling Qt's quitOnLastWindowClosed(), which would cause KMail to exit when the user OK'd a message box while KMail was mimimized to the systray. Implement cancelMailCheck() for POP accounts, so that those stop when quitting KMail. Also abort mail checks when using File->Quit in the menu and the systray is active. BUG: 163479 M +2 -2 kmail/kmcommands.cpp M +1 -1 kmail/kmmainwin.cpp M +7 -0 kmail/main.cpp M +6 -0 kmail/popaccount.cpp M +5 -0 kmail/popaccount.h M +8 -0 kontact/src/main.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=830027 SVN commit 831845 by tmcguire: Also quit the event loop when a part still holds a reference to a KGlobal object, probably by a KJob which wasn't properly deleted. This fixes that the Kontact process was still running (without a window) after viewing an article in Akregator. The real fix would be to fix Akregator, it should take care of properly cleaning up each KJob. @David: maybe KJob::allowQuitWhileJobsAreRunning(bool) wasn't such a bad idea after all? CCBUG: 163479 BUG: 166367 M +6 -0 mainwindow.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=831845 |