/// <inheritdoc /> public IDialog CreateDialog(string title, IEditorViewModel editor, DialogOptions options) { var dialog = CreateDialog(title, (UIElement)editor.GetView(), options, new CloseActionCommand(_localization.GetValue("Cancel")), new AsyncActionCommand(_localization.GetValue("Save"), async() => { try { await editor.Save(); return(true); } catch (ValidationException) { return(false); } }) { Tag = ActionCommandTags.SaveCommand }); return(dialog); }