Generalise and combine cancel/confirm prompts.

This commit is contained in:
Paul Chote
2016-06-16 18:21:55 +01:00
parent bc03c199f5
commit 3ac42e1643
9 changed files with 94 additions and 146 deletions

View File

@@ -409,7 +409,7 @@ namespace OpenRA.Mods.Common.Widgets.Logic
Action<ReplayMetadata, Action> onDeleteReplay = (r, after) =>
{
ConfirmationDialogs.PromptConfirmAction(
ConfirmationDialogs.ButtonPrompt(
title: "Delete selected replay?",
text: "Delete replay '{0}'?".F(Path.GetFileNameWithoutExtension(r.FilePath)),
onConfirm: () =>
@@ -450,7 +450,7 @@ namespace OpenRA.Mods.Common.Widgets.Logic
return;
}
ConfirmationDialogs.PromptConfirmAction(
ConfirmationDialogs.ButtonPrompt(
title: "Delete all selected replays?",
text: "Delete {0} replays?".F(list.Count),
onConfirm: () =>