Summary: | Icon in the battery popup broken with 10% battery left | ||
---|---|---|---|
Product: | [Unmaintained] plasma4 | Reporter: | Kai Uwe Broulik <kde> |
Component: | widget-battery | Assignee: | Plasma Bugs List <plasma-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | annma, cfeck, markg85, viranch.mehta |
Priority: | NOR | Keywords: | regression |
Version: | 4.8.80 (beta1) | ||
Target Milestone: | --- | ||
Platform: | unspecified | ||
OS: | Linux | ||
Latest Commit: | http://commits.kde.org/kde-workspace/75dfd6f83f5d3dd5b4e2226ab6938eccc1f179ac | Version Fixed In: | 4.9 |
Sentry Crash Report: | |||
Attachments: |
Battery icon broken
45% remaining, iconin panel has 2 bars, icon in tooltip has only 1 bar battery applet at 10% charge |
Description
Kai Uwe Broulik
2012-06-12 17:45:06 UTC
Created attachment 71771 [details]
Battery icon broken
Created attachment 71773 [details]
45% remaining, iconin panel has 2 bars, icon in tooltip has only 1 bar
In the first screenshot. I certainly hope the switch element isn't used in the desktop version. That would be the begin of very nasty inconsistency. Anyway, was the percentage and the bar fine in KDE 4.8.x? If so, please do add the regression keyword. The switch was unfortunately replaced by a checkbox now in Beta 2. A Switch is predestined for two-state things and I hope it will emerge on the desktop as well. The QML checkbox also looks inconsistent with the rest, so .. (In reply to comment #3) ... > Anyway, was the percentage and the bar fine in KDE 4.8.x? If so, please do > add the regression keyword. One needs "editbugs" rights to add keywords, please add that yourself. (In reply to comment #5) > (In reply to comment #3) > ... > > Anyway, was the percentage and the bar fine in KDE 4.8.x? If so, please do > > add the regression keyword. > > One needs "editbugs" rights to add keywords, please add that yourself. done. (In reply to comment #2) > Created attachment 71773 [details] > 45% remaining, iconin panel has 2 bars, icon in tooltip has only 1 bar This was in previous version too, both the icons have different number of bars even for full battery (5 bars for in applet icon, and 4 bars in the icon in the popup, so this difference is scaled at all percentages). so _this_ is not a regression. Git commit 75dfd6f83f5d3dd5b4e2226ab6938eccc1f179ac by Viranch Mehta. Committed on 21/06/2012 at 14:28. Pushed by viranch into branch 'master'. Fix the popup battery icon when the battery charge is below 10% FIXED-IN:4.9 M +1 -0 plasma/generic/applets/batterymonitor/contents/ui/BatteryIcon.qml http://commits.kde.org/kde-workspace/75dfd6f83f5d3dd5b4e2226ab6938eccc1f179ac Created attachment 72015 [details]
battery applet at 10% charge
screenshot after fixing the bug (just for reference)
This causes a regression. When the battery gets removed, the "Unavailable" element is no longer displayed. The following patch fixes it. diff --git a/plasma/generic/applets/batterymonitor/contents/ui/BatteryIcon.qml b/plasma/generic/applets/batterymonitor/contents/ui/BatteryIcon.qml index ea5f82b..cfb50df 100644 --- a/plasma/generic/applets/batterymonitor/contents/ui/BatteryIcon.qml +++ b/plasma/generic/applets/batterymonitor/contents/ui/BatteryIcon.qml @@ -42,7 +42,7 @@ Item { anchors.fill: parent svg: svg elementId: hasBattery ? fillElement(percent) : "Unavailable" - visible: percent>10 + visible: percent>10 || !hasBattery } function fillElement(p) { Git commit 7668f435d5ceebf67363764661cdf3e128e9c30b by Viranch Mehta. Committed on 24/06/2012 at 20:53. Pushed by viranch into branch 'master'. Show the "Unavailable" FrameSvg when battery is not inserted into the computer (patch submitted by Christoph) M +1 -1 plasma/generic/applets/batterymonitor/contents/ui/BatteryIcon.qml http://commits.kde.org/kde-workspace/7668f435d5ceebf67363764661cdf3e128e9c30b |