Re: [Kde-hardware-devel] Review Request 123263: WIP: KDE Connect backend for Solid

2015-04-19 Thread Lamarque Souza


 On April 5, 2015, 5:54 p.m., Lamarque Souza wrote:
  src/solid/devices/backends/kdeconnect/kdeconnectbattery.cpp, line 79
  https://git.reviewboard.kde.org/r/123263/diff/1/?file=360131#file360131line79
 
  Is it possible to retrieve a correct value for this and the other 
  values below (timeToEmpty, timeToFull, etc)?
 
 Kai Uwe Broulik wrote:
 I suppose, but that needs implementing on the KDE Connect side
 
 Albert Vaca Cintora wrote:
 From Android we could expose any of these: 
 http://developer.android.com/reference/android/os/BatteryManager.html
 
 Which ones would be useful in solid?

According to /usr/include/solid/battery.h the ones we really need are: for 
isPlugged we need BATTERY_PLUGGED_AC, BATTERY_PLUGGED_USB and 
BATTERY_PLUGGED_WIRELESS. isPowerSupply: I think it is always false in this 
case. type: always PhoneBattery. chargePercent: BATTERY_PROPERTY_CAPACITY. 
capacity: BATTERY_PROPERTY_CHARGE_COUNTER. isRechargeable: always true. 
chargeState: BATTERY_STATUS_CHARGING, BATTERY_STATUS_DISCHARGING, 
BATTERY_STATUS_FULL and BATTERY_STATUS_NOT_CHARGING; BATTERY_STATUS_UNKNOWN can 
also be used, but Solid does not expose such a value.


- Lamarque


---
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/123263/#review78531
---


On April 5, 2015, 8:56 p.m., Kai Uwe Broulik wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://git.reviewboard.kde.org/r/123263/
 ---
 
 (Updated April 5, 2015, 8:56 p.m.)
 
 
 Review request for kdeconnect, Solid, Albert Vaca Cintora, and Emmanuel 
 Pescosta.
 
 
 Repository: solid
 
 
 Description
 ---
 
 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.
 
 
 Diffs
 -
 
   src/solid/devices/CMakeLists.txt 9271ae1 
   src/solid/devices/backends/kdeconnect/CMakeLists.txt PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectbattery.h PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectbattery.cpp PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectdevice.h PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectdevice.cpp PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectdeviceinterface.h 
 PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectdeviceinterface.cpp 
 PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectmanager.h PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectmanager.cpp PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectportablemediaplayer.h 
 PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectportablemediaplayer.cpp 
 PRE-CREATION 
   src/solid/devices/managerbase.cpp eee4de5 
 
 Diff: https://git.reviewboard.kde.org/r/123263/diff/
 
 
 Testing
 ---
 
 With some crash fixes already pushed to plasma-workspace it works pretty well.
 
 
 Thanks,
 
 Kai Uwe Broulik
 


___
Kde-hardware-devel mailing list
Kde-hardware-devel@kde.org
https://mail.kde.org/mailman/listinfo/kde-hardware-devel


Re: [Kde-hardware-devel] Review Request 123263: WIP: KDE Connect backend for Solid

2015-04-19 Thread Albert Vaca Cintora

---
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/123263/#review79218
---


I don't understand the portable media player part. Does it do something? 
Besides that, I think we need to fix the issues opened by Lamarque and Alex, 
but looks good to me :)

- Albert Vaca Cintora


On abr. 5, 2015, 1:56 p.m., Kai Uwe Broulik wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://git.reviewboard.kde.org/r/123263/
 ---
 
 (Updated abr. 5, 2015, 1:56 p.m.)
 
 
 Review request for kdeconnect, Solid, Albert Vaca Cintora, and Emmanuel 
 Pescosta.
 
 
 Repository: solid
 
 
 Description
 ---
 
 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.
 
 
 Diffs
 -
 
   src/solid/devices/CMakeLists.txt 9271ae1 
   src/solid/devices/backends/kdeconnect/CMakeLists.txt PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectbattery.h PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectbattery.cpp PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectdevice.h PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectdevice.cpp PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectdeviceinterface.h 
 PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectdeviceinterface.cpp 
 PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectmanager.h PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectmanager.cpp PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectportablemediaplayer.h 
 PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectportablemediaplayer.cpp 
 PRE-CREATION 
   src/solid/devices/managerbase.cpp eee4de5 
 
 Diff: https://git.reviewboard.kde.org/r/123263/diff/
 
 
 Testing
 ---
 
 With some crash fixes already pushed to plasma-workspace it works pretty well.
 
 
 Thanks,
 
 Kai Uwe Broulik
 


___
Kde-hardware-devel mailing list
Kde-hardware-devel@kde.org
https://mail.kde.org/mailman/listinfo/kde-hardware-devel


Re: [Kde-hardware-devel] Review Request 123263: WIP: KDE Connect backend for Solid

2015-04-19 Thread Albert Vaca Cintora


 On abr. 5, 2015, 10:54 a.m., Lamarque Souza wrote:
  src/solid/devices/backends/kdeconnect/kdeconnectbattery.cpp, line 79
  https://git.reviewboard.kde.org/r/123263/diff/1/?file=360131#file360131line79
 
  Is it possible to retrieve a correct value for this and the other 
  values below (timeToEmpty, timeToFull, etc)?
 
 Kai Uwe Broulik wrote:
 I suppose, but that needs implementing on the KDE Connect side

From Android we could expose any of these: 
http://developer.android.com/reference/android/os/BatteryManager.html

Which ones would be useful in solid?


- Albert


---
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/123263/#review78531
---


On abr. 5, 2015, 1:56 p.m., Kai Uwe Broulik wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://git.reviewboard.kde.org/r/123263/
 ---
 
 (Updated abr. 5, 2015, 1:56 p.m.)
 
 
 Review request for kdeconnect, Solid, Albert Vaca Cintora, and Emmanuel 
 Pescosta.
 
 
 Repository: solid
 
 
 Description
 ---
 
 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.
 
 
 Diffs
 -
 
   src/solid/devices/CMakeLists.txt 9271ae1 
   src/solid/devices/backends/kdeconnect/CMakeLists.txt PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectbattery.h PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectbattery.cpp PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectdevice.h PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectdevice.cpp PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectdeviceinterface.h 
 PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectdeviceinterface.cpp 
 PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectmanager.h PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectmanager.cpp PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectportablemediaplayer.h 
 PRE-CREATION 
   src/solid/devices/backends/kdeconnect/kdeconnectportablemediaplayer.cpp 
 PRE-CREATION 
   src/solid/devices/managerbase.cpp eee4de5 
 
 Diff: https://git.reviewboard.kde.org/r/123263/diff/
 
 
 Testing
 ---
 
 With some crash fixes already pushed to plasma-workspace it works pretty well.
 
 
 Thanks,
 
 Kai Uwe Broulik
 


___
Kde-hardware-devel mailing list
Kde-hardware-devel@kde.org
https://mail.kde.org/mailman/listinfo/kde-hardware-devel


Re: [Kde-hardware-devel] Review Request 123418: Add X11 guards

2015-04-19 Thread Nerdopolis Turfwalker

---
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/123418/#review79234
---

Ship it!


kded5 no longer crashes due to powerdevel, and it appears to still work.

- Nerdopolis Turfwalker


On April 18, 2015, 4:34 p.m., Kai Uwe Broulik wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://git.reviewboard.kde.org/r/123418/
 ---
 
 (Updated April 18, 2015, 4:34 p.m.)
 
 
 Review request for Solid, Martin Gräßlin and Nerdopolis Turfwalker.
 
 
 Bugs: 346341
 https://bugs.kde.org/show_bug.cgi?id=346341
 
 
 Repository: powerdevil
 
 
 Description
 ---
 
 Improve X11 guards by correcting compile-time checks and adding runtime 
 checks; also don't constantly query QX11Info.
 
 
 Diffs
 -
 
   daemon/backends/upower/xrandrbrightness.h 67d44a8 
   daemon/backends/upower/xrandrbrightness.cpp f1cd5a5 
   daemon/kwinkscreenhelpereffect.h 4d0a163 
   daemon/kwinkscreenhelpereffect.cpp dec5d65 
 
 Diff: https://git.reviewboard.kde.org/r/123418/diff/
 
 
 Testing
 ---
 
 Compiles both with and without HAVE_XCB but I don't have a Wayland setup.
 
 
 Thanks,
 
 Kai Uwe Broulik
 


___
Kde-hardware-devel mailing list
Kde-hardware-devel@kde.org
https://mail.kde.org/mailman/listinfo/kde-hardware-devel


Re: [Kde-hardware-devel] Review Request 123418: Add X11 guards

2015-04-19 Thread Martin Gräßlin

---
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/123418/#review79238
---



daemon/kwinkscreenhelpereffect.h (line 30)
https://git.reviewboard.kde.org/r/123418/#comment54140

Is it really your intention to have compile checks for X11?

Let's face it the complete kwinscreenhelpereffect is pointless to compile 
at all without X11.

My suggestion is to only have the runtime checks.



daemon/kwinkscreenhelpereffect.cpp (lines 36 - 37)
https://git.reviewboard.kde.org/r/123418/#comment54139

why the bool: the m_connection should also carry the information: if it's 
not null you are on xcb, otherwise it'll be null.

Personally I have always only set the m_connection if we are on x11, mostly 
because I don't trust Qt :-P


- Martin Gräßlin


On April 18, 2015, 6:34 p.m., Kai Uwe Broulik wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://git.reviewboard.kde.org/r/123418/
 ---
 
 (Updated April 18, 2015, 6:34 p.m.)
 
 
 Review request for Solid, Martin Gräßlin and Nerdopolis Turfwalker.
 
 
 Bugs: 346341
 https://bugs.kde.org/show_bug.cgi?id=346341
 
 
 Repository: powerdevil
 
 
 Description
 ---
 
 Improve X11 guards by correcting compile-time checks and adding runtime 
 checks; also don't constantly query QX11Info.
 
 
 Diffs
 -
 
   daemon/backends/upower/xrandrbrightness.h 67d44a8 
   daemon/backends/upower/xrandrbrightness.cpp f1cd5a5 
   daemon/kwinkscreenhelpereffect.h 4d0a163 
   daemon/kwinkscreenhelpereffect.cpp dec5d65 
 
 Diff: https://git.reviewboard.kde.org/r/123418/diff/
 
 
 Testing
 ---
 
 Compiles both with and without HAVE_XCB but I don't have a Wayland setup.
 
 
 Thanks,
 
 Kai Uwe Broulik
 


___
Kde-hardware-devel mailing list
Kde-hardware-devel@kde.org
https://mail.kde.org/mailman/listinfo/kde-hardware-devel