WIP: KDE Connect backend for Solid

Review Request #123263 - Created April 5, 2015 and discarded

Kai Uwe Broulik
kdeconnect, solid
albertvaka, emmanuelp

This adds a KDE Connect backend to Solid enabling us to show phone battery status in the device notifier, and have the phone appear in the device notifier like an external storage.

It is pretty synchronous at the moment. Any ideas how I could improve that? I guess when someone wants to get devices, it creates a new device interface and calls allDevices() or devicesFromQuery() immediately afterwards, so I cannot just do that stuff async and defer population? Or call deviceAdded for each of the initial ones once I have them?

It requires adjustment in the kdeconnect KIO slave so it can handle addresses like kdeconnect://org/kde/kdeconnect/123456 or kdeconnect:udi=/org/kde/kdeconnect/123456 (like mtp kio does) because all Dolphin or the device notifier have is the UDI. It also needs a new device action that matches "Portable Media Player" with the "kdeconnect" protocol, similar to mtp.

By adjusting the predicate in Dolphin's Places sidebar (and probably the file dialog) to query for the "kdeconnect" protocol, we can have its places automatically updated without having KDE Connect manually mess with KFilePlaces.

With some crash fixes already pushed to plasma-workspace it works pretty well.


  • 6
  • 0
  • 0
  • 6
Description From Last Updated
You can do what Android does here: set a default percentage value (-1 ou 0) and let the onChargeChanged() slot ... Lamarque Souza Lamarque Souza
If there was any error during dbus call calling value() will lead to crash(). Lamarque Souza Lamarque Souza
Is it possible to retrieve a correct value for this and the other values below (timeToEmpty, timeToFull, etc)? Lamarque Souza Lamarque Souza
Answering your question from this patch's description: yes, I prefer that you call onDeviceAdded() slot for each device appended here. ... Lamarque Souza Lamarque Souza
iirc this will block if dbus is frozen. Àlex Fiestas Àlex Fiestas
All this empty strings could be replaced with some hardcoded literal. Àlex Fiestas Àlex Fiestas
Lamarque Souza
Kai Uwe Broulik
Àlex Fiestas
Àlex Fiestas
Albert Vaca Cintora
Kai Uwe Broulik
Kai Uwe Broulik
Aleix Pol Gonzalez
Kai Uwe Broulik
Review request changed

Status: Discarded