@@ -549,9 +549,9 @@ private fun BundlePatchControls(
549549) {
550550 val context = LocalContext .current
551551
552- // Returns a lambda that shows a toast with [label ] and then executes [action].
553- fun withToast (label : String , action : () -> Unit ): () -> Unit = {
554- context.toast(label )
552+ // Shows a confirmation toast with [doneMessage ] and then executes [action]
553+ fun withToast (doneMessage : String , action : () -> Unit ): () -> Unit = {
554+ context.toast(doneMessage )
555555 action()
556556 }
557557
@@ -560,12 +560,17 @@ private fun BundlePatchControls(
560560 val restoreLabel = stringResource(R .string.expert_mode_restore_saved)
561561 val deselectAllLabel = stringResource(R .string.expert_mode_disable_all)
562562
563+ val enabledDone = stringResource(R .string.expert_mode_enable_all_done)
564+ val disabledDone = stringResource(R .string.expert_mode_disable_all_done)
565+ val resetDone = stringResource(R .string.expert_mode_reset_to_default_done)
566+ val restoredDone = stringResource(R .string.expert_mode_restore_saved_done)
567+
563568 Row (
564569 modifier = modifier.fillMaxWidth(),
565570 horizontalArrangement = Arrangement .spacedBy(12 .dp, Alignment .CenterHorizontally )
566571 ) {
567572 ActionPillButton (
568- onClick = withToast(selectAllLabel , onSelectAll),
573+ onClick = withToast(enabledDone , onSelectAll),
569574 icon = Icons .Outlined .DoneAll ,
570575 contentDescription = selectAllLabel,
571576 tooltip = selectAllLabel,
@@ -578,7 +583,7 @@ private fun BundlePatchControls(
578583 )
579584 )
580585 ActionPillButton (
581- onClick = withToast(defaultLabel , onResetToDefault),
586+ onClick = withToast(resetDone , onResetToDefault),
582587 icon = Icons .Outlined .Recommend ,
583588 contentDescription = defaultLabel,
584589 tooltip = defaultLabel,
@@ -590,7 +595,7 @@ private fun BundlePatchControls(
590595 )
591596 )
592597 ActionPillButton (
593- onClick = withToast(restoreLabel , onRestoreSaved),
598+ onClick = withToast(restoredDone , onRestoreSaved),
594599 icon = Icons .Outlined .History ,
595600 contentDescription = restoreLabel,
596601 tooltip = restoreLabel,
@@ -603,7 +608,7 @@ private fun BundlePatchControls(
603608 )
604609 )
605610 ActionPillButton (
606- onClick = withToast(deselectAllLabel , onDeselectAll),
611+ onClick = withToast(disabledDone , onDeselectAll),
607612 icon = Icons .Outlined .ClearAll ,
608613 contentDescription = deselectAllLabel,
609614 tooltip = deselectAllLabel,
@@ -618,7 +623,6 @@ private fun BundlePatchControls(
618623 }
619624}
620625
621-
622626/* *
623627 * Individual patch card with toggle and options button.
624628 */
0 commit comments