Debugger: Added copy selection option in disassembly view
This commit is contained in:
parent
6b4fe28e59
commit
9950a4d4cc
2 changed files with 22 additions and 10 deletions
28
UI/Debugger/Controls/ctrlDisassemblyView.Designer.cs
generated
28
UI/Debugger/Controls/ctrlDisassemblyView.Designer.cs
generated
|
@ -34,6 +34,8 @@
|
|||
this.mnuMarkAsCode = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.mnuMarkAsData = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.mnuMarkAsUnidentifiedData = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.mnuEditSelectedCode = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.mnuCopySelection = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.sepMarkSelectionAs = new System.Windows.Forms.ToolStripSeparator();
|
||||
this.mnuToggleBreakpoint = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.mnuAddToWatch = new System.Windows.Forms.ToolStripMenuItem();
|
||||
|
@ -47,7 +49,6 @@
|
|||
this.cboSourceFile = new System.Windows.Forms.ComboBox();
|
||||
this.lblSourceFile = new System.Windows.Forms.Label();
|
||||
this.tlpMain = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.mnuEditSelectedCode = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.ctxMenu.SuspendLayout();
|
||||
this.tlpMain.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
|
@ -83,6 +84,7 @@
|
|||
this.ctxMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||
this.mnuMarkSelectionAs,
|
||||
this.mnuEditSelectedCode,
|
||||
this.mnuCopySelection,
|
||||
this.sepMarkSelectionAs,
|
||||
this.mnuToggleBreakpoint,
|
||||
this.mnuAddToWatch,
|
||||
|
@ -94,7 +96,7 @@
|
|||
this.sepSwitchView,
|
||||
this.mnuSwitchView});
|
||||
this.ctxMenu.Name = "ctxMenu";
|
||||
this.ctxMenu.Size = new System.Drawing.Size(227, 242);
|
||||
this.ctxMenu.Size = new System.Drawing.Size(227, 264);
|
||||
this.ctxMenu.Closing += new System.Windows.Forms.ToolStripDropDownClosingEventHandler(this.ctxMenu_Closing);
|
||||
this.ctxMenu.Opening += new System.ComponentModel.CancelEventHandler(this.ctxMenu_Opening);
|
||||
//
|
||||
|
@ -129,6 +131,20 @@
|
|||
this.mnuMarkAsUnidentifiedData.Size = new System.Drawing.Size(199, 22);
|
||||
this.mnuMarkAsUnidentifiedData.Text = "Unidentified Code/Data";
|
||||
//
|
||||
// mnuEditSelectedCode
|
||||
//
|
||||
this.mnuEditSelectedCode.Image = global::Mesen.GUI.Properties.Resources.Edit;
|
||||
this.mnuEditSelectedCode.Name = "mnuEditSelectedCode";
|
||||
this.mnuEditSelectedCode.Size = new System.Drawing.Size(226, 22);
|
||||
this.mnuEditSelectedCode.Text = "Edit Selected Code";
|
||||
//
|
||||
// mnuCopySelection
|
||||
//
|
||||
this.mnuCopySelection.Image = global::Mesen.GUI.Properties.Resources.Copy;
|
||||
this.mnuCopySelection.Name = "mnuCopySelection";
|
||||
this.mnuCopySelection.Size = new System.Drawing.Size(226, 22);
|
||||
this.mnuCopySelection.Text = "Copy Selection";
|
||||
//
|
||||
// sepMarkSelectionAs
|
||||
//
|
||||
this.sepMarkSelectionAs.Name = "sepMarkSelectionAs";
|
||||
|
@ -236,13 +252,6 @@
|
|||
this.tlpMain.Size = new System.Drawing.Size(465, 398);
|
||||
this.tlpMain.TabIndex = 3;
|
||||
//
|
||||
// mnuEditSelectedCode
|
||||
//
|
||||
this.mnuEditSelectedCode.Image = global::Mesen.GUI.Properties.Resources.Edit;
|
||||
this.mnuEditSelectedCode.Name = "mnuEditSelectedCode";
|
||||
this.mnuEditSelectedCode.Size = new System.Drawing.Size(226, 22);
|
||||
this.mnuEditSelectedCode.Text = "Edit Selected Code";
|
||||
//
|
||||
// ctrlDisassemblyView
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
|
@ -279,5 +288,6 @@
|
|||
private System.Windows.Forms.ToolStripMenuItem mnuMarkAsData;
|
||||
private System.Windows.Forms.ToolStripMenuItem mnuMarkAsUnidentifiedData;
|
||||
private System.Windows.Forms.ToolStripMenuItem mnuEditSelectedCode;
|
||||
private System.Windows.Forms.ToolStripMenuItem mnuCopySelection;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -157,6 +157,9 @@ namespace Mesen.GUI.Debugger.Controls
|
|||
mnuEditSelectedCode.InitShortcut(this, nameof(DebuggerShortcutsConfig.CodeWindow_EditSelectedCode));
|
||||
mnuEditSelectedCode.Click += (s, e) => EditSelectedCode();
|
||||
|
||||
mnuCopySelection.InitShortcut(this, nameof(DebuggerShortcutsConfig.Copy));
|
||||
mnuCopySelection.Click += (s, e) => ctrlCode.CopySelection(true, false, true);
|
||||
|
||||
mnuAddToWatch.InitShortcut(this, nameof(DebuggerShortcutsConfig.LabelList_AddToWatch));
|
||||
|
||||
mnuMarkAsCode.InitShortcut(this, nameof(DebuggerShortcutsConfig.MarkAsCode));
|
||||
|
@ -646,7 +649,6 @@ namespace Mesen.GUI.Debugger.Controls
|
|||
|
||||
bool showMarkAs = !_inSourceView && (_manager.CpuType == CpuType.Cpu || _manager.CpuType == CpuType.Sa1);
|
||||
mnuMarkSelectionAs.Visible = showMarkAs;
|
||||
sepMarkSelectionAs.Visible = showMarkAs;
|
||||
mnuEditSelectedCode.Visible = showMarkAs;
|
||||
|
||||
mnuAddToWatch.Enabled = active;
|
||||
|
|
Loading…
Add table
Reference in a new issue