D22626: KAlarm: simplify the starting of KOrganizer to use DBus activation
David Jarvie
noreply at phabricator.kde.org
Mon Jul 22 00:00:46 BST 2019
djarvie requested changes to this revision.
djarvie added a comment.
This revision now requires changes to proceed.
Tested on Neon.
The patched code doesn't start KOrganizer either. The QDBusInterface iface(KORG_DBUS_SERVICE, QStringLiteral(KORG_DBUS_LOAD_PATH), ...) call returns the error "The name org.kde.korganizer was not provided by any .service files".
Substituting with QDBusConnection::sessionBus().interface()->startService("org.kde.korganizer") returns the same error.
It also turns out that the original code didn't work - the KDBusServiceStarter::findServiceFor() call returns the error "Cannot open library libkdeinit5_korganizer".
Note that KOrganizer is installed, and if it is already running, the code works, and qdbusviewer lists org.kde.korganizer.
INLINE COMMENTS
> functions.cpp:1855
> QDBusReply<bool> reply = iface.call(QStringLiteral("load"));
> - if ((!reply.isValid() || !reply.value())
> - && iface.lastError().type() != QDBusError::UnknownMethod)
> + if ((!reply.isValid() || !reply.value()) && iface.lastError().type() != QDBusError::UnknownMethod)
> {
Please leave formatting unchanged.
REVISION DETAIL
https://phabricator.kde.org/D22626
To: dfaure, djarvie, vkrause
Cc: kde-pim
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20190721/4bf8cc4d/attachment.html>
More information about the kde-pim
mailing list