[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-hardware-devel
Subject: Re: [Kde-hardware-devel] Review Request: Hide Battery levels config altogether (instead of disabling
From: "Alex Fiestas" <alex () eyeos ! org>
Date: 2012-10-10 15:28:22
Message-ID: 20121010152822.13538.96232 () vidsolbach ! de
[Download RAW message or body]
[Attachment #2 (multipart/alternative)]
> On Oct. 10, 2012, 2:46 p.m., Dario Freddi wrote:
> > Besides the fact that I like the principle of the idea, I am not sure whether the \
> > approach of hiding works better than disabling. I am saying this since it's quite \
> > common to have people unplugging their battery at times to save some of its \
> > lifecycle. Hence, the fact that batteryCount == 0 might also mean that the \
> > battery is simply unplugged, and maybe if that's the case having the fields \
> > simply disabled might make more sense. What do you think?
>
> Kai Uwe Broulik wrote:
> Correct me if I am wrong but I think in 90% of cases when there is no battery \
> present, it is probably a desktop computer where you don't need that option at all. \
> And since you cannot configure those options anyway if there is no battery, I think \
> hiding it is okay. I actaully cannot think of a person that I know that removes the \
> battery when the computer is running in a docking station powered all the time. \
> Maybe it is better (if possible?) to change the check to check for "Is Notebook" or \
> "Is Desktop Computer" instead of looking for a present battery? I don't know how \
> this works but at least kickoff shows a notebook icon on my notebook and a computer \
> on my desktop. :)
> Dario Freddi wrote:
> Definitely, that would be spot-on. We should definitely investigate the Kickoff \
> model, otherwise your rationale definitely makes sense and this patch might be good \
> to go. What I'm gonna do is add a "ship it!" anyway since you're totally right - if \
> you fancy having a look to what Kickoff does (but I think it is probably following \
> the same battery logic), feel free to do so, otherwise this patch is good to me.
> P.S.: Thanks for these small papercuts, they're really, really appreciated! :)
>
> Kai Uwe Broulik wrote:
> Just had a look at the kickoff code and yes, it uses:
> QList<Solid::Device> batteryList = \
> Solid::Device::listFromType(Solid::DeviceInterface::Battery, QString());
> if (batteryList.isEmpty()) {
> return KIcon("computer");
> } else {
> return KIcon("computer-laptop");
> }
> And I apologize for not yet having committed all my other review requests but I \
> have a new notebook that doesn't yet have commit access (and I am not at home atm). \
> Don't worry - and there's still a few days left for feature freeze :)
> Dario Freddi wrote:
> Perfect, then the ship it remains. Btw, should you have any problems with \
> committing the RRs in time, ping me ;)
It may not be the best solution (but surely it is slightly better)
Check if there is a LID (laptop screen). If there is no LID then it is no laptop :)
- Alex
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106783/#review20136
-----------------------------------------------------------
On Oct. 10, 2012, 2:36 p.m., Kai Uwe Broulik wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/106783/
> -----------------------------------------------------------
>
> (Updated Oct. 10, 2012, 2:36 p.m.)
>
>
> Review request for Solid.
>
>
> Description
> -------
>
> This little patch hides the config options for battery levels altogether when there \
> is no battery present. Reducses visual clutter.
>
> Diffs
> -----
>
> powerdevil/kcmodule/global/GeneralPage.cpp 5ff3f4d
> powerdevil/kcmodule/global/generalPage.ui 7840526
>
> Diff: http://git.reviewboard.kde.org/r/106783/diff/
>
>
> Testing
> -------
>
> Didn't test whether the elements are really hidden in the real condition (Have a \
> notebook only here, but I know that if works) but commented out the if and the \
> elements are all properly removed.
>
> Thanks,
>
> Kai Uwe Broulik
>
>
[Attachment #5 (text/html)]
<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/106783/">http://git.reviewboard.kde.org/r/106783/</a>
</td>
</tr>
</table>
<br />
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;"> <p style="margin-top: 0;">On October 10th, 2012, 2:46 p.m., <b>Dario \
Freddi</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;">Besides the fact that I like the principle of the idea, I am not sure \
whether the approach of hiding works better than disabling. I am saying this since \
it's quite common to have people unplugging their battery at times to save some \
of its lifecycle. Hence, the fact that batteryCount == 0 might also mean that the \
battery is simply unplugged, and maybe if that's the case having the fields \
simply disabled might make more sense. What do you think?</pre> </blockquote>
<p>On October 10th, 2012, 2:50 p.m., <b>Kai Uwe Broulik</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;">Correct me if I am wrong \
but I think in 90% of cases when there is no battery present, it is probably a \
desktop computer where you don't need that option at all. And since you cannot \
configure those options anyway if there is no battery, I think hiding it is okay. I \
actaully cannot think of a person that I know that removes the battery when the \
computer is running in a docking station powered all the time. Maybe it is better (if \
possible?) to change the check to check for "Is Notebook" or "Is \
Desktop Computer" instead of looking for a present battery? I don't know how \
this works but at least kickoff shows a notebook icon on my notebook and a computer \
on my desktop. :)</pre> </blockquote>
<p>On October 10th, 2012, 2:55 p.m., <b>Dario Freddi</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;">Definitely, that would \
be spot-on. We should definitely investigate the Kickoff model, otherwise your \
rationale definitely makes sense and this patch might be good to go. What I'm \
gonna do is add a "ship it!" anyway since you're totally right - if you \
fancy having a look to what Kickoff does (but I think it is probably following the \
same battery logic), feel free to do so, otherwise this patch is good to me.
P.S.: Thanks for these small papercuts, they're really, really appreciated! \
:)</pre> </blockquote>
<p>On October 10th, 2012, 3:01 p.m., <b>Kai Uwe Broulik</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;">Just had a look at the \
kickoff code and yes, it uses:
QList<Solid::Device> batteryList = \
Solid::Device::listFromType(Solid::DeviceInterface::Battery, QString());
if (batteryList.isEmpty()) {
return KIcon("computer");
} else {
return KIcon("computer-laptop");
}
And I apologize for not yet having committed all my other review requests but I have \
a new notebook that doesn't yet have commit access (and I am not at home atm). Don't \
worry - and there's still a few days left for feature freeze :)</pre> </blockquote>
<p>On October 10th, 2012, 3:04 p.m., <b>Dario Freddi</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;">Perfect, then the ship \
it remains. Btw, should you have any problems with committing the RRs in time, ping \
me ;)</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;">It may not be the best \
solution (but surely it is slightly better)
Check if there is a LID (laptop screen). If there is no LID then it is no laptop \
:)</pre> <br />
<p>- Alex</p>
<br />
<p>On October 10th, 2012, 2:36 p.m., Kai Uwe Broulik wrote:</p>
<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" \
style="background-image: \
url('http://git.reviewboard.kde.org/media/rb/images/review_request_box_top_bg.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 Oct. 10, 2012, 2:36 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 little patch hides the config options for battery levels altogether \
when there is no battery present. Reducses visual clutter.</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;">Didn't test whether the elements are really hidden in the real condition \
(Have a notebook only here, but I know that if works) but commented out the if and \
the elements are all properly removed.</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>powerdevil/kcmodule/global/GeneralPage.cpp <span style="color: \
grey">(5ff3f4d)</span></li>
<li>powerdevil/kcmodule/global/generalPage.ui <span style="color: \
grey">(7840526)</span></li>
</ul>
<p><a href="http://git.reviewboard.kde.org/r/106783/diff/" style="margin-left: \
3em;">View Diff</a></p>
</td>
</tr>
</table>
</div>
</body>
</html>
_______________________________________________
Kde-hardware-devel mailing list
Kde-hardware-devel@kde.org
https://mail.kde.org/mailman/listinfo/kde-hardware-devel
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic