f1843cb492
Better patch to replace !218. - Auto and quick detection of previous D-Bus instance; - Remove private D-Bus compile definition, only use it on macOS without an existing D-Bus instance; - Safe reboot after crashes because the indicator is not relating on the kdeconnectd to run a D-Bus session; - Safe exit after clicking on `Quit` in the systray. More details in commit logs: Only enable private D-Bus on macOS because the other platforms do not need them. The app should be able to easily detect the session bus from the env DBUS_LAUNCHD_SESSION_BUS_SOCKET from launchd through launchctl. Because https://gitlab.freedesktop.org/dbus/dbus/-/blob/master/dbus/dbus-sysdeps-unix.c#L4392 shows that it is the only probing method on macOS with launchd. The D-Bus session bus can be easily found from launchd/launchctl with DBUS_LAUNCHD_SESSION_BUS_SOCKET env. It can be an external one (installed from HomeBrew) or an internal one (launched by a previous instance followed by a crash). The indicator helper on macOS can now automatically detect whether we can use a potentially (with launchd/launchctl env set, or KDE Connect macOS private_bus_address set) existed and usable session bus. If previous bus is usable, just try to launch the kdeconnectd with us. Otherwise, launch a private D-Bus daemon, export the launchd/launchctl env, and run a kdeconnectd instance. Everything works better and quicker now :) |
||
---|---|---|
.. | ||
CMakeLists.txt | ||
commandsmodel.cpp | ||
commandsmodel.h | ||
conversationmessage.cpp | ||
conversationmessage.h | ||
dbushelpers.h | ||
dbusinterfaces.cpp | ||
dbusinterfaces.h | ||
devicesmodel.cpp | ||
devicesmodel.h | ||
devicespluginfilterproxymodel.cpp | ||
devicespluginfilterproxymodel.h | ||
devicessortproxymodel.cpp | ||
devicessortproxymodel.h | ||
Messages.sh | ||
notificationsmodel.cpp | ||
notificationsmodel.h | ||
pluginmodel.cpp | ||
pluginmodel.h | ||
remotecommandsmodel.cpp | ||
remotecommandsmodel.h | ||
remotesinksmodel.cpp | ||
remotesinksmodel.h |