Example #1
0
        private void 转账TToolStripMenuItem_Click(object sender, EventArgs e)
        {
            Transaction tx;

            using (TransferDialog dialog = new TransferDialog())
            {
                if (dialog.ShowDialog() != DialogResult.OK)
                {
                    return;
                }
                tx = dialog.GetTransaction();
            }
            if (tx is InvocationTransaction itx)
            {
                using (InvokeContractDialog dialog = new InvokeContractDialog(itx))
                {
                    if (dialog.ShowDialog() != DialogResult.OK)
                    {
                        return;
                    }
                    tx = dialog.GetTransaction();
                }
            }
            Helper.SignAndShowInformation(tx);
        }
Example #2
0
 private void invokeContractToolStripMenuItem_Click(object sender, EventArgs e)
 {
     using (InvokeContractDialog dialog = new InvokeContractDialog())
     {
         if (dialog.ShowDialog() != DialogResult.OK)
         {
             return;
         }
         Helper.SignAndShowInformation(dialog.GetTransaction());
     }
 }
Example #3
0
        private void  举EToolStripMenuItem_Click(object sender, EventArgs e)
        {
            InvocationTransaction tx;

            using (ElectionDialog dialog = new ElectionDialog())
            {
                if (dialog.ShowDialog() != DialogResult.OK)
                {
                    return;
                }
                tx = dialog.GetTransaction();
            }
            using (InvokeContractDialog dialog = new InvokeContractDialog(tx))
            {
                if (dialog.ShowDialog() != DialogResult.OK)
                {
                    return;
                }
                tx = dialog.GetTransaction();
            }
            Helper.SignAndShowInformation(tx);
        }
Example #4
0
        private void voteToolStripMenuItem_Click(object sender, EventArgs e)
        {
            InvocationTransaction tx;
            Contract contract = (Contract)listView1.SelectedItems[0].Tag;

            using (VotingDialog dialog = new VotingDialog(contract.ScriptHash))
            {
                if (dialog.ShowDialog() != DialogResult.OK)
                {
                    return;
                }
                tx = dialog.GetTransaction();
            }
            using (InvokeContractDialog dialog = new InvokeContractDialog(tx))
            {
                if (dialog.ShowDialog() != DialogResult.OK)
                {
                    return;
                }
                tx = dialog.GetTransaction();
            }
            Helper.SignAndShowInformation(tx);
        }