Sat 6 Jul 01:11:18 CEST 2024
This commit is contained in:
parent
38266ed3e9
commit
3326154e0d
|
@ -189,17 +189,16 @@ function Right() {
|
|||
]
|
||||
}),
|
||||
on_clicked: () => {
|
||||
switch (powerProfiles.active_profile) {
|
||||
case 'balanced':
|
||||
powerProfiles.active_profile = 'performance';
|
||||
break;
|
||||
case 'performance':
|
||||
powerProfiles.active_profile = 'power-saver';
|
||||
break;
|
||||
default:
|
||||
powerProfiles.active_profile = 'balanced';
|
||||
break;
|
||||
};
|
||||
let next = false
|
||||
for (const profile of powerProfiles.profiles) {
|
||||
if (next) {
|
||||
powerProfiles.active_profile = profile["Profile"]
|
||||
return
|
||||
} else if (profile["Profile"] === powerProfiles.active_profile) {
|
||||
next = true
|
||||
}
|
||||
}
|
||||
powerProfiles.active_profile = powerProfiles.profiles[0]["Profile"]
|
||||
},
|
||||
}),
|
||||
Widget.Label({
|
||||
|
|
Loading…
Reference in New Issue