public void SetConfig(DebugViewInfo config) { _config = config; mnuPrgAddressReplace.Checked = false; mnuPrgAddressBelow.Checked = false; mnuHidePrgAddresses.Checked = false; mnuShowByteCodeOnLeft.Checked = false; mnuShowByteCodeBelow.Checked = false; mnuHideByteCode.Checked = false; switch (config.ByteCodePosition) { case ByteCodePosition.Left: this.ctrlCodeViewer.ShowContentNotes = true; this.ctrlCodeViewer.ShowSingleContentLineNotes = true; this.mnuShowByteCodeOnLeft.Checked = true; break; case ByteCodePosition.Below: this.ctrlCodeViewer.ShowContentNotes = true; this.ctrlCodeViewer.ShowSingleContentLineNotes = false; this.mnuShowByteCodeBelow.Checked = true; break; case ByteCodePosition.Hidden: this.ctrlCodeViewer.ShowContentNotes = false; this.ctrlCodeViewer.ShowSingleContentLineNotes = false; this.mnuHideByteCode.Checked = true; break; } switch (config.PrgAddressPosition) { case PrgAddressPosition.Replace: this.ctrlCodeViewer.ShowLineNumberNotes = true; this.ctrlCodeViewer.ShowSingleLineLineNumberNotes = true; this.mnuPrgAddressReplace.Checked = true; break; case PrgAddressPosition.Below: this.ctrlCodeViewer.ShowLineNumberNotes = true; this.ctrlCodeViewer.ShowSingleLineLineNumberNotes = false; this.mnuPrgAddressBelow.Checked = true; break; case PrgAddressPosition.Hidden: this.ctrlCodeViewer.ShowLineNumberNotes = false; this.ctrlCodeViewer.ShowSingleLineLineNumberNotes = false; this.mnuHidePrgAddresses.Checked = true; break; } if (this.FontSize != config.FontSize) { this.FontSize = config.FontSize; } }
public void SetConfig(DebugViewInfo config) { _config = config; _codeViewerActions.InitMenu(config); if (this.ctrlCodeViewer.TextZoom != config.TextZoom) { this.ctrlCodeViewer.TextZoom = config.TextZoom; } }
public void SetConfig(DebugViewInfo config) { _config = config; this.mnuShowOnlyDisassembledCode.Checked = config.ShowOnlyDiassembledCode; this.mnuShowLineNotes.Checked = config.ShowPrgAddresses; this.mnuShowCodeNotes.Checked = config.ShowByteCode; this.FontSize = config.FontSize; this.ctrlCodeViewer.ShowLineNumberNotes = this.mnuShowLineNotes.Checked; this.ctrlCodeViewer.ShowContentNotes = this.mnuShowCodeNotes.Checked; }
public void SetConfig(DebugViewInfo config, bool disableActions = false) { _config = config; if (!disableActions) { _codeViewerActions.InitMenu(config); } if (this.ctrlCodeViewer.TextZoom != config.TextZoom) { this.ctrlCodeViewer.TextZoom = config.TextZoom; } }
public void InitMenu(DebugViewInfo config) { _config = config; mnuPrgShowInline.Checked = false; mnuPrgAddressReplace.Checked = false; mnuPrgAddressBelow.Checked = false; mnuHidePrgAddresses.Checked = false; mnuShowByteCodeOnLeft.Checked = false; mnuShowByteCodeBelow.Checked = false; mnuHideByteCode.Checked = false; mnuShowSourceAsComments.Checked = config.ShowSourceAsComments; switch (config.ByteCodePosition) { case ByteCodePosition.Left: Viewer.CodeViewer.ShowContentNotes = true; Viewer.CodeViewer.ShowSingleContentLineNotes = true; this.mnuShowByteCodeOnLeft.Checked = true; break; case ByteCodePosition.Below: Viewer.CodeViewer.ShowContentNotes = true; Viewer.CodeViewer.ShowSingleContentLineNotes = false; this.mnuShowByteCodeBelow.Checked = true; break; case ByteCodePosition.Hidden: Viewer.CodeViewer.ShowContentNotes = false; Viewer.CodeViewer.ShowSingleContentLineNotes = false; this.mnuHideByteCode.Checked = true; break; } switch (config.PrgAddressPosition) { case PrgAddressPosition.Inline: Viewer.CodeViewer.ShowCompactPrgAddresses = true; Viewer.CodeViewer.ShowLineNumberNotes = false; Viewer.CodeViewer.ShowSingleLineLineNumberNotes = false; this.mnuPrgShowInline.Checked = true; break; case PrgAddressPosition.Replace: Viewer.CodeViewer.ShowCompactPrgAddresses = false; Viewer.CodeViewer.ShowLineNumberNotes = true; Viewer.CodeViewer.ShowSingleLineLineNumberNotes = true; this.mnuPrgAddressReplace.Checked = true; break; case PrgAddressPosition.Below: Viewer.CodeViewer.ShowCompactPrgAddresses = false; Viewer.CodeViewer.ShowLineNumberNotes = true; Viewer.CodeViewer.ShowSingleLineLineNumberNotes = false; this.mnuPrgAddressBelow.Checked = true; break; case PrgAddressPosition.Hidden: Viewer.CodeViewer.ShowCompactPrgAddresses = false; Viewer.CodeViewer.ShowLineNumberNotes = false; Viewer.CodeViewer.ShowSingleLineLineNumberNotes = false; this.mnuHidePrgAddresses.Checked = true; break; } }