Merge "Hides Screen Attention setting when AttentionService isn't installed." into sc-dev

This commit is contained in:
Yi Jiang
2021-06-22 16:59:20 +00:00
committed by Android (Google) Code Review
3 changed files with 35 additions and 5 deletions

View File

@@ -314,8 +314,7 @@ public class ScreenTimeoutSettings extends RadioButtonPickerFragment implements
}
private static boolean isScreenAttentionAvailable(Context context) {
return context.getResources().getBoolean(
com.android.internal.R.bool.config_adaptive_sleep_available);
return AdaptiveSleepPreferenceController.isAdaptiveSleepSupported(context);
}
private static class TimeoutCandidateInfo extends CandidateInfo {