/// <summary> /// Create a "P" command to utilize the clipboard text /// </summary> private async void OnItemTripleClicked(object sender, DisassemblyItemSelectedEventArgs e) { if (!SpectNetPackage.Default.Options.CommentingMode || e.Selected == null) { return; } Prompt.CommandText = $"P {e.Selected.AddressFormatted} {Clipboard.GetText()}"; Prompt.CommandLine.CaretIndex = Prompt.CommandText.Length; await Task.Delay(20); Prompt.SetFocus(); }
/// <summary> /// Create an "L" command to utilize the label address /// </summary> private async void OnItemClicked(object sender, DisassemblyItemSelectedEventArgs e) { if (e.Selected == null) { return; } if (SpectNetPackage.Default.Options.CommentingMode) { // --- Commenting mode: Create an "L" command to utilize the label address Prompt.CommandText = $"L {e.Selected.AddressFormatted} "; Prompt.CommandLine.CaretIndex = Prompt.CommandText.Length; await Task.Delay(10); Prompt.SetFocus(); return; } // --- Normal mode, toggle the breakpoint e.Selected.Parent.ToggleBreakpoint(e.Selected); e.Selected.RaisePropertyChanged("HasBreakpoint"); }