Members of the KDE Community are recommended to subscribe to the kde-community mailing list at to allow them to participate in important discussions and receive other important announcements

Commit a97adcdb authored by Martin Koller's avatar Martin Koller

Allow Akonadi resources to participate in online/offline mode switching

Currently kmail has only a hardcoded check for pop3 and imap resources
when switching online/offline mode.
That means new/3rd-party resources can not participate
in this switching.

With introducing a new capability label "NeedsNetwork"
in a resources .desktop file, kmail can now switch the online mode
for all resources which have this flag set.

REVIEW: 122228
parent 761c265e
......@@ -932,7 +932,8 @@ void KMKernel::setAccountStatus(bool goOnline)
const QString identifier( type.identifier() );
if ( PimCommon::Util::isImapResource(identifier) ||
identifier.contains( POP3_RESOURCE_IDENTIFIER ) ||
identifier.contains( QLatin1String("akonadi_maildispatcher_agent") ) ) {
identifier.contains( QLatin1String("akonadi_maildispatcher_agent") ) ||
type.type().capabilities().contains(QLatin1String("NeedsNetwork")) ) {
type.setIsOnline( goOnline );
Markdown is supported
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