Disable the mic/cam toggles when admin disallows
Test: Use test DPC app Bug: 184927615 Change-Id: Ib3825967b2e7ddb6d4768abbc2e17fd39b936371
This commit is contained in:
@@ -16,6 +16,8 @@
|
||||
|
||||
package com.android.settings.privacy;
|
||||
|
||||
import static android.os.UserManager.DISALLOW_CAMERA_TOGGLE;
|
||||
|
||||
import static com.android.settings.utils.SensorPrivacyManagerHelper.CAMERA;
|
||||
|
||||
import android.content.Context;
|
||||
@@ -40,4 +42,9 @@ public class CameraToggleController extends SensorToggleController {
|
||||
&& DeviceConfig.getBoolean(DeviceConfig.NAMESPACE_PRIVACY, "camera_toggle_enabled",
|
||||
true) ? AVAILABLE_UNSEARCHABLE : UNSUPPORTED_ON_DEVICE;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String getRestriction() {
|
||||
return DISALLOW_CAMERA_TOGGLE;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user