25 lines
784 B
C#
25 lines
784 B
C#
using VisionBuilder.UI.Common.ViewModel;
|
|
using VisionBuilder.UI.Common.ViewModel.Interfaces.UI;
|
|
using VisionBuilder.UI.Windows.Dialogs;
|
|
|
|
namespace VisionBuilder.UI.Windows.Settings;
|
|
|
|
public class WindowsRecipeSelectionDialogService: IRecipeSelectionDialogService
|
|
{
|
|
private readonly IRecipeCreationTool _recipeCreationTool;
|
|
|
|
public WindowsRecipeSelectionDialogService(IRecipeCreationTool recipeCreationTool)
|
|
{
|
|
_recipeCreationTool = recipeCreationTool;
|
|
}
|
|
|
|
public bool SelectRecipe(RecipeSelectionVM recipeSelectionVm)
|
|
{
|
|
RecipeSelectionDialog dialog = new RecipeSelectionDialog(recipeSelectionVm, _recipeCreationTool);
|
|
if(dialog.ShowDialog() == DialogResult.OK)
|
|
{
|
|
return true;
|
|
}
|
|
return false;
|
|
}
|
|
} |