Skip to content
Commit b16e0522 authored by Jonathan Marten's avatar Jonathan Marten Committed by Laurent Montel
Browse files

Do not quit unconditionally when main window is closed

This appears to be a consequence of commits 3e34c9f0 and 22d1bab9.
When the system tray icon is active, closing the main window should
merely hide it but keep KMail running in the background.  However,
the test "if (KMMainWidget::mainWidgetList())" in KMKernel::canQueryClose()
seems to be incorect, it is saying "if there is a main window, then
allow the close".  The effect is that KMail quits when the window is
closed.

The test may have been incorrect for a long time, but masked by the
second part of the conditional "and if there is more than one main
window" before commit 3e34c9f0.  Most users will only have one KMail
main window open and so will never satisfy the condition.

Reversing the test restores the correct behaviour, so that KMail keeps
running in the background (with the system tray icon shown if enabled)
when the main window is closed.
parent 2b6bdedc
Pipeline #81873 passed with stage
in 23 minutes and 36 seconds
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment