Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5f7bee46 authored by Adrian Roos's avatar Adrian Roos
Browse files

AOD: Pause sensors while proximity is covered

Test: manual
Bug: 62484520
Change-Id: I4c5b28e62396fb4178bdec7fa5f1f7af5209e2fa
parent 23ed7d76
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -158,13 +158,16 @@ public class DozeTriggers implements DozeMachine.Part {
                break;
            case DOZE:
            case DOZE_AOD:
            case DOZE_AOD_PAUSED:
                mDozeSensors.setProxListening(newState != DozeMachine.State.DOZE);
                mDozeSensors.setListening(true);
                if (oldState != DozeMachine.State.INITIALIZED) {
                    mDozeSensors.reregisterAllSensors();
                }
                break;
            case DOZE_AOD_PAUSED:
                mDozeSensors.setProxListening(true);
                mDozeSensors.setListening(false);
                break;
            case DOZE_PULSING:
                mDozeSensors.setProxListening(true);
                break;