Unlocked empty auth entry shouldn't be clickable anymore

Bug: 281615348
Fix: 281615348
Test: manual (see bug for recording)
Change-Id: I4a1b42a3624c65bdddad593fc77770422f72fbe1
This commit is contained in:
Helen Qin
2023-05-09 05:55:22 +00:00
parent fcdac40e64
commit ddef3203c5

View File

@@ -561,7 +561,12 @@ fun AuthenticationEntryRow(
enforceOneLine: Boolean = false,
) {
Entry(
onClick = { onEntrySelected(authenticationEntryInfo) },
onClick = if (authenticationEntryInfo.isUnlockedAndEmpty) {
{}
} // No-op
else {
{ onEntrySelected(authenticationEntryInfo) }
},
iconImageBitmap = authenticationEntryInfo.icon.toBitmap().asImageBitmap(),
entryHeadlineText = authenticationEntryInfo.title,
entrySecondLineText = stringResource(