<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 solid;">
    <tr>
     <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="http://git.reviewboard.kde.org/r/110384/">http://git.reviewboard.kde.org/r/110384/</a>
     </td>
    </tr>
   </table>
   <br />





<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
 <p style="margin-top: 0;">On July 26th, 2013, 2:07 a.m. UTC, <b>Kurt Hindenburg</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">I think this commit is causing build failures on MacOSX - kdelibs/4.11 branch

[ 21%] Building CXX object solid/solid/CMakeFiles/solid.dir/backends/iokit/iokitdevice.o                                                                        
/Volumes/Projects/kde/src/kde/kdelibs/solid/solid/backends/iokit/iokitdevice.cpp:235:25: error: 
      allocating an object of abstract class type
      'Solid::Backends::IOKit::Battery'
            iface = new Battery(this);
                        ^
/Volumes/Projects/kde/src/kde/kdelibs/solid/solid/ifaces/battery.h:78:21: note: 
      unimplemented pure virtual method 'capacity' in 'Battery'
        virtual int capacity() const = 0;
                    ^
/Volumes/Projects/kde/src/kde/kdelibs/solid/solid/ifaces/battery.h:93:22: note: 
      unimplemented pure virtual method 'isPowerSupply' in 'Battery'
        virtual bool isPowerSupply() const = 0;
                     ^
/Volumes/Projects/kde/src/kde/kdelibs/solid/solid/ifaces/battery.h:122:22: note: 
      unimplemented pure virtual method 'capacityChanged' in 'Battery'
        virtual void capacityChanged(int value, const QString &udi) = 0;
                     ^
/Volumes/Projects/kde/src/kde/kdelibs/solid/solid/ifaces/battery.h:152:22: note: 
      unimplemented pure virtual method 'powerSupplyStateChanged' in 'Battery'
        virtual void powerSupplyStateChanged(bool newState, const...
                     ^
/Volumes/Projects/kde/src/kde/kdelibs/solid/solid/backends/iokit/iokitdevice.cpp:216:13: warning: 
      18 enumeration values not handled in switch: 'Unknown', 'Block',
      'StorageAccess'... [-Wswitch]
    switch (type)
            ^
1 warning and 1 error generated.
make[2]: *** [solid/solid/CMakeFiles/solid.dir/backends/iokit/iokitdevice.o] Error 1</pre>
 </blockquote>







</blockquote>

<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">I wasn't aware there was another backend. Can you point me to some docs on IOKit? Will look into this, sorry for the inconvenience.</pre>
<br />










<p>- Kai Uwe</p>


<br />
<p>On May 13th, 2013, 3:38 p.m. UTC, Kai Uwe Broulik wrote:</p>








<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('http://git.reviewboard.kde.org/static/rb/images/review_request_box_top_bg.ab6f3b1072c9.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
 <tr>
  <td>

<div>Review request for Solid.</div>
<div>By Kai Uwe Broulik.</div>


<p style="color: grey;"><i>Updated May 13, 2013, 3:38 p.m.</i></p>






<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
 <table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
 <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">This patch adds support for the "power supply" property in UPower batteries that tells if a battery is actually powering the machine (ie. laptop battery) or just inside a peripheral device (ie. mouse, keyboard, ..)

In the UDev backend it reads the power supply property, in HAL, which doesn't support this, we're assuming that primary battery and UPS battery are power supply and others are not (which is the current way PowerDevil for example determins whether a computer has a battery or not). Can be somewhat problematic as not all mice report themselves as mouse battery.

This patch will in the end allow for example Plasma's battery monitor to only average battery percentage of batteries that are actually powering the machine, or PowerDevil to emit a separate message when your mouse battery goes low.</pre>
  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
 <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">After adjusting Plasma's powermanagement dataengine and battery monitor, I had it show two batteries (laptop battery and bluetooth mouse) and only take the laptop battery for battery percentage.</pre>
  </td>
 </tr>
</table>




<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>solid/solid/backends/fakehw/fakebattery.h <span style="color: grey">(c7e2791)</span></li>

 <li>solid/solid/backends/fakehw/fakebattery.cpp <span style="color: grey">(0afe765)</span></li>

 <li>solid/solid/backends/fakehw/fakecomputer.xml <span style="color: grey">(fe7e323)</span></li>

 <li>solid/solid/backends/hal/halbattery.h <span style="color: grey">(e2f38a0)</span></li>

 <li>solid/solid/backends/hal/halbattery.cpp <span style="color: grey">(4c530da)</span></li>

 <li>solid/solid/backends/upower/upowerbattery.h <span style="color: grey">(9d52f7b)</span></li>

 <li>solid/solid/backends/upower/upowerbattery.cpp <span style="color: grey">(1a40a2a)</span></li>

 <li>solid/solid/backends/upower/upowerdevice.cpp <span style="color: grey">(4930053)</span></li>

 <li>solid/solid/battery.h <span style="color: grey">(3afac6f)</span></li>

 <li>solid/solid/battery.cpp <span style="color: grey">(37d7321)</span></li>

 <li>solid/solid/ifaces/battery.h <span style="color: grey">(9987d18)</span></li>

</ul>

<p><a href="http://git.reviewboard.kde.org/r/110384/diff/" style="margin-left: 3em;">View Diff</a></p>







  </td>
 </tr>
</table>








  </div>
 </body>
</html>