mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-04-29 15:03:09 +00:00
show the charging state in the battery icon
smaller percentage text
This commit is contained in:
parent
79763041b3
commit
a1ab2d2dbd
2 changed files with 3 additions and 3 deletions
|
|
@ -73,7 +73,7 @@ FocusScope {
|
||||||
batteryType: model["Type"]
|
batteryType: model["Type"]
|
||||||
percent: pmSource.data["Battery0"]["Percent"]
|
percent: pmSource.data["Battery0"]["Percent"]
|
||||||
hasBattery: true
|
hasBattery: true
|
||||||
pluggedIn: pmSource.data["Battery0"]["State"] === "Charging" && pmSource.data["Battery0"]["Is Power Supply"]
|
pluggedIn: pmSource.data["Battery0"]["State"] === "Charging"
|
||||||
}
|
}
|
||||||
|
|
||||||
Column {
|
Column {
|
||||||
|
|
|
||||||
|
|
@ -136,7 +136,7 @@ Item {
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: batteryLayout
|
id: batteryLayout
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
spacing: 0
|
spacing: -10
|
||||||
PlasmaComponents.Label {
|
PlasmaComponents.Label {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
|
|
@ -152,7 +152,7 @@ Item {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
hasBattery: true
|
hasBattery: true
|
||||||
percent: pmSource.data["Battery"]["Percent"]
|
percent: pmSource.data["Battery"]["Percent"]
|
||||||
//pluggedIn: batteryContainer.pluggedIn
|
pluggedIn: pmSource.data["AC Adapter"]["Plugged in"]
|
||||||
// height: batteryContainer.iconSize
|
// height: batteryContainer.iconSize
|
||||||
// width: height
|
// width: height
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue