Debugger: Added "Go to All" feature
This commit is contained in:
parent
c29ceb79ef
commit
ce893167c6
24 changed files with 1280 additions and 74 deletions
|
@ -240,23 +240,7 @@ void MemoryDumper::SetMemoryValueWord(DebugMemoryType memoryType, uint32_t addre
|
|||
uint8_t MemoryDumper::GetMemoryValue(DebugMemoryType memoryType, uint32_t address, bool disableSideEffects)
|
||||
{
|
||||
switch(memoryType) {
|
||||
case DebugMemoryType::CpuMemory:
|
||||
if(disableSideEffects) {
|
||||
AddressTypeInfo info;
|
||||
_debugger->GetAbsoluteAddressAndType(address, &info);
|
||||
if(info.Address >= 0) {
|
||||
switch(info.Type) {
|
||||
case AddressType::Register: return 0; //not supported
|
||||
case AddressType::InternalRam: return GetMemoryValue(DebugMemoryType::InternalRam, info.Address, true);
|
||||
case AddressType::PrgRom: return GetMemoryValue(DebugMemoryType::PrgRom, info.Address, true);
|
||||
case AddressType::WorkRam: return GetMemoryValue(DebugMemoryType::WorkRam, info.Address, true);
|
||||
case AddressType::SaveRam: return GetMemoryValue(DebugMemoryType::SaveRam, info.Address, true);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
return _memoryManager->DebugRead(address, false);
|
||||
}
|
||||
break;
|
||||
case DebugMemoryType::CpuMemory: return _memoryManager->DebugRead(address, disableSideEffects);
|
||||
|
||||
case DebugMemoryType::PpuMemory: return _mapper->DebugReadVRAM(address, disableSideEffects);
|
||||
case DebugMemoryType::PaletteMemory: return _ppu->ReadPaletteRAM(address);
|
||||
|
|
|
@ -51,6 +51,9 @@ namespace Mesen.GUI.Config
|
|||
[ShortcutName("Mark Selection as Unidentified Code/Data")]
|
||||
public XmlKeys MarkAsUnidentified = Keys.Control | Keys.D3;
|
||||
|
||||
[ShortcutName("Go to All")]
|
||||
public XmlKeys GoToAll = Keys.Control | Keys.Oemcomma;
|
||||
|
||||
[ShortcutName("Edit in Memory Viewer")]
|
||||
public XmlKeys CodeWindow_EditInMemoryViewer = Keys.F1;
|
||||
[ShortcutName("View in disassembly")]
|
||||
|
|
|
@ -104,20 +104,22 @@ namespace Mesen.GUI.Debugger
|
|||
|
||||
private void DisplaySymbolTooltip(Ld65DbgImporter.SymbolInfo symbol)
|
||||
{
|
||||
int relativeAddress = symbol.Address.HasValue ? symbol.Address.Value : -1;
|
||||
byte byteValue = relativeAddress >= 0 ? InteropEmu.DebugGetMemoryValue(DebugMemoryType.CpuMemory, (UInt32)relativeAddress) : (byte)0;
|
||||
UInt16 wordValue = relativeAddress >= 0 ? (UInt16)(byteValue | (InteropEmu.DebugGetMemoryValue(DebugMemoryType.CpuMemory, (UInt32)relativeAddress + 1) << 8)) : (UInt16)0;
|
||||
|
||||
AddressTypeInfo addressInfo = SymbolProvider.GetSymbolAddressInfo(symbol);
|
||||
|
||||
if(addressInfo != null) {
|
||||
if(addressInfo != null && addressInfo.Address >= 0) {
|
||||
int relativeAddress = InteropEmu.DebugGetRelativeAddress((uint)addressInfo.Address, addressInfo.Type);
|
||||
byte byteValue = relativeAddress >= 0 ? InteropEmu.DebugGetMemoryValue(DebugMemoryType.CpuMemory, (UInt32)relativeAddress) : (byte)0;
|
||||
UInt16 wordValue = relativeAddress >= 0 ? (UInt16)(byteValue | (InteropEmu.DebugGetMemoryValue(DebugMemoryType.CpuMemory, (UInt32)relativeAddress + 1) << 8)) : (UInt16)0;
|
||||
|
||||
var values = new Dictionary<string, string>() {
|
||||
{ "Symbol", symbol.Name }
|
||||
};
|
||||
|
||||
if(relativeAddress >= 0) {
|
||||
values["CPU Address"] = "$" + relativeAddress.ToString("X4");
|
||||
};
|
||||
} else {
|
||||
values["CPU Address"] = "<out of scope>";
|
||||
}
|
||||
|
||||
if(addressInfo.Type == AddressType.PrgRom) {
|
||||
values["PRG Offset"] = "$" + addressInfo.Address.ToString("X4");
|
||||
|
@ -129,7 +131,7 @@ namespace Mesen.GUI.Debugger
|
|||
} else {
|
||||
var values = new Dictionary<string, string>() {
|
||||
{ "Symbol", symbol.Name },
|
||||
{ "Constant", "$" + relativeAddress.ToString("X2") }
|
||||
{ "Constant", symbol.Address.HasValue ? ("$" + symbol.Address.Value.ToString("X2")) : "<unknown>" }
|
||||
};
|
||||
ShowTooltip(symbol.Name, values, -1, addressInfo);
|
||||
}
|
||||
|
|
|
@ -19,6 +19,7 @@ namespace Mesen.GUI.Debugger.Controls
|
|||
public event SwitchToSourceEventHandler OnSwitchView;
|
||||
|
||||
private int _lastClickedAddress = Int32.MaxValue;
|
||||
private Ld65DbgImporter.SymbolInfo _lastClickedSymbol = null;
|
||||
private string _newWatchValue = string.Empty;
|
||||
private string _lastWord = string.Empty;
|
||||
private Point _lastLocation = Point.Empty;
|
||||
|
@ -212,7 +213,17 @@ namespace Mesen.GUI.Debugger.Controls
|
|||
|
||||
private void GoToLocation()
|
||||
{
|
||||
Viewer.ScrollToLineNumber((int)_lastClickedAddress);
|
||||
if(_lastClickedSymbol != null && Viewer is ctrlSourceViewer) {
|
||||
Ld65DbgImporter.DefinitionInfo def = Viewer.SymbolProvider.GetSymbolDefinition(_lastClickedSymbol);
|
||||
if(def != null) {
|
||||
((ctrlSourceViewer)Viewer).ScrollToFileLine(def.FileName, def.Line);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if(_lastClickedAddress >= 0) {
|
||||
Viewer.ScrollToLineNumber((int)_lastClickedAddress);
|
||||
}
|
||||
}
|
||||
|
||||
private void mnuAddToWatch_Click(object sender, EventArgs e)
|
||||
|
@ -480,16 +491,17 @@ namespace Mesen.GUI.Debugger.Controls
|
|||
if(word.StartsWith("$")) {
|
||||
//CPU Address
|
||||
_lastClickedAddress = Int32.Parse(word.Substring(1), NumberStyles.AllowHexSpecifier);
|
||||
_lastClickedSymbol = null;
|
||||
_newWatchValue = "[$" + _lastClickedAddress.ToString("X") + "]";
|
||||
} else if(symbol != null) {
|
||||
//Symbol
|
||||
AddressTypeInfo addressInfo = (AddressTypeInfo)Viewer.SymbolProvider.GetSymbolAddressInfo(symbol);
|
||||
_lastClickedAddress = (Int32)InteropEmu.DebugGetRelativeAddress((uint)addressInfo.Address, addressInfo.Type);
|
||||
bool matchingLabelExists = codeLabel != null && codeLabel.Label == symbol.Name;
|
||||
_newWatchValue = matchingLabelExists ? $"[{word}]" : $"[${_lastClickedAddress.ToString("X2")}]";
|
||||
_lastClickedAddress = -1;
|
||||
_lastClickedSymbol = symbol;
|
||||
_newWatchValue = "[" + word + "]";
|
||||
} else if(codeLabel != null) {
|
||||
//Label
|
||||
_lastClickedAddress = (Int32)InteropEmu.DebugGetRelativeAddress(codeLabel.Address, codeLabel.AddressType);
|
||||
_lastClickedSymbol = null;
|
||||
_newWatchValue = "[" + word + "]";
|
||||
}
|
||||
|
||||
|
@ -526,6 +538,7 @@ namespace Mesen.GUI.Debugger.Controls
|
|||
mnuEditInMemoryViewer.Enabled = false;
|
||||
mnuEditInMemoryViewer.Text = $"Edit in Memory Viewer";
|
||||
|
||||
_lastClickedSymbol = null;
|
||||
if(mouseLocation.X < Viewer.CodeViewer.CodeMargin) {
|
||||
_lastClickedAddress = Viewer.CodeViewer.GetLineNumberAtPosition(mouseLocation.Y);
|
||||
} else {
|
||||
|
|
245
GUI.NET/Debugger/Controls/ctrlSearchResult.Designer.cs
generated
Normal file
245
GUI.NET/Debugger/Controls/ctrlSearchResult.Designer.cs
generated
Normal file
|
@ -0,0 +1,245 @@
|
|||
namespace Mesen.GUI.Debugger.Controls
|
||||
{
|
||||
partial class ctrlSearchResult
|
||||
{
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if(disposing && (components != null)) {
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Component Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.tableLayoutPanel4 = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.lblCpu = new System.Windows.Forms.Label();
|
||||
this.lblRelativeAddress = new System.Windows.Forms.Label();
|
||||
this.lblLocation = new System.Windows.Forms.Label();
|
||||
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.lblAbsoluteAddress = new System.Windows.Forms.Label();
|
||||
this.lblMemoryType = new System.Windows.Forms.Label();
|
||||
this.tableLayoutPanel3 = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.lblLabelName = new System.Windows.Forms.Label();
|
||||
this.picType = new System.Windows.Forms.PictureBox();
|
||||
this.picWarning = new System.Windows.Forms.PictureBox();
|
||||
this.tableLayoutPanel1.SuspendLayout();
|
||||
this.tableLayoutPanel4.SuspendLayout();
|
||||
this.tableLayoutPanel2.SuspendLayout();
|
||||
this.tableLayoutPanel3.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.picType)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.picWarning)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// tableLayoutPanel1
|
||||
//
|
||||
this.tableLayoutPanel1.ColumnCount = 2;
|
||||
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20F));
|
||||
this.tableLayoutPanel1.Controls.Add(this.tableLayoutPanel4, 1, 1);
|
||||
this.tableLayoutPanel1.Controls.Add(this.lblLocation, 0, 1);
|
||||
this.tableLayoutPanel1.Controls.Add(this.tableLayoutPanel2, 1, 0);
|
||||
this.tableLayoutPanel1.Controls.Add(this.tableLayoutPanel3, 0, 0);
|
||||
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
|
||||
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||
this.tableLayoutPanel1.RowCount = 3;
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F));
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F));
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||
this.tableLayoutPanel1.Size = new System.Drawing.Size(251, 36);
|
||||
this.tableLayoutPanel1.TabIndex = 0;
|
||||
//
|
||||
// tableLayoutPanel4
|
||||
//
|
||||
this.tableLayoutPanel4.ColumnCount = 2;
|
||||
this.tableLayoutPanel4.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||
this.tableLayoutPanel4.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle());
|
||||
this.tableLayoutPanel4.Controls.Add(this.lblCpu, 0, 0);
|
||||
this.tableLayoutPanel4.Controls.Add(this.lblRelativeAddress, 1, 0);
|
||||
this.tableLayoutPanel4.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tableLayoutPanel4.Location = new System.Drawing.Point(125, 17);
|
||||
this.tableLayoutPanel4.Margin = new System.Windows.Forms.Padding(0);
|
||||
this.tableLayoutPanel4.Name = "tableLayoutPanel4";
|
||||
this.tableLayoutPanel4.RowCount = 1;
|
||||
this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||
this.tableLayoutPanel4.Size = new System.Drawing.Size(126, 17);
|
||||
this.tableLayoutPanel4.TabIndex = 6;
|
||||
//
|
||||
// lblCpu
|
||||
//
|
||||
this.lblCpu.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.lblCpu.AutoSize = true;
|
||||
this.lblCpu.Font = new System.Drawing.Font("Microsoft Sans Serif", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.lblCpu.ForeColor = System.Drawing.SystemColors.GrayText;
|
||||
this.lblCpu.Location = new System.Drawing.Point(34, 0);
|
||||
this.lblCpu.Name = "lblCpu";
|
||||
this.lblCpu.Padding = new System.Windows.Forms.Padding(0, 3, 0, 0);
|
||||
this.lblCpu.Size = new System.Drawing.Size(25, 15);
|
||||
this.lblCpu.TabIndex = 4;
|
||||
this.lblCpu.Text = "CPU";
|
||||
//
|
||||
// lblRelativeAddress
|
||||
//
|
||||
this.lblRelativeAddress.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.lblRelativeAddress.AutoSize = true;
|
||||
this.lblRelativeAddress.Location = new System.Drawing.Point(65, 2);
|
||||
this.lblRelativeAddress.Name = "lblRelativeAddress";
|
||||
this.lblRelativeAddress.Padding = new System.Windows.Forms.Padding(0, 0, 0, 2);
|
||||
this.lblRelativeAddress.Size = new System.Drawing.Size(58, 15);
|
||||
this.lblRelativeAddress.TabIndex = 2;
|
||||
this.lblRelativeAddress.Text = "$FFFF:$00";
|
||||
//
|
||||
// lblLocation
|
||||
//
|
||||
this.lblLocation.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.lblLocation.AutoSize = true;
|
||||
this.lblLocation.Location = new System.Drawing.Point(3, 19);
|
||||
this.lblLocation.Name = "lblLocation";
|
||||
this.lblLocation.Padding = new System.Windows.Forms.Padding(0, 0, 0, 2);
|
||||
this.lblLocation.Size = new System.Drawing.Size(71, 15);
|
||||
this.lblLocation.TabIndex = 1;
|
||||
this.lblLocation.Text = "Filename.asm";
|
||||
//
|
||||
// tableLayoutPanel2
|
||||
//
|
||||
this.tableLayoutPanel2.ColumnCount = 2;
|
||||
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle());
|
||||
this.tableLayoutPanel2.Controls.Add(this.lblAbsoluteAddress, 1, 0);
|
||||
this.tableLayoutPanel2.Controls.Add(this.lblMemoryType, 0, 0);
|
||||
this.tableLayoutPanel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tableLayoutPanel2.Location = new System.Drawing.Point(125, 0);
|
||||
this.tableLayoutPanel2.Margin = new System.Windows.Forms.Padding(0);
|
||||
this.tableLayoutPanel2.Name = "tableLayoutPanel2";
|
||||
this.tableLayoutPanel2.RowCount = 1;
|
||||
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||
this.tableLayoutPanel2.Size = new System.Drawing.Size(126, 17);
|
||||
this.tableLayoutPanel2.TabIndex = 4;
|
||||
//
|
||||
// lblAbsoluteAddress
|
||||
//
|
||||
this.lblAbsoluteAddress.Anchor = System.Windows.Forms.AnchorStyles.Right;
|
||||
this.lblAbsoluteAddress.AutoSize = true;
|
||||
this.lblAbsoluteAddress.Location = new System.Drawing.Point(59, 1);
|
||||
this.lblAbsoluteAddress.Name = "lblAbsoluteAddress";
|
||||
this.lblAbsoluteAddress.Padding = new System.Windows.Forms.Padding(0, 2, 0, 0);
|
||||
this.lblAbsoluteAddress.Size = new System.Drawing.Size(64, 15);
|
||||
this.lblAbsoluteAddress.TabIndex = 3;
|
||||
this.lblAbsoluteAddress.Text = "$12345:$55";
|
||||
//
|
||||
// lblMemoryType
|
||||
//
|
||||
this.lblMemoryType.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.lblMemoryType.AutoSize = true;
|
||||
this.lblMemoryType.Font = new System.Drawing.Font("Microsoft Sans Serif", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.lblMemoryType.ForeColor = System.Drawing.SystemColors.GrayText;
|
||||
this.lblMemoryType.Location = new System.Drawing.Point(3, 0);
|
||||
this.lblMemoryType.Name = "lblMemoryType";
|
||||
this.lblMemoryType.Padding = new System.Windows.Forms.Padding(0, 3, 0, 0);
|
||||
this.lblMemoryType.Size = new System.Drawing.Size(50, 15);
|
||||
this.lblMemoryType.TabIndex = 4;
|
||||
this.lblMemoryType.Text = "PRG ROM";
|
||||
//
|
||||
// tableLayoutPanel3
|
||||
//
|
||||
this.tableLayoutPanel3.ColumnCount = 3;
|
||||
this.tableLayoutPanel3.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle());
|
||||
this.tableLayoutPanel3.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle());
|
||||
this.tableLayoutPanel3.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||
this.tableLayoutPanel3.Controls.Add(this.picWarning, 0, 0);
|
||||
this.tableLayoutPanel3.Controls.Add(this.lblLabelName, 2, 0);
|
||||
this.tableLayoutPanel3.Controls.Add(this.picType, 1, 0);
|
||||
this.tableLayoutPanel3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tableLayoutPanel3.Location = new System.Drawing.Point(0, 0);
|
||||
this.tableLayoutPanel3.Margin = new System.Windows.Forms.Padding(0);
|
||||
this.tableLayoutPanel3.Name = "tableLayoutPanel3";
|
||||
this.tableLayoutPanel3.RowCount = 1;
|
||||
this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle());
|
||||
this.tableLayoutPanel3.Size = new System.Drawing.Size(125, 17);
|
||||
this.tableLayoutPanel3.TabIndex = 5;
|
||||
//
|
||||
// lblLabelName
|
||||
//
|
||||
this.lblLabelName.AutoSize = true;
|
||||
this.lblLabelName.Location = new System.Drawing.Point(37, 0);
|
||||
this.lblLabelName.Name = "lblLabelName";
|
||||
this.lblLabelName.Padding = new System.Windows.Forms.Padding(0, 2, 0, 0);
|
||||
this.lblLabelName.Size = new System.Drawing.Size(75, 15);
|
||||
this.lblLabelName.TabIndex = 0;
|
||||
this.lblLabelName.Text = "MyLabelName";
|
||||
//
|
||||
// picType
|
||||
//
|
||||
this.picType.Location = new System.Drawing.Point(18, 0);
|
||||
this.picType.Margin = new System.Windows.Forms.Padding(1, 0, 0, 0);
|
||||
this.picType.Name = "picType";
|
||||
this.picType.Size = new System.Drawing.Size(16, 16);
|
||||
this.picType.TabIndex = 1;
|
||||
this.picType.TabStop = false;
|
||||
//
|
||||
// picWarning
|
||||
//
|
||||
this.picWarning.Image = global::Mesen.GUI.Properties.Resources.Warning;
|
||||
this.picWarning.Location = new System.Drawing.Point(1, 0);
|
||||
this.picWarning.Margin = new System.Windows.Forms.Padding(1, 0, 0, 0);
|
||||
this.picWarning.Name = "picWarning";
|
||||
this.picWarning.Size = new System.Drawing.Size(16, 16);
|
||||
this.picWarning.TabIndex = 2;
|
||||
this.picWarning.TabStop = false;
|
||||
//
|
||||
// ctrlSearchResult
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.Controls.Add(this.tableLayoutPanel1);
|
||||
this.Margin = new System.Windows.Forms.Padding(0, 0, 0, 1);
|
||||
this.Name = "ctrlSearchResult";
|
||||
this.Size = new System.Drawing.Size(251, 36);
|
||||
this.tableLayoutPanel1.ResumeLayout(false);
|
||||
this.tableLayoutPanel1.PerformLayout();
|
||||
this.tableLayoutPanel4.ResumeLayout(false);
|
||||
this.tableLayoutPanel4.PerformLayout();
|
||||
this.tableLayoutPanel2.ResumeLayout(false);
|
||||
this.tableLayoutPanel2.PerformLayout();
|
||||
this.tableLayoutPanel3.ResumeLayout(false);
|
||||
this.tableLayoutPanel3.PerformLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.picType)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.picWarning)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||
private System.Windows.Forms.Label lblLabelName;
|
||||
private System.Windows.Forms.Label lblLocation;
|
||||
private System.Windows.Forms.Label lblRelativeAddress;
|
||||
private System.Windows.Forms.Label lblAbsoluteAddress;
|
||||
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
|
||||
private System.Windows.Forms.Label lblMemoryType;
|
||||
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel3;
|
||||
private System.Windows.Forms.PictureBox picType;
|
||||
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel4;
|
||||
private System.Windows.Forms.Label lblCpu;
|
||||
private System.Windows.Forms.PictureBox picWarning;
|
||||
}
|
||||
}
|
136
GUI.NET/Debugger/Controls/ctrlSearchResult.cs
Normal file
136
GUI.NET/Debugger/Controls/ctrlSearchResult.cs
Normal file
|
@ -0,0 +1,136 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Drawing;
|
||||
using System.Data;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
using Mesen.GUI.Controls;
|
||||
using Mesen.GUI.Forms;
|
||||
using System.IO;
|
||||
|
||||
namespace Mesen.GUI.Debugger.Controls
|
||||
{
|
||||
public partial class ctrlSearchResult : BaseControl
|
||||
{
|
||||
public new event EventHandler Click;
|
||||
public new event EventHandler DoubleClick;
|
||||
|
||||
public ctrlSearchResult()
|
||||
{
|
||||
InitializeComponent();
|
||||
this.TabStop = false;
|
||||
this.AddClickHandler(this);
|
||||
}
|
||||
|
||||
protected override bool ProcessTabKey(bool forward)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
private void ChildClickHandler(object sender, EventArgs e)
|
||||
{
|
||||
Click?.Invoke(this, e);
|
||||
}
|
||||
|
||||
private void CtrlDoubleClickHandler(object sender, EventArgs e)
|
||||
{
|
||||
DoubleClick?.Invoke(this, e);
|
||||
}
|
||||
|
||||
private void AddClickHandler(Control parent)
|
||||
{
|
||||
foreach(Control ctrl in parent.Controls) {
|
||||
ctrl.Click += ChildClickHandler;
|
||||
ctrl.DoubleClick += CtrlDoubleClickHandler;
|
||||
AddClickHandler(ctrl);
|
||||
}
|
||||
}
|
||||
|
||||
public void Initialize(SearchResultInfo info)
|
||||
{
|
||||
lblLabelName.Text = info.Caption;
|
||||
if(info.AbsoluteAddress >= 0) {
|
||||
lblAbsoluteAddress.Text = "$" + info.AbsoluteAddress.ToString("X4") + ":$" + info.Value.ToString("X2");
|
||||
if(info.RelativeAddress >= 0) {
|
||||
lblRelativeAddress.ForeColor = SystemColors.ControlText;
|
||||
lblRelativeAddress.Text = "$" + info.RelativeAddress.ToString("X4") + ":$" + info.Value.ToString("X2");
|
||||
} else {
|
||||
lblRelativeAddress.ForeColor = SystemColors.GrayText;
|
||||
lblRelativeAddress.Text = "<out of scope>";
|
||||
}
|
||||
lblMemoryType.Text = ResourceHelper.GetEnumText(info.MemoryType);
|
||||
lblCpu.Text = "CPU";
|
||||
if(info.SearchResultType == SearchResultType.Function) {
|
||||
picType.Image = Properties.Resources.Function;
|
||||
} else if(info.SearchResultType == SearchResultType.JumpTarget) {
|
||||
picType.Image = Properties.Resources.JumpTarget;
|
||||
} else if(info.MemoryType == AddressType.Register) {
|
||||
picType.Image = Properties.Resources.RegisterIcon;
|
||||
} else {
|
||||
picType.Image = Properties.Resources.CheatCode;
|
||||
}
|
||||
} else if(info.SearchResultType == SearchResultType.File) {
|
||||
lblMemoryType.Text = "File";
|
||||
lblCpu.Text = "";
|
||||
lblAbsoluteAddress.Text = "";
|
||||
lblRelativeAddress.Text = "";
|
||||
picType.Image = Properties.Resources.LogWindow;
|
||||
} else if(info.SearchResultType == SearchResultType.Constant) {
|
||||
lblMemoryType.Text = "Constant";
|
||||
lblCpu.Text = "";
|
||||
lblAbsoluteAddress.Text = "";
|
||||
lblRelativeAddress.Text = "Value: $" + info.Value.ToString("X2");
|
||||
picType.Image = Properties.Resources.Enum;
|
||||
} else {
|
||||
lblAbsoluteAddress.Text = "";
|
||||
lblRelativeAddress.Text = "";
|
||||
lblCpu.Text = "";
|
||||
lblMemoryType.Text = "";
|
||||
picType.Image = null;
|
||||
}
|
||||
|
||||
picWarning.Visible = info.Disabled;
|
||||
if(info.Disabled) {
|
||||
this.Enabled = false;
|
||||
} else {
|
||||
this.Enabled = true;
|
||||
}
|
||||
|
||||
if(!string.IsNullOrWhiteSpace(info.Filename)) {
|
||||
if(info.SearchResultType == SearchResultType.File) {
|
||||
lblLocation.Text = info.Filename;
|
||||
} else {
|
||||
lblLocation.Text = Path.GetFileName(info.Filename) + ":" + (info.FileLineNumber + 1).ToString();
|
||||
}
|
||||
} else {
|
||||
lblLocation.Text = "";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public enum SearchResultType
|
||||
{
|
||||
Function,
|
||||
JumpTarget,
|
||||
Constant,
|
||||
Data,
|
||||
File
|
||||
}
|
||||
|
||||
public class SearchResultInfo
|
||||
{
|
||||
public string Caption;
|
||||
public int AbsoluteAddress;
|
||||
public int RelativeAddress;
|
||||
public int Value;
|
||||
public string Filename;
|
||||
public int FileLineNumber;
|
||||
public AddressType MemoryType;
|
||||
public SearchResultType SearchResultType;
|
||||
public CodeLabel CodeLabel;
|
||||
public bool Disabled;
|
||||
}
|
||||
}
|
120
GUI.NET/Debugger/Controls/ctrlSearchResult.resx
Normal file
120
GUI.NET/Debugger/Controls/ctrlSearchResult.resx
Normal file
|
@ -0,0 +1,120 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
</root>
|
|
@ -327,6 +327,17 @@ namespace Mesen.GUI.Debugger.Controls
|
|||
_tooltipManager?.Close();
|
||||
}
|
||||
|
||||
public void ScrollToFileLine(string filename, int lineNumber)
|
||||
{
|
||||
foreach(Ld65DbgImporter.FileInfo fileInfo in cboFile.Items) {
|
||||
if(fileInfo.Name == filename) {
|
||||
cboFile.SelectedItem = fileInfo;
|
||||
ctrlCodeViewer.ScrollToLineIndex(lineNumber);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void ScrollToAddress(AddressTypeInfo addressInfo, bool scrollToTop = false)
|
||||
{
|
||||
if(addressInfo.Address >= 0 && addressInfo.Type == AddressType.PrgRom) {
|
||||
|
|
|
@ -93,6 +93,21 @@ namespace Mesen.GUI.Debugger
|
|||
return null;
|
||||
}
|
||||
|
||||
public DefinitionInfo GetSymbolDefinition(SymbolInfo symbol)
|
||||
{
|
||||
foreach(int definition in symbol.Definitions) {
|
||||
LineInfo line = _lines[definition];
|
||||
string fileName = _files[line.FileID].Name;
|
||||
|
||||
return new DefinitionInfo() {
|
||||
FileName = fileName,
|
||||
Line = line.LineNumber
|
||||
};
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
private SymbolInfo GetMatchingSymbol(SymbolInfo symbol, int rangeStart, int rangeEnd)
|
||||
{
|
||||
foreach(int reference in symbol.References) {
|
||||
|
@ -118,6 +133,11 @@ namespace Mesen.GUI.Debugger
|
|||
return null;
|
||||
}
|
||||
|
||||
internal List<SymbolInfo> GetSymbols()
|
||||
{
|
||||
return _symbols.Values.ToList();
|
||||
}
|
||||
|
||||
internal SymbolInfo GetSymbol(string word, int prgStartAddress, int prgEndAddress)
|
||||
{
|
||||
try {
|
||||
|
@ -151,7 +171,14 @@ namespace Mesen.GUI.Debugger
|
|||
|
||||
SegmentInfo segment = _segments[symbol.SegmentID.Value];
|
||||
if(segment.IsRam) {
|
||||
return new AddressTypeInfo() { Address = symbol.Address.Value, Type = AddressType.Register };
|
||||
int labelAddress;
|
||||
AddressType? addressType;
|
||||
GetRamLabelAddressAndType(symbol.Address.Value, out labelAddress, out addressType);
|
||||
if(addressType.HasValue) {
|
||||
return new AddressTypeInfo() { Address = labelAddress, Type = addressType.Value };
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
} else {
|
||||
return new AddressTypeInfo() { Address = symbol.Address.Value - segment.Start + segment.FileOffset - _headerSize, Type = AddressType.PrgRom };
|
||||
}
|
||||
|
@ -297,23 +324,41 @@ namespace Mesen.GUI.Debugger
|
|||
return false;
|
||||
}
|
||||
|
||||
private void GetRamLabelAddressAndType(int address, out int absoluteAddress, out AddressType? addressType)
|
||||
{
|
||||
if(address < 0x2000) {
|
||||
absoluteAddress = address;
|
||||
addressType = AddressType.InternalRam;
|
||||
} else if(address >= _workRamStart && address <= _workRamEnd) {
|
||||
absoluteAddress = address - _workRamStart;
|
||||
addressType = AddressType.WorkRam;
|
||||
} else if(address >= _saveRamStart && address <= _saveRamEnd) {
|
||||
absoluteAddress = address - _saveRamStart;
|
||||
addressType = AddressType.SaveRam;
|
||||
} else {
|
||||
absoluteAddress = -1;
|
||||
addressType = null;
|
||||
}
|
||||
}
|
||||
|
||||
private CodeLabel CreateLabel(Int32 address, bool isRamLabel)
|
||||
{
|
||||
CodeLabel label = null;
|
||||
if(isRamLabel) {
|
||||
if(address < 0x2000) {
|
||||
if(!_ramLabels.TryGetValue(address, out label)) {
|
||||
label = new CodeLabel() { Address = (UInt32)address, AddressType = AddressType.InternalRam, Comment = string.Empty, Label = string.Empty };
|
||||
_ramLabels[address] = label;
|
||||
int labelAddress;
|
||||
AddressType? addressType;
|
||||
GetRamLabelAddressAndType(address, out labelAddress, out addressType);
|
||||
if(addressType == AddressType.InternalRam) {
|
||||
if(!_ramLabels.TryGetValue(labelAddress, out label)) {
|
||||
label = new CodeLabel() { Address = (UInt32)labelAddress, AddressType = AddressType.InternalRam, Comment = string.Empty, Label = string.Empty };
|
||||
_ramLabels[labelAddress] = label;
|
||||
}
|
||||
} else if(address >= _workRamStart && address <= _workRamEnd) {
|
||||
int labelAddress = address - _workRamStart;
|
||||
} else if(addressType == AddressType.WorkRam) {
|
||||
if(!_workRamLabels.TryGetValue(labelAddress, out label)) {
|
||||
label = new CodeLabel() { Address = (UInt32)labelAddress, AddressType = AddressType.WorkRam, Comment = string.Empty, Label = string.Empty };
|
||||
_workRamLabels[labelAddress] = label;
|
||||
}
|
||||
} else if(address >= _saveRamStart && address <= _saveRamEnd) {
|
||||
int labelAddress = address - _saveRamStart;
|
||||
} else if(addressType == AddressType.SaveRam) {
|
||||
if(!_saveRamLabels.TryGetValue(labelAddress, out label)) {
|
||||
label = new CodeLabel() { Address = (UInt32)labelAddress, AddressType = AddressType.SaveRam, Comment = string.Empty, Label = string.Empty };
|
||||
_saveRamLabels[labelAddress] = label;
|
||||
|
@ -646,5 +691,11 @@ namespace Mesen.GUI.Debugger
|
|||
public string Name;
|
||||
public int? SymbolID;
|
||||
}
|
||||
|
||||
public class DefinitionInfo
|
||||
{
|
||||
public string FileName;
|
||||
public int Line;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -40,6 +40,11 @@ namespace Mesen.GUI.Debugger
|
|||
{
|
||||
return InteropEmu.DebugGetRelativeAddress(this.Address, this.AddressType);
|
||||
}
|
||||
|
||||
public byte GetValue()
|
||||
{
|
||||
return InteropEmu.DebugGetMemoryValue(AddressType.ToMemoryType(), Address);
|
||||
}
|
||||
}
|
||||
|
||||
public class LabelManager
|
||||
|
|
|
@ -36,6 +36,7 @@ namespace Mesen.GUI.Debugger
|
|||
GetMember(nameof(DebuggerShortcutsConfig.MarkAsCode)),
|
||||
GetMember(nameof(DebuggerShortcutsConfig.MarkAsData)),
|
||||
GetMember(nameof(DebuggerShortcutsConfig.MarkAsUnidentified)),
|
||||
GetMember(nameof(DebuggerShortcutsConfig.GoToAll)),
|
||||
GetMember(nameof(DebuggerShortcutsConfig.CodeWindow_EditInMemoryViewer)),
|
||||
GetMember(nameof(DebuggerShortcutsConfig.MemoryViewer_ViewInDisassembly)),
|
||||
|
||||
|
|
72
GUI.NET/Debugger/frmDebugger.Designer.cs
generated
72
GUI.NET/Debugger/frmDebugger.Designer.cs
generated
|
@ -140,6 +140,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.toolStripMenuItem20 = new System.Windows.Forms.ToolStripSeparator();
|
||||
this.mnuBringToFrontOnBreak = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.mnuBringToFrontOnPause = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.toolStripMenuItem28 = new System.Windows.Forms.ToolStripSeparator();
|
||||
this.mnuEnableSubInstructionBreakpoints = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.toolStripMenuItem12 = new System.Windows.Forms.ToolStripSeparator();
|
||||
this.mnuShowOptions = new System.Windows.Forms.ToolStripMenuItem();
|
||||
|
@ -214,7 +215,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.ctrlPpuMemoryMapping = new Mesen.GUI.Debugger.Controls.ctrlMemoryMapping();
|
||||
this.ctrlCpuMemoryMapping = new Mesen.GUI.Debugger.Controls.ctrlMemoryMapping();
|
||||
this.tsToolbar = new Mesen.GUI.Controls.ctrlMesenToolStrip();
|
||||
this.toolStripMenuItem28 = new System.Windows.Forms.ToolStripSeparator();
|
||||
this.mnuGoToAll = new System.Windows.Forms.ToolStripMenuItem();
|
||||
((System.ComponentModel.ISupportInitialize)(this.splitContainer)).BeginInit();
|
||||
this.splitContainer.Panel1.SuspendLayout();
|
||||
this.splitContainer.Panel2.SuspendLayout();
|
||||
|
@ -259,7 +260,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.splitContainer.Panel2.Controls.Add(this.tableLayoutPanel10);
|
||||
this.splitContainer.Panel2MinSize = 100;
|
||||
this.splitContainer.Size = new System.Drawing.Size(1075, 570);
|
||||
this.splitContainer.SplitterDistance = 410;
|
||||
this.splitContainer.SplitterDistance = 407;
|
||||
this.splitContainer.SplitterWidth = 7;
|
||||
this.splitContainer.TabIndex = 1;
|
||||
this.splitContainer.TabStop = false;
|
||||
|
@ -283,7 +284,7 @@ namespace Mesen.GUI.Debugger
|
|||
//
|
||||
this.ctrlSplitContainerTop.Panel2.Controls.Add(this.tlpFunctionLabelLists);
|
||||
this.ctrlSplitContainerTop.Panel2MinSize = 150;
|
||||
this.ctrlSplitContainerTop.Size = new System.Drawing.Size(1075, 410);
|
||||
this.ctrlSplitContainerTop.Size = new System.Drawing.Size(1075, 407);
|
||||
this.ctrlSplitContainerTop.SplitterDistance = 750;
|
||||
this.ctrlSplitContainerTop.SplitterWidth = 7;
|
||||
this.ctrlSplitContainerTop.TabIndex = 3;
|
||||
|
@ -304,8 +305,8 @@ namespace Mesen.GUI.Debugger
|
|||
this.tlpTop.Name = "tlpTop";
|
||||
this.tlpTop.RowCount = 1;
|
||||
this.tlpTop.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||
this.tlpTop.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 410F));
|
||||
this.tlpTop.Size = new System.Drawing.Size(750, 410);
|
||||
this.tlpTop.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 407F));
|
||||
this.tlpTop.Size = new System.Drawing.Size(750, 407);
|
||||
this.tlpTop.TabIndex = 2;
|
||||
//
|
||||
// panel1
|
||||
|
@ -316,7 +317,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.panel1.Location = new System.Drawing.Point(3, 0);
|
||||
this.panel1.Margin = new System.Windows.Forms.Padding(3, 0, 3, 0);
|
||||
this.panel1.Name = "panel1";
|
||||
this.panel1.Size = new System.Drawing.Size(286, 410);
|
||||
this.panel1.Size = new System.Drawing.Size(286, 407);
|
||||
this.panel1.TabIndex = 5;
|
||||
//
|
||||
// ctrlSourceViewer
|
||||
|
@ -325,7 +326,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.ctrlSourceViewer.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.ctrlSourceViewer.Location = new System.Drawing.Point(0, 0);
|
||||
this.ctrlSourceViewer.Name = "ctrlSourceViewer";
|
||||
this.ctrlSourceViewer.Size = new System.Drawing.Size(286, 410);
|
||||
this.ctrlSourceViewer.Size = new System.Drawing.Size(286, 407);
|
||||
this.ctrlSourceViewer.SymbolProvider = null;
|
||||
this.ctrlSourceViewer.TabIndex = 7;
|
||||
this.ctrlSourceViewer.Visible = false;
|
||||
|
@ -338,7 +339,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.ctrlDebuggerCode.Location = new System.Drawing.Point(0, 0);
|
||||
this.ctrlDebuggerCode.Name = "ctrlDebuggerCode";
|
||||
this.ctrlDebuggerCode.ShowMemoryValues = false;
|
||||
this.ctrlDebuggerCode.Size = new System.Drawing.Size(286, 410);
|
||||
this.ctrlDebuggerCode.Size = new System.Drawing.Size(286, 407);
|
||||
this.ctrlDebuggerCode.SymbolProvider = null;
|
||||
this.ctrlDebuggerCode.TabIndex = 2;
|
||||
this.ctrlDebuggerCode.OnEditCode += new Mesen.GUI.Debugger.ctrlDebuggerCode.AssemblerEventHandler(this.ctrlDebuggerCode_OnEditCode);
|
||||
|
@ -352,7 +353,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.panel2.Location = new System.Drawing.Point(292, 0);
|
||||
this.panel2.Margin = new System.Windows.Forms.Padding(0, 0, 3, 0);
|
||||
this.panel2.Name = "panel2";
|
||||
this.panel2.Size = new System.Drawing.Size(1, 410);
|
||||
this.panel2.Size = new System.Drawing.Size(1, 407);
|
||||
this.panel2.TabIndex = 6;
|
||||
//
|
||||
// ctrlSourceViewerSplit
|
||||
|
@ -361,7 +362,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.ctrlSourceViewerSplit.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.ctrlSourceViewerSplit.Location = new System.Drawing.Point(0, 0);
|
||||
this.ctrlSourceViewerSplit.Name = "ctrlSourceViewerSplit";
|
||||
this.ctrlSourceViewerSplit.Size = new System.Drawing.Size(1, 410);
|
||||
this.ctrlSourceViewerSplit.Size = new System.Drawing.Size(1, 407);
|
||||
this.ctrlSourceViewerSplit.SymbolProvider = null;
|
||||
this.ctrlSourceViewerSplit.TabIndex = 8;
|
||||
this.ctrlSourceViewerSplit.Visible = false;
|
||||
|
@ -374,7 +375,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.ctrlDebuggerCodeSplit.Location = new System.Drawing.Point(0, 0);
|
||||
this.ctrlDebuggerCodeSplit.Name = "ctrlDebuggerCodeSplit";
|
||||
this.ctrlDebuggerCodeSplit.ShowMemoryValues = false;
|
||||
this.ctrlDebuggerCodeSplit.Size = new System.Drawing.Size(1, 410);
|
||||
this.ctrlDebuggerCodeSplit.Size = new System.Drawing.Size(1, 407);
|
||||
this.ctrlDebuggerCodeSplit.SymbolProvider = null;
|
||||
this.ctrlDebuggerCodeSplit.TabIndex = 4;
|
||||
this.ctrlDebuggerCodeSplit.Visible = false;
|
||||
|
@ -394,7 +395,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.tableLayoutPanel1.RowCount = 2;
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle());
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||
this.tableLayoutPanel1.Size = new System.Drawing.Size(458, 410);
|
||||
this.tableLayoutPanel1.Size = new System.Drawing.Size(458, 407);
|
||||
this.tableLayoutPanel1.TabIndex = 7;
|
||||
//
|
||||
// ctrlConsoleStatus
|
||||
|
@ -418,7 +419,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.tlpVerticalLayout.Name = "tlpVerticalLayout";
|
||||
this.tlpVerticalLayout.RowCount = 1;
|
||||
this.tlpVerticalLayout.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tlpVerticalLayout.Size = new System.Drawing.Size(458, 10);
|
||||
this.tlpVerticalLayout.Size = new System.Drawing.Size(458, 7);
|
||||
this.tlpVerticalLayout.TabIndex = 4;
|
||||
//
|
||||
// tlpFunctionLabelLists
|
||||
|
@ -434,16 +435,16 @@ namespace Mesen.GUI.Debugger
|
|||
this.tlpFunctionLabelLists.RowCount = 2;
|
||||
this.tlpFunctionLabelLists.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tlpFunctionLabelLists.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tlpFunctionLabelLists.Size = new System.Drawing.Size(318, 410);
|
||||
this.tlpFunctionLabelLists.Size = new System.Drawing.Size(318, 407);
|
||||
this.tlpFunctionLabelLists.TabIndex = 5;
|
||||
//
|
||||
// grpLabels
|
||||
//
|
||||
this.grpLabels.Controls.Add(this.ctrlLabelList);
|
||||
this.grpLabels.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.grpLabels.Location = new System.Drawing.Point(3, 208);
|
||||
this.grpLabels.Location = new System.Drawing.Point(3, 206);
|
||||
this.grpLabels.Name = "grpLabels";
|
||||
this.grpLabels.Size = new System.Drawing.Size(312, 199);
|
||||
this.grpLabels.Size = new System.Drawing.Size(312, 198);
|
||||
this.grpLabels.TabIndex = 6;
|
||||
this.grpLabels.TabStop = false;
|
||||
this.grpLabels.Text = "Labels";
|
||||
|
@ -453,7 +454,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.ctrlLabelList.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.ctrlLabelList.Location = new System.Drawing.Point(3, 16);
|
||||
this.ctrlLabelList.Name = "ctrlLabelList";
|
||||
this.ctrlLabelList.Size = new System.Drawing.Size(306, 180);
|
||||
this.ctrlLabelList.Size = new System.Drawing.Size(306, 179);
|
||||
this.ctrlLabelList.TabIndex = 0;
|
||||
this.ctrlLabelList.OnFindOccurrence += new System.EventHandler(this.ctrlLabelList_OnFindOccurrence);
|
||||
this.ctrlLabelList.OnLabelSelected += new System.EventHandler(this.ctrlLabelList_OnLabelSelected);
|
||||
|
@ -464,7 +465,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.grpFunctions.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.grpFunctions.Location = new System.Drawing.Point(3, 3);
|
||||
this.grpFunctions.Name = "grpFunctions";
|
||||
this.grpFunctions.Size = new System.Drawing.Size(312, 199);
|
||||
this.grpFunctions.Size = new System.Drawing.Size(312, 197);
|
||||
this.grpFunctions.TabIndex = 5;
|
||||
this.grpFunctions.TabStop = false;
|
||||
this.grpFunctions.Text = "Functions";
|
||||
|
@ -474,7 +475,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.ctrlFunctionList.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.ctrlFunctionList.Location = new System.Drawing.Point(3, 16);
|
||||
this.ctrlFunctionList.Name = "ctrlFunctionList";
|
||||
this.ctrlFunctionList.Size = new System.Drawing.Size(306, 180);
|
||||
this.ctrlFunctionList.Size = new System.Drawing.Size(306, 178);
|
||||
this.ctrlFunctionList.TabIndex = 0;
|
||||
this.ctrlFunctionList.OnFindOccurrence += new System.EventHandler(this.ctrlFunctionList_OnFindOccurrence);
|
||||
this.ctrlFunctionList.OnFunctionSelected += new System.EventHandler(this.ctrlFunctionList_OnFunctionSelected);
|
||||
|
@ -505,7 +506,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.tableLayoutPanel10.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||
this.tableLayoutPanel10.RowStyles.Add(new System.Windows.Forms.RowStyle());
|
||||
this.tableLayoutPanel10.RowStyles.Add(new System.Windows.Forms.RowStyle());
|
||||
this.tableLayoutPanel10.Size = new System.Drawing.Size(1075, 153);
|
||||
this.tableLayoutPanel10.Size = new System.Drawing.Size(1075, 156);
|
||||
this.tableLayoutPanel10.TabIndex = 0;
|
||||
//
|
||||
// grpWatch
|
||||
|
@ -514,7 +515,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.grpWatch.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.grpWatch.Location = new System.Drawing.Point(3, 3);
|
||||
this.grpWatch.Name = "grpWatch";
|
||||
this.grpWatch.Size = new System.Drawing.Size(352, 147);
|
||||
this.grpWatch.Size = new System.Drawing.Size(352, 150);
|
||||
this.grpWatch.TabIndex = 2;
|
||||
this.grpWatch.TabStop = false;
|
||||
this.grpWatch.Text = "Watch";
|
||||
|
@ -524,7 +525,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.ctrlWatch.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.ctrlWatch.Location = new System.Drawing.Point(3, 16);
|
||||
this.ctrlWatch.Name = "ctrlWatch";
|
||||
this.ctrlWatch.Size = new System.Drawing.Size(346, 128);
|
||||
this.ctrlWatch.Size = new System.Drawing.Size(346, 131);
|
||||
this.ctrlWatch.TabIndex = 0;
|
||||
//
|
||||
// grpBreakpoints
|
||||
|
@ -533,7 +534,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.grpBreakpoints.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.grpBreakpoints.Location = new System.Drawing.Point(361, 3);
|
||||
this.grpBreakpoints.Name = "grpBreakpoints";
|
||||
this.grpBreakpoints.Size = new System.Drawing.Size(352, 147);
|
||||
this.grpBreakpoints.Size = new System.Drawing.Size(352, 150);
|
||||
this.grpBreakpoints.TabIndex = 3;
|
||||
this.grpBreakpoints.TabStop = false;
|
||||
this.grpBreakpoints.Text = "Breakpoints";
|
||||
|
@ -543,7 +544,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.ctrlBreakpoints.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.ctrlBreakpoints.Location = new System.Drawing.Point(3, 16);
|
||||
this.ctrlBreakpoints.Name = "ctrlBreakpoints";
|
||||
this.ctrlBreakpoints.Size = new System.Drawing.Size(346, 128);
|
||||
this.ctrlBreakpoints.Size = new System.Drawing.Size(346, 131);
|
||||
this.ctrlBreakpoints.TabIndex = 0;
|
||||
this.ctrlBreakpoints.BreakpointNavigation += new System.EventHandler(this.ctrlBreakpoints_BreakpointNavigation);
|
||||
//
|
||||
|
@ -553,7 +554,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.grpCallstack.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.grpCallstack.Location = new System.Drawing.Point(719, 3);
|
||||
this.grpCallstack.Name = "grpCallstack";
|
||||
this.grpCallstack.Size = new System.Drawing.Size(353, 147);
|
||||
this.grpCallstack.Size = new System.Drawing.Size(353, 150);
|
||||
this.grpCallstack.TabIndex = 4;
|
||||
this.grpCallstack.TabStop = false;
|
||||
this.grpCallstack.Text = "Call Stack";
|
||||
|
@ -563,7 +564,7 @@ namespace Mesen.GUI.Debugger
|
|||
this.ctrlCallstack.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.ctrlCallstack.Location = new System.Drawing.Point(3, 16);
|
||||
this.ctrlCallstack.Name = "ctrlCallstack";
|
||||
this.ctrlCallstack.Size = new System.Drawing.Size(347, 128);
|
||||
this.ctrlCallstack.Size = new System.Drawing.Size(347, 131);
|
||||
this.ctrlCallstack.TabIndex = 0;
|
||||
this.ctrlCallstack.FunctionSelected += new System.EventHandler(this.ctrlCallstack_FunctionSelected);
|
||||
//
|
||||
|
@ -918,7 +919,8 @@ namespace Mesen.GUI.Debugger
|
|||
this.mnuFindPrev,
|
||||
this.toolStripMenuItem9,
|
||||
this.mnuFindAllOccurrences,
|
||||
this.mnuGoTo});
|
||||
this.mnuGoTo,
|
||||
this.mnuGoToAll});
|
||||
this.searchToolStripMenuItem.Name = "searchToolStripMenuItem";
|
||||
this.searchToolStripMenuItem.Size = new System.Drawing.Size(54, 20);
|
||||
this.searchToolStripMenuItem.Text = "Search";
|
||||
|
@ -1307,7 +1309,12 @@ namespace Mesen.GUI.Debugger
|
|||
this.mnuBringToFrontOnPause.Text = "Bring debugger to front on pause";
|
||||
this.mnuBringToFrontOnPause.Click += new System.EventHandler(this.mnuBringToFrontOnPause_Click);
|
||||
//
|
||||
// mnuBreakOnFirstCycle
|
||||
// toolStripMenuItem28
|
||||
//
|
||||
this.toolStripMenuItem28.Name = "toolStripMenuItem28";
|
||||
this.toolStripMenuItem28.Size = new System.Drawing.Size(258, 6);
|
||||
//
|
||||
// mnuEnableSubInstructionBreakpoints
|
||||
//
|
||||
this.mnuEnableSubInstructionBreakpoints.CheckOnClick = true;
|
||||
this.mnuEnableSubInstructionBreakpoints.Name = "mnuEnableSubInstructionBreakpoints";
|
||||
|
@ -1899,10 +1906,12 @@ namespace Mesen.GUI.Debugger
|
|||
this.tsToolbar.Text = "toolStrip1";
|
||||
this.tsToolbar.Visible = false;
|
||||
//
|
||||
// toolStripMenuItem28
|
||||
// mnuGoToAll
|
||||
//
|
||||
this.toolStripMenuItem28.Name = "toolStripMenuItem28";
|
||||
this.toolStripMenuItem28.Size = new System.Drawing.Size(258, 6);
|
||||
this.mnuGoToAll.Name = "mnuGoToAll";
|
||||
this.mnuGoToAll.Size = new System.Drawing.Size(183, 22);
|
||||
this.mnuGoToAll.Text = "Go to All";
|
||||
this.mnuGoToAll.Click += new System.EventHandler(this.mnuGoToAll_Click);
|
||||
//
|
||||
// frmDebugger
|
||||
//
|
||||
|
@ -2139,5 +2148,6 @@ namespace Mesen.GUI.Debugger
|
|||
private System.Windows.Forms.ToolStripSeparator toolStripMenuItem27;
|
||||
private System.Windows.Forms.ToolStripMenuItem mnuEnableSubInstructionBreakpoints;
|
||||
private System.Windows.Forms.ToolStripSeparator toolStripMenuItem28;
|
||||
private System.Windows.Forms.ToolStripMenuItem mnuGoToAll;
|
||||
}
|
||||
}
|
|
@ -261,6 +261,7 @@ namespace Mesen.GUI.Debugger
|
|||
mnuRunScanline.InitShortcut(this, nameof(DebuggerShortcutsConfig.RunPpuScanline));
|
||||
mnuRunOneFrame.InitShortcut(this, nameof(DebuggerShortcutsConfig.RunPpuFrame));
|
||||
|
||||
mnuGoToAll.InitShortcut(this, nameof(DebuggerShortcutsConfig.GoToAll));
|
||||
mnuGoToAddress.InitShortcut(this, nameof(DebuggerShortcutsConfig.GoTo));
|
||||
mnuFind.InitShortcut(this, nameof(DebuggerShortcutsConfig.Find));
|
||||
mnuFindNext.InitShortcut(this, nameof(DebuggerShortcutsConfig.FindNext));
|
||||
|
@ -1798,5 +1799,40 @@ namespace Mesen.GUI.Debugger
|
|||
MesenMsgBox.Show("UnexpectedError", MessageBoxButtons.OK, MessageBoxIcon.Error, ex.ToString());
|
||||
}
|
||||
}
|
||||
|
||||
private void mnuGoToAll_Click(object sender, EventArgs e)
|
||||
{
|
||||
using(frmGoToAll frm = new frmGoToAll(_lastCodeWindow.SymbolProvider)) {
|
||||
if(frm.ShowDialog() == DialogResult.OK) {
|
||||
frmGoToAll.GoToDestination dest = frm.Destination;
|
||||
|
||||
if(_lastCodeWindow is ctrlSourceViewer && !string.IsNullOrWhiteSpace(dest.File)) {
|
||||
((ctrlSourceViewer)_lastCodeWindow).ScrollToFileLine(dest.File, dest.Line);
|
||||
} else if(dest.Label != null && dest.Label.GetRelativeAddress() >= 0) {
|
||||
_lastCodeWindow.ScrollToAddress(new AddressTypeInfo() { Address = (int)dest.Label.Address, Type = dest.Label.AddressType });
|
||||
} else if(!string.IsNullOrWhiteSpace(dest.File)) {
|
||||
if(!(_lastCodeWindow is ctrlSourceViewer)) {
|
||||
ctrlDebuggerCode_OnSwitchView(_lastCodeWindow);
|
||||
}
|
||||
if(_lastCodeWindow is ctrlSourceViewer) {
|
||||
((ctrlSourceViewer)_lastCodeWindow).ScrollToFileLine(dest.File, dest.Line);
|
||||
}
|
||||
}
|
||||
|
||||
if(Program.IsMono) {
|
||||
//Delay by 150ms before giving focus when running on Mono
|
||||
//Otherwise this doesn't work (presumably because Mono sets the debugger form to disabled while the popup is opened)
|
||||
Task.Run(() => {
|
||||
System.Threading.Thread.Sleep(150);
|
||||
this.BeginInvoke((Action)(() => {
|
||||
_lastCodeWindow.CodeViewer.Focus();
|
||||
}));
|
||||
});
|
||||
} else {
|
||||
_lastCodeWindow.CodeViewer.Focus();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -121,12 +121,12 @@
|
|||
<value>17, 17</value>
|
||||
</metadata>
|
||||
<metadata name="menuStrip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>107, 17</value>
|
||||
<value>17, 56</value>
|
||||
</metadata>
|
||||
<metadata name="statusStrip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>215, 17</value>
|
||||
<value>17, 95</value>
|
||||
</metadata>
|
||||
<metadata name="tsToolbar.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>324, 17</value>
|
||||
<value>17, 134</value>
|
||||
</metadata>
|
||||
</root>
|
125
GUI.NET/Debugger/frmGoToAll.Designer.cs
generated
Normal file
125
GUI.NET/Debugger/frmGoToAll.Designer.cs
generated
Normal file
|
@ -0,0 +1,125 @@
|
|||
namespace Mesen.GUI.Debugger
|
||||
{
|
||||
partial class frmGoToAll
|
||||
{
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if(disposing && (components != null)) {
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Windows Form Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.lblSearch = new System.Windows.Forms.Label();
|
||||
this.txtSearch = new System.Windows.Forms.TextBox();
|
||||
this.pnlResults = new System.Windows.Forms.Panel();
|
||||
this.tlpResults = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.tableLayoutPanel1.SuspendLayout();
|
||||
this.pnlResults.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// tableLayoutPanel1
|
||||
//
|
||||
this.tableLayoutPanel1.ColumnCount = 2;
|
||||
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle());
|
||||
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||
this.tableLayoutPanel1.Controls.Add(this.lblSearch, 0, 0);
|
||||
this.tableLayoutPanel1.Controls.Add(this.txtSearch, 1, 0);
|
||||
this.tableLayoutPanel1.Controls.Add(this.pnlResults, 0, 1);
|
||||
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
|
||||
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||
this.tableLayoutPanel1.RowCount = 2;
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle());
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||
this.tableLayoutPanel1.Size = new System.Drawing.Size(386, 421);
|
||||
this.tableLayoutPanel1.TabIndex = 0;
|
||||
//
|
||||
// lblSearch
|
||||
//
|
||||
this.lblSearch.Anchor = System.Windows.Forms.AnchorStyles.Left;
|
||||
this.lblSearch.AutoSize = true;
|
||||
this.lblSearch.Location = new System.Drawing.Point(3, 6);
|
||||
this.lblSearch.Name = "lblSearch";
|
||||
this.lblSearch.Size = new System.Drawing.Size(44, 13);
|
||||
this.lblSearch.TabIndex = 0;
|
||||
this.lblSearch.Text = "Search:";
|
||||
//
|
||||
// txtSearch
|
||||
//
|
||||
this.txtSearch.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.txtSearch.Location = new System.Drawing.Point(53, 3);
|
||||
this.txtSearch.Name = "txtSearch";
|
||||
this.txtSearch.Size = new System.Drawing.Size(330, 20);
|
||||
this.txtSearch.TabIndex = 1;
|
||||
this.txtSearch.TextChanged += new System.EventHandler(this.txtSearch_TextChanged);
|
||||
//
|
||||
// pnlResults
|
||||
//
|
||||
this.pnlResults.AutoScroll = true;
|
||||
this.pnlResults.BackColor = System.Drawing.SystemColors.ControlDarkDark;
|
||||
this.pnlResults.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
|
||||
this.tableLayoutPanel1.SetColumnSpan(this.pnlResults, 2);
|
||||
this.pnlResults.Controls.Add(this.tlpResults);
|
||||
this.pnlResults.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.pnlResults.Location = new System.Drawing.Point(3, 29);
|
||||
this.pnlResults.Name = "pnlResults";
|
||||
this.pnlResults.Size = new System.Drawing.Size(380, 389);
|
||||
this.pnlResults.TabIndex = 2;
|
||||
//
|
||||
// tlpResults
|
||||
//
|
||||
this.tlpResults.BackColor = System.Drawing.Color.Transparent;
|
||||
this.tlpResults.ColumnCount = 1;
|
||||
this.tlpResults.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||
this.tlpResults.Location = new System.Drawing.Point(0, 0);
|
||||
this.tlpResults.Name = "tlpResults";
|
||||
this.tlpResults.RowCount = 1;
|
||||
this.tlpResults.RowStyles.Add(new System.Windows.Forms.RowStyle());
|
||||
this.tlpResults.Size = new System.Drawing.Size(361, 457);
|
||||
this.tlpResults.TabIndex = 0;
|
||||
//
|
||||
// frmGoToAll
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(386, 421);
|
||||
this.Controls.Add(this.tableLayoutPanel1);
|
||||
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWindow;
|
||||
this.Name = "frmGoToAll";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
|
||||
this.Text = "Go to All";
|
||||
this.tableLayoutPanel1.ResumeLayout(false);
|
||||
this.tableLayoutPanel1.PerformLayout();
|
||||
this.pnlResults.ResumeLayout(false);
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||
private System.Windows.Forms.Label lblSearch;
|
||||
private System.Windows.Forms.TextBox txtSearch;
|
||||
private System.Windows.Forms.Panel pnlResults;
|
||||
private System.Windows.Forms.TableLayoutPanel tlpResults;
|
||||
}
|
||||
}
|
293
GUI.NET/Debugger/frmGoToAll.cs
Normal file
293
GUI.NET/Debugger/frmGoToAll.cs
Normal file
|
@ -0,0 +1,293 @@
|
|||
using Mesen.GUI.Debugger.Controls;
|
||||
using Mesen.GUI.Forms;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace Mesen.GUI.Debugger
|
||||
{
|
||||
public partial class frmGoToAll : BaseForm
|
||||
{
|
||||
private const int MaxResultCount = 30;
|
||||
|
||||
private List<ctrlSearchResult> _results = new List<ctrlSearchResult>();
|
||||
private int _selectedResult = 0;
|
||||
private int _resultCount = 0;
|
||||
private Ld65DbgImporter _symbolProvider;
|
||||
|
||||
public GoToDestination Destination { get; private set; }
|
||||
|
||||
public frmGoToAll(Ld65DbgImporter symbolProvider = null)
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
_symbolProvider = symbolProvider;
|
||||
|
||||
tlpResults.SuspendLayout();
|
||||
for(int i = 0; i < MaxResultCount; i++) {
|
||||
ctrlSearchResult searchResult = new ctrlSearchResult();
|
||||
searchResult.Dock = DockStyle.Top;
|
||||
searchResult.BackColor = i % 2 == 0 ? SystemColors.ControlLight : SystemColors.ControlLightLight;
|
||||
searchResult.Visible = false;
|
||||
searchResult.Click += SearchResult_Click;
|
||||
searchResult.DoubleClick += SearchResult_DoubleClick;
|
||||
tlpResults.Controls.Add(searchResult, 0, i);
|
||||
tlpResults.RowStyles.Add(new RowStyle(SizeType.AutoSize));
|
||||
|
||||
_results.Add(searchResult);
|
||||
}
|
||||
tlpResults.ResumeLayout();
|
||||
|
||||
UpdateResults();
|
||||
}
|
||||
|
||||
private void SearchResult_Click(object sender, EventArgs e)
|
||||
{
|
||||
SelectedResult = _results.IndexOf(sender as ctrlSearchResult);
|
||||
}
|
||||
|
||||
private void SearchResult_DoubleClick(object sender, EventArgs e)
|
||||
{
|
||||
SelectedResult = _results.IndexOf(sender as ctrlSearchResult);
|
||||
SelectAndClose();
|
||||
}
|
||||
|
||||
protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
|
||||
{
|
||||
if(keyData == Keys.Up) {
|
||||
SelectedResult--;
|
||||
return true;
|
||||
} else if(keyData == Keys.Down) {
|
||||
SelectedResult++;
|
||||
return true;
|
||||
} else if(keyData == Keys.PageUp) {
|
||||
SelectedResult -= pnlResults.ClientSize.Height / _results[0].Height;
|
||||
return true;
|
||||
} else if(keyData == Keys.PageDown) {
|
||||
SelectedResult += pnlResults.ClientSize.Height / _results[0].Height;
|
||||
return true;
|
||||
} else if(keyData == Keys.Enter) {
|
||||
SelectAndClose();
|
||||
} else if(keyData == Keys.Escape) {
|
||||
Close();
|
||||
}
|
||||
|
||||
return base.ProcessCmdKey(ref msg, keyData);
|
||||
}
|
||||
|
||||
private int SelectedResult
|
||||
{
|
||||
get { return _selectedResult; }
|
||||
set
|
||||
{
|
||||
//Reset currently highlighted element's color
|
||||
_results[_selectedResult].BackColor = _selectedResult % 2 == 0 ? SystemColors.ControlLight : SystemColors.ControlLightLight;
|
||||
|
||||
_selectedResult = Math.Max(0, Math.Min(_resultCount - 1, value));
|
||||
if(_resultCount == 0) {
|
||||
_results[0].BackColor = SystemColors.ControlLight;
|
||||
} else {
|
||||
_results[_selectedResult].BackColor = Color.LightBlue;
|
||||
}
|
||||
|
||||
if(_resultCount > 0) {
|
||||
if(Program.IsMono) {
|
||||
//Use this logic to replace ScrollControlIntoView (which doesn't work properly on Mono)
|
||||
int startPos = (_results[0].Height + 1) * _selectedResult;
|
||||
int endPos = startPos + _results[0].Height + 1;
|
||||
|
||||
int minVisiblePos = pnlResults.VerticalScroll.Value;
|
||||
int maxVisiblePos = pnlResults.Height + pnlResults.VerticalScroll.Value;
|
||||
|
||||
if(startPos < minVisiblePos) {
|
||||
pnlResults.VerticalScroll.Value = startPos;
|
||||
} else if(endPos > maxVisiblePos) {
|
||||
pnlResults.VerticalScroll.Value = endPos - pnlResults.Height;
|
||||
}
|
||||
} else {
|
||||
pnlResults.ScrollControlIntoView(_results[_selectedResult]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void UpdateResults()
|
||||
{
|
||||
string searchString = txtSearch.Text.ToLower();
|
||||
_resultCount = 0;
|
||||
|
||||
HashSet<int> entryPoints = new HashSet<int>(InteropEmu.DebugGetFunctionEntryPoints());
|
||||
bool[] isJumpTargets = InteropEmu.DebugGetJumpTargets();
|
||||
|
||||
List<SearchResultInfo> searchResults = new List<SearchResultInfo>();
|
||||
|
||||
if(!string.IsNullOrWhiteSpace(searchString)) {
|
||||
if(_symbolProvider != null) {
|
||||
foreach(Ld65DbgImporter.FileInfo file in _symbolProvider.Files.Values) {
|
||||
if(file.Name.ToLower().Contains(searchString)) {
|
||||
searchResults.Add(new SearchResultInfo() {
|
||||
Caption = Path.GetFileName(file.Name),
|
||||
AbsoluteAddress = -1,
|
||||
MemoryType = AddressType.InternalRam,
|
||||
SearchResultType = SearchResultType.File,
|
||||
Filename = file.Name,
|
||||
FileLineNumber = 0,
|
||||
RelativeAddress = -1,
|
||||
CodeLabel = null
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
foreach(Ld65DbgImporter.SymbolInfo symbol in _symbolProvider.GetSymbols()) {
|
||||
if(symbol.Name.ToLower().Contains(searchString)) {
|
||||
Ld65DbgImporter.DefinitionInfo def = _symbolProvider.GetSymbolDefinition(symbol);
|
||||
AddressTypeInfo addressInfo = _symbolProvider.GetSymbolAddressInfo(symbol);
|
||||
int value = 0;
|
||||
int relAddress = -1;
|
||||
bool isConstant = addressInfo == null;
|
||||
if(addressInfo != null) {
|
||||
value = InteropEmu.DebugGetMemoryValue(addressInfo.Type.ToMemoryType(), (uint)addressInfo.Address);
|
||||
relAddress = InteropEmu.DebugGetRelativeAddress((uint)addressInfo.Address, addressInfo.Type);
|
||||
} else {
|
||||
//For constants, the address field contains the constant's value
|
||||
value = symbol.Address ?? 0;
|
||||
}
|
||||
|
||||
SearchResultType resultType = SearchResultType.Data;
|
||||
if(addressInfo?.Type == AddressType.PrgRom && entryPoints.Contains(addressInfo.Address)) {
|
||||
resultType = SearchResultType.Function;
|
||||
} else if(addressInfo?.Type == AddressType.PrgRom && addressInfo.Address < isJumpTargets.Length && isJumpTargets[addressInfo.Address]) {
|
||||
resultType = SearchResultType.JumpTarget;
|
||||
} else if(isConstant) {
|
||||
resultType = SearchResultType.Constant;
|
||||
}
|
||||
|
||||
searchResults.Add(new SearchResultInfo() {
|
||||
Caption = symbol.Name,
|
||||
AbsoluteAddress = addressInfo?.Address ?? -1,
|
||||
MemoryType = addressInfo?.Type ?? AddressType.InternalRam,
|
||||
SearchResultType = resultType,
|
||||
Value = value,
|
||||
Filename = def?.FileName ?? "",
|
||||
FileLineNumber = def?.Line ?? 0,
|
||||
RelativeAddress = relAddress,
|
||||
CodeLabel = LabelManager.GetLabel(symbol.Name)
|
||||
});
|
||||
}
|
||||
}
|
||||
} else {
|
||||
foreach(CodeLabel label in LabelManager.GetLabels()) {
|
||||
if(label.Label.ToLower().Contains(searchString)) {
|
||||
SearchResultType resultType = SearchResultType.Data;
|
||||
if(label.AddressType == AddressType.PrgRom && entryPoints.Contains((int)label.Address)) {
|
||||
resultType = SearchResultType.Function;
|
||||
} else if(label.AddressType == AddressType.PrgRom && label.Address < isJumpTargets.Length && isJumpTargets[label.Address]) {
|
||||
resultType = SearchResultType.JumpTarget;
|
||||
}
|
||||
|
||||
int relativeAddress = label.GetRelativeAddress();
|
||||
|
||||
searchResults.Add(new SearchResultInfo() {
|
||||
Caption = label.Label,
|
||||
AbsoluteAddress = (int)label.Address,
|
||||
Value = label.GetValue(),
|
||||
MemoryType = label.AddressType,
|
||||
SearchResultType = resultType,
|
||||
Filename = "",
|
||||
Disabled = relativeAddress < 0,
|
||||
RelativeAddress = relativeAddress,
|
||||
CodeLabel = label
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
searchResults.Sort((SearchResultInfo a, SearchResultInfo b) => {
|
||||
int comparison = a.Disabled.CompareTo(b.Disabled);
|
||||
|
||||
if(comparison == 0) {
|
||||
bool aStartsWithSearch = a.Caption.StartsWith(searchString, StringComparison.InvariantCultureIgnoreCase);
|
||||
bool bStartsWithSearch = b.Caption.StartsWith(searchString, StringComparison.InvariantCultureIgnoreCase);
|
||||
|
||||
comparison = bStartsWithSearch.CompareTo(aStartsWithSearch);
|
||||
if(comparison == 0) {
|
||||
comparison = a.Caption.CompareTo(b.Caption);
|
||||
}
|
||||
}
|
||||
return comparison;
|
||||
});
|
||||
|
||||
_resultCount = Math.Min(searchResults.Count, MaxResultCount);
|
||||
SelectedResult = 0;
|
||||
|
||||
if(searchResults.Count == 0) {
|
||||
searchResults.Add(new SearchResultInfo() { Caption = "No results found.", AbsoluteAddress = -1 });
|
||||
pnlResults.BackColor = SystemColors.ControlLight;
|
||||
} else {
|
||||
pnlResults.BackColor = SystemColors.ControlDarkDark;
|
||||
}
|
||||
|
||||
if(Program.IsMono) {
|
||||
pnlResults.Visible = false;
|
||||
} else {
|
||||
//Suspend layout causes a crash on Mono
|
||||
tlpResults.SuspendLayout();
|
||||
}
|
||||
|
||||
for(int i = 0; i < _resultCount; i++) {
|
||||
_results[i].Initialize(searchResults[i]);
|
||||
_results[i].Tag = searchResults[i];
|
||||
_results[i].Visible = true;
|
||||
}
|
||||
|
||||
for(int i = searchResults.Count; i < MaxResultCount; i++) {
|
||||
_results[i].Visible = false;
|
||||
}
|
||||
|
||||
pnlResults.VerticalScroll.Value = 0;
|
||||
tlpResults.Height = (_results[0].Height + 1) * _resultCount;
|
||||
|
||||
pnlResults.ResumeLayout();
|
||||
if(Program.IsMono) {
|
||||
pnlResults.Visible = true;
|
||||
tlpResults.Width = pnlResults.ClientSize.Width - 17;
|
||||
} else {
|
||||
tlpResults.ResumeLayout();
|
||||
tlpResults.Width = pnlResults.ClientSize.Width - 1;
|
||||
}
|
||||
}
|
||||
|
||||
private void txtSearch_TextChanged(object sender, EventArgs e)
|
||||
{
|
||||
UpdateResults();
|
||||
}
|
||||
|
||||
private void SelectAndClose()
|
||||
{
|
||||
if(_resultCount > 0) {
|
||||
SearchResultInfo searchResult = _results[_selectedResult].Tag as SearchResultInfo;
|
||||
if(!searchResult.Disabled) {
|
||||
Destination = new GoToDestination() { Label = searchResult.CodeLabel, File = searchResult.Filename, Line = searchResult.FileLineNumber };
|
||||
DialogResult = DialogResult.OK;
|
||||
Close();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public struct GoToDestination
|
||||
{
|
||||
public CodeLabel Label;
|
||||
public int CpuAddress;
|
||||
public string File;
|
||||
public int Line;
|
||||
}
|
||||
}
|
||||
}
|
123
GUI.NET/Debugger/frmGoToAll.resx
Normal file
123
GUI.NET/Debugger/frmGoToAll.resx
Normal file
|
@ -0,0 +1,123 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<metadata name="toolTip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
</root>
|
|
@ -466,6 +466,12 @@
|
|||
<Compile Include="Debugger\Controls\ctrlScanlineCycleSelect.Designer.cs">
|
||||
<DependentUpon>ctrlScanlineCycleSelect.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Debugger\Controls\ctrlSearchResult.cs">
|
||||
<SubType>UserControl</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Debugger\Controls\ctrlSearchResult.Designer.cs">
|
||||
<DependentUpon>ctrlSearchResult.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Debugger\Controls\ctrlTextHooker.cs">
|
||||
<SubType>UserControl</SubType>
|
||||
</Compile>
|
||||
|
@ -545,7 +551,9 @@
|
|||
<Compile Include="Debugger\Controls\ApuViewer\ctrlSquareInfo.Designer.cs">
|
||||
<DependentUpon>ctrlSquareInfo.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Debugger\Controls\ctrlTextbox.cs" />
|
||||
<Compile Include="Debugger\Controls\ctrlTextbox.cs">
|
||||
<SubType>Component</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Debugger\Controls\ctrlTextbox.Designer.cs">
|
||||
<DependentUpon>ctrlTextbox.cs</DependentUpon>
|
||||
</Compile>
|
||||
|
@ -653,6 +661,12 @@
|
|||
<Compile Include="Debugger\frmAssembler.Designer.cs">
|
||||
<DependentUpon>frmAssembler.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Debugger\frmGoToAll.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Debugger\frmGoToAll.Designer.cs">
|
||||
<DependentUpon>frmGoToAll.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Debugger\frmSetScriptTimeout.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
|
@ -1230,6 +1244,8 @@
|
|||
<Compile Include="RuntimeChecker.cs" />
|
||||
<Compile Include="SingleInstance.cs" />
|
||||
<Compile Include="TestRunner.cs" />
|
||||
<None Include="Resources\RegisterIcon.png" />
|
||||
<None Include="Resources\JumpTarget.png" />
|
||||
<None Include="Resources\Cut.png" />
|
||||
<None Include="Resources\HistoryViewer.png" />
|
||||
<None Include="Resources\VsButton4.png" />
|
||||
|
@ -1334,12 +1350,18 @@
|
|||
<EmbeddedResource Include="Debugger\Controls\ctrlScanlineCycleSelect.resx">
|
||||
<DependentUpon>ctrlScanlineCycleSelect.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Debugger\Controls\ctrlSearchResult.resx">
|
||||
<DependentUpon>ctrlSearchResult.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Debugger\Controls\ctrlTextHooker.resx">
|
||||
<DependentUpon>ctrlTextHooker.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Debugger\Controls\ctrlSourceViewer.resx">
|
||||
<DependentUpon>ctrlSourceViewer.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Debugger\frmGoToAll.resx">
|
||||
<DependentUpon>frmGoToAll.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Debugger\frmSetScriptTimeout.resx">
|
||||
<DependentUpon>frmSetScriptTimeout.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
|
|
20
GUI.NET/Properties/Resources.Designer.cs
generated
20
GUI.NET/Properties/Resources.Designer.cs
generated
|
@ -490,6 +490,16 @@ namespace Mesen.GUI.Properties {
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized resource of type System.Drawing.Bitmap.
|
||||
/// </summary>
|
||||
internal static System.Drawing.Bitmap JumpTarget {
|
||||
get {
|
||||
object obj = ResourceManager.GetObject("JumpTarget", resourceCulture);
|
||||
return ((System.Drawing.Bitmap)(obj));
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized resource of type System.Drawing.Bitmap.
|
||||
/// </summary>
|
||||
|
@ -750,6 +760,16 @@ namespace Mesen.GUI.Properties {
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized resource of type System.Drawing.Bitmap.
|
||||
/// </summary>
|
||||
internal static System.Drawing.Bitmap RegisterIcon {
|
||||
get {
|
||||
object obj = ResourceManager.GetObject("RegisterIcon", resourceCulture);
|
||||
return ((System.Drawing.Bitmap)(obj));
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized resource of type System.Drawing.Bitmap.
|
||||
/// </summary>
|
||||
|
|
|
@ -427,4 +427,10 @@
|
|||
<data name="Cut" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>..\Resources\Cut.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
<data name="JumpTarget" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>..\Resources\JumpTarget.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
<data name="RegisterIcon" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>..\Resources\RegisterIcon.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
</root>
|
Binary file not shown.
Before Width: | Height: | Size: 250 B After Width: | Height: | Size: 275 B |
Binary file not shown.
Before Width: | Height: | Size: 501 B After Width: | Height: | Size: 439 B |
BIN
GUI.NET/Resources/JumpTarget.png
Normal file
BIN
GUI.NET/Resources/JumpTarget.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 560 B |
BIN
GUI.NET/Resources/RegisterIcon.png
Normal file
BIN
GUI.NET/Resources/RegisterIcon.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 234 B |
Loading…
Add table
Reference in a new issue