Exemple #1
0
 public NavigateToProductFinderCmd(IDialogVM productFinder)
 {
     _productFinder    = productFinder;
     DisplayName       = "Product Search";
     DoCanExecuteCheck = () => true;
     DoExecute         = o => Navigate();
 }
Exemple #2
0
 public SubmitDialogCmd(IDialogVM dialog)
 {
     DisplayName = "Submit";
     DoExecute  += o =>
     {
         dialog.Submit();
         dialog.CloseCmd.Execute(null);
     };
 }
Exemple #3
0
        public void OpenDialog(IDialogVM ws)
        {
            var dialogPresenter = Application.Current.MainWindow as IDialogPresenter;

            if (dialogPresenter != null)
            {
                dialogPresenter.ShowModalDialog(ws);
            }
        }
Exemple #4
0
 public DialogWindow(Window parent, IDialogVM ws)
 {
     Resources   = parent.Resources;
     ws.CloseCmd = CloseCommand = new CloseCommandVM(Close);
     DataContext = this;
     InitializeComponent();
     Owner                  = parent;
     Width                  = 500;
     Height                 = 500;
     WindowStyle            = WindowStyle.None;
     ShowInTaskbar          = false;
     WindowStartupLocation  = WindowStartupLocation.CenterOwner;
     ResizeMode             = ResizeMode.NoResize;
     ContentControl.Content = ws;
 }
Exemple #5
0
        public void ShowAsynchModalDialog(IDialogVM ws)
        {
            var w = new DialogWindow(this, ws);

            w.Show();
        }