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

Commit 3f7bd9e0 authored by Eric Laurent's avatar Eric Laurent Committed by Android (Google) Code Review
Browse files

Merge "audio policy: fix sensor privacy listener"

parents 6d02cd00 35cd793f
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -1816,12 +1816,14 @@ void AudioPolicyService::UidPolicy::dumpInternals(int fd) {
void AudioPolicyService::SensorPrivacyPolicy::registerSelf() {
    SensorPrivacyManager spm;
    mSensorPrivacyEnabled = spm.isSensorPrivacyEnabled();
    (void)spm.addToggleSensorPrivacyListener(this);
    spm.addSensorPrivacyListener(this);
}

void AudioPolicyService::SensorPrivacyPolicy::unregisterSelf() {
    SensorPrivacyManager spm;
    spm.removeSensorPrivacyListener(this);
    spm.removeToggleSensorPrivacyListener(this);
}

bool AudioPolicyService::SensorPrivacyPolicy::isSensorPrivacyEnabled() {