lock: fix battery percentage (#340)
This commit is contained in:
parent
1f4ec53f8f
commit
6ae451413d
1 changed files with 1 additions and 1 deletions
|
|
@ -71,7 +71,7 @@ WrapperItem {
|
|||
|
||||
sourceComponent: StyledText {
|
||||
animate: true
|
||||
text: qsTr("%1%2 remaining").arg(UPower.onBattery ? "" : "(+) ").arg(UPower.displayDevice.percentage)
|
||||
text: qsTr("%1%2% remaining").arg(UPower.onBattery ? "" : "(+) ").arg(Math.round(UPower.displayDevice.percentage * 100))
|
||||
color: !UPower.onBattery || UPower.displayDevice.percentage > 0.2 ? Colours.palette.m3onSurface : Colours.palette.m3error
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue