Esempio n. 1
0
        private AddBreakpointDialog CreateAddBreakpointDialog(BreakpointOperation op, MemoryCallbackType?type = null, uint?address = null, uint?mask = null)
        {
            var operation = (AddBreakpointDialog.BreakpointOperation)op;

            var b = new AddBreakpointDialog(operation)
            {
                MaxAddressSize = MemoryDomains.SystemBus.Size - 1
            };

            if (type != null)
            {
                b.BreakType = (MemoryCallbackType)type;
            }

            if (address != null)
            {
                b.Address = (uint)address;
            }

            if (mask != null)
            {
                b.AddressMask = (uint)mask;
            }

            if (!MCS.ExecuteCallbacksAvailable)
            {
                b.DisableExecuteOption();
            }

            return(b);
        }
Esempio n. 2
0
        private void AddBreakpointButton_Click(object sender, EventArgs e)
        {
            var b = new AddBreakpointDialog();

            if (b.ShowDialog() == DialogResult.OK)
            {
                Breakpoints.Add(b.Address, b.BreakType);
            }

            BreakpointView.ItemCount = Breakpoints.Count;
            UpdateBreakpointRemoveButton();
        }