mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-04-26 14:23:09 +00:00
Move the Battery settings with its provider
And make use of it to show if it's plugged or not
This commit is contained in:
parent
dd888a707f
commit
9dfac82863
2 changed files with 8 additions and 6 deletions
|
|
@ -137,6 +137,14 @@ Item {
|
|||
// indicator providers
|
||||
IndicatorProviders.BatteryProvider {
|
||||
id: batteryProvider
|
||||
|
||||
readonly property var setting: HomeScreenComponents.QuickSetting {
|
||||
text: i18n("Battery")
|
||||
icon: "battery-full" + (batteryProvider.pluggedIn ? "-charging" : "")
|
||||
enabled: false
|
||||
settingsCommand: "plasma-settings -m kcm_mobile_power"
|
||||
}
|
||||
Component.onCompleted: quickSettings.quickSettingsModel.include(setting)
|
||||
}
|
||||
IndicatorProviders.BluetoothProvider {
|
||||
id: bluetoothProvider
|
||||
|
|
|
|||
|
|
@ -79,12 +79,6 @@ HomeScreenComponents.QuickSettingsModel
|
|||
nmHandler.enableWwan(!enabledConnections.wwanEnabled)
|
||||
}
|
||||
}
|
||||
HomeScreenComponents.QuickSetting {
|
||||
text: i18n("Battery")
|
||||
icon: "battery-full"
|
||||
enabled: false
|
||||
settingsCommand: "plasma-settings -m kcm_mobile_power"
|
||||
}
|
||||
HomeScreenComponents.QuickSetting {
|
||||
text: i18n("Flashlight")
|
||||
icon: "flashlight-on"
|
||||
|
|
|
|||
Loading…
Reference in a new issue