diff options
| author | 2024-03-26 03:50:09 +0000 | |
|---|---|---|
| committer | 2024-03-26 03:50:09 +0000 | |
| commit | 76b5877745f93638b1152e407be0b853e9b722e5 (patch) | |
| tree | af1b978897afe63c45abec7cbe9db6afcda2763d | |
| parent | 0f1179c678d91bf9ef31f48ae5ab1c07b54c70bd (diff) | |
| parent | c6a2fdf1f37357c53fcbd41a05043a4019ea52d2 (diff) | |
Merge "To modify the icon on SettingsAlertDialogWithIcon" into main
| -rw-r--r-- | packages/SettingsLib/Spa/spa/src/com/android/settingslib/spa/widget/dialog/SettingsAlertDialogWithIcon.kt | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/packages/SettingsLib/Spa/spa/src/com/android/settingslib/spa/widget/dialog/SettingsAlertDialogWithIcon.kt b/packages/SettingsLib/Spa/spa/src/com/android/settingslib/spa/widget/dialog/SettingsAlertDialogWithIcon.kt index 1695e4f33915..030522d73b26 100644 --- a/packages/SettingsLib/Spa/spa/src/com/android/settingslib/spa/widget/dialog/SettingsAlertDialogWithIcon.kt +++ b/packages/SettingsLib/Spa/spa/src/com/android/settingslib/spa/widget/dialog/SettingsAlertDialogWithIcon.kt @@ -39,11 +39,17 @@ fun SettingsAlertDialogWithIcon( confirmButton: AlertDialogButton?, dismissButton: AlertDialogButton?, title: String?, + icon: @Composable (() -> Unit)? = { + Icon( + Icons.Default.WarningAmber, + contentDescription = null + ) + }, text: @Composable (() -> Unit)?, ) { AlertDialog( onDismissRequest = onDismissRequest, - icon = { Icon(Icons.Default.WarningAmber, contentDescription = null) }, + icon = icon, modifier = Modifier.width(getDialogWidth()), confirmButton = { confirmButton?.let { |