[automerge] Use migrated severity levels 2p: 2a775c69fc 2p: b5446ce437
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/17384684 Bug: 225388845 Change-Id: I1726bd5f8d1c2393e5abaffed8d70bd9cb0ec3e9
This commit is contained in:
committed by
Presubmit Automerger Backend
commit
5dfad2eb8c
@@ -25,7 +25,6 @@ import android.os.Bundle;
|
||||
import android.os.UserHandle;
|
||||
import android.safetycenter.SafetyEvent;
|
||||
import android.safetycenter.SafetySourceData;
|
||||
import android.safetycenter.SafetySourceSeverity;
|
||||
import android.safetycenter.SafetySourceStatus;
|
||||
|
||||
import com.android.settings.R;
|
||||
@@ -122,8 +121,8 @@ public final class BiometricsSafetySource {
|
||||
Intent clickIntent, boolean enabled, boolean hasEnrolled, SafetyEvent safetyEvent) {
|
||||
final PendingIntent pendingIntent = createPendingIntent(context, clickIntent);
|
||||
final int severityLevel =
|
||||
enabled && hasEnrolled ? SafetySourceSeverity.LEVEL_INFORMATION
|
||||
: SafetySourceSeverity.LEVEL_UNSPECIFIED;
|
||||
enabled && hasEnrolled ? SafetySourceData.SEVERITY_LEVEL_INFORMATION
|
||||
: SafetySourceData.SEVERITY_LEVEL_UNSPECIFIED;
|
||||
|
||||
final SafetySourceStatus status = new SafetySourceStatus.Builder(title, summary,
|
||||
severityLevel).setPendingIntent(pendingIntent).setEnabled(enabled).build();
|
||||
|
||||
@@ -26,7 +26,6 @@ import android.os.UserHandle;
|
||||
import android.safetycenter.SafetyEvent;
|
||||
import android.safetycenter.SafetySourceData;
|
||||
import android.safetycenter.SafetySourceIssue;
|
||||
import android.safetycenter.SafetySourceSeverity;
|
||||
import android.safetycenter.SafetySourceStatus;
|
||||
import android.safetycenter.SafetySourceStatus.IconAction;
|
||||
|
||||
@@ -71,9 +70,9 @@ public final class LockScreenSafetySource {
|
||||
final boolean isLockPatternSecure = screenLockPreferenceDetailsUtils.isLockPatternSecure();
|
||||
final int severityLevel = enabled
|
||||
? isLockPatternSecure
|
||||
? SafetySourceSeverity.LEVEL_INFORMATION
|
||||
: SafetySourceSeverity.LEVEL_RECOMMENDATION
|
||||
: SafetySourceSeverity.LEVEL_UNSPECIFIED;
|
||||
? SafetySourceData.SEVERITY_LEVEL_INFORMATION
|
||||
: SafetySourceData.SEVERITY_LEVEL_RECOMMENDATION
|
||||
: SafetySourceData.SEVERITY_LEVEL_UNSPECIFIED;
|
||||
|
||||
|
||||
final SafetySourceStatus status = new SafetySourceStatus.Builder(
|
||||
@@ -138,7 +137,7 @@ public final class LockScreenSafetySource {
|
||||
NO_SCREEN_LOCK_ISSUE_ID,
|
||||
context.getString(R.string.no_screen_lock_issue_title),
|
||||
context.getString(R.string.no_screen_lock_issue_summary),
|
||||
SafetySourceSeverity.LEVEL_RECOMMENDATION,
|
||||
SafetySourceData.SEVERITY_LEVEL_RECOMMENDATION,
|
||||
NO_SCREEN_LOCK_ISSUE_TYPE_ID)
|
||||
.setIssueCategory(SafetySourceIssue.ISSUE_CATEGORY_DEVICE)
|
||||
.addAction(action).build();
|
||||
|
||||
Reference in New Issue
Block a user