[ion] Dim Brightness before shutting down when the battery low

This commit is contained in:
Émilie Feral
2019-04-04 17:18:22 +02:00
parent 22b7853dfa
commit da12904873

View File

@@ -311,6 +311,7 @@ void AppsContainer::displayExamModePopUp(bool activate) {
void AppsContainer::shutdownDueToLowBattery() {
while (Ion::Battery::level() == Ion::Battery::Charge::EMPTY) {
Ion::Backlight::setBrightness(0);
m_emptyBatteryWindow.redraw(true);
Ion::Timing::msleep(3000);
Ion::Power::suspend();