示例#1
0
        public TR Invoke(object dataContext)
        {
            T viewModel = InitViewModel(dataContext);

            WindowDisplayService.ShowDialog <TR>(_viewType, viewModel, null);

            return(viewModel.IsConfirmed ? viewModel.Result : default(TR));
        }
        public override void Invoke(ViewContext viewContext, bool asDialog)
        {
            T viewModel = InitViewModel();

            WindowDisplayService.ShowDialog <TR>(viewContext.ViewTypeName, viewModel, viewContext.ParentWindow);

            if (viewModel.IsConfirmed)
            {
                _processInteractionResult(viewModel.Result);
            }
        }
示例#3
0
        public virtual void Invoke(ViewContext viewContext, bool asDialog)
        {
            var viewModel = InitViewModel();

            WindowDisplayService.ShowWindow(viewContext.ViewTypeName, viewModel, asDialog, viewContext.ParentWindow);
        }
示例#4
0
 public NavigationService(WindowDisplayService displayService)
 {
     _displayService = displayService;
 }