Beispiel #1
0
        private void button2_Click(object sender, EventArgs e)
        {
            InsertInstruction insert = new InsertInstruction(method.Body.Instructions.Count - 1);
            insert.ShowDialog();

            if (insert.DialogResult == DialogResult.OK)
            {
                methodInstructions1.InsertInstruction(insert);
            }
        }
Beispiel #2
0
        private void button2_Click(object sender, EventArgs e)
        {
            InsertInstruction insert = new InsertInstruction(method.Body.Instructions.Count - 1);

            insert.ShowDialog();

            if (insert.DialogResult == DialogResult.OK)
            {
                methodInstructions1.InsertInstruction(insert);
            }
        }
Beispiel #3
0
        private void button3_Click(object sender, EventArgs e)
        {
            if (methodInstructions1.SelectedItem != null)
            {
                InsertInstruction insert = new InsertInstruction(method.Body.Instructions.Count - 1);
                insert.numericUpDown1.Value = methodInstructions1.SelectedIndex;
                insert.comboBox1.SelectedItem = methodInstructions1.SelectedInstruction.OpCode.Code.ToString();
                if (methodInstructions1.SelectedInstruction.Operand != null)
                    insert.textBox1.Text = methodInstructions1.SelectedInstruction.Operand.ToString();
                insert.button1.Text = "Modify";
                insert.ShowDialog();

                if (insert.DialogResult == DialogResult.OK)
                {
                    methodInstructions1.RemoveSelected();
                    methodInstructions1.InsertInstruction(insert);
                }
            }
        }
Beispiel #4
0
        private void button3_Click(object sender, EventArgs e)
        {
            if (methodInstructions1.SelectedItem != null)
            {
                InsertInstruction insert = new InsertInstruction(method.Body.Instructions.Count - 1);
                insert.numericUpDown1.Value   = methodInstructions1.SelectedIndex;
                insert.comboBox1.SelectedItem = methodInstructions1.SelectedInstruction.OpCode.Code.ToString();
                if (methodInstructions1.SelectedInstruction.Operand != null)
                {
                    insert.textBox1.Text = methodInstructions1.SelectedInstruction.Operand.ToString();
                }
                insert.button1.Text = "Modify";
                insert.ShowDialog();

                if (insert.DialogResult == DialogResult.OK)
                {
                    methodInstructions1.RemoveSelected();
                    methodInstructions1.InsertInstruction(insert);
                }
            }
        }