Inheritance: DialogViewModelBase
Exemplo n.º 1
0
 private void FinishCreateTransactionAction()
 {
     try
     {
         if (SignTransaction)
         {
             var outputs = PendingOutputs.Select(po => new Transaction.Output(po.OutputAmount, po.BuildOutputScript().Script)).ToArray();
             var shell   = (ShellViewModel)_parentViewModel;
             Func <string, Task> action = (passphrase) => SignTransactionWithPassphrase(passphrase, outputs, PublishTransaction);
             var dialog = new PassphraseDialogViewModel(shell, "Enter passphrase to sign transaction", "Sign", action);
             PostMessage(new OpenDialogMessage(dialog));
         }
         else
         {
             ShowUnsignedTransaction();
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }
Exemplo n.º 2
0
 private void FinishCreateTransactionAction()
 {
     try
     {
         if (SignTransaction)
         {
             var outputs = PendingOutputs.Select(po => new Transaction.Output(po.OutputAmount, po.BuildOutputScript().Script)).ToArray();
             var shell = (ShellViewModel)_parentViewModel;
             Func<string, Task> action = (passphrase) => SignTransactionWithPassphrase(passphrase, outputs, PublishTransaction);
             var dialog = new PassphraseDialogViewModel(shell, "Enter passphrase to sign transaction", "Sign", action);
             PostMessage(new OpenDialogMessage(dialog));
         }
         else
         {
             ShowUnsignedTransaction();
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }