From e8b717c18eebd91e387df77b1da760051868f54c Mon Sep 17 00:00:00 2001 From: YoshiRulz Date: Tue, 24 Sep 2024 13:51:37 +1000 Subject: [PATCH] Reorder fields in `WatchEditor` (resolves #4046) --- .../tools/Watch/WatchEditor.cs | 53 ++++++++++--------- 1 file changed, 27 insertions(+), 26 deletions(-) diff --git a/src/BizHawk.Client.EmuHawk/tools/Watch/WatchEditor.cs b/src/BizHawk.Client.EmuHawk/tools/Watch/WatchEditor.cs index 35a9141e04..a75615c2f5 100644 --- a/src/BizHawk.Client.EmuHawk/tools/Watch/WatchEditor.cs +++ b/src/BizHawk.Client.EmuHawk/tools/Watch/WatchEditor.cs @@ -54,6 +54,18 @@ namespace BizHawk.Client.EmuHawk }; var row = 0; + LocLabelEx label6 = new() { Anchor = AnchorStyles.Right, Text = "Mem Domain:" }; + DomainDropDown = new() + { + DropDownStyle = ComboBoxStyle.DropDownList, + FormattingEnabled = true, + Size = new(120, 21), + }; + DomainDropDown.SelectedIndexChanged += DomainComboBox_SelectedIndexChanged; + tlpMain.Controls.Add(label6, row: row, column: 0); + tlpMain.Controls.Add(DomainDropDown, row: row, column: 1); + row++; + LocLabelEx label1 = new() { Anchor = AnchorStyles.Right, Text = "Address:" }; AddressBox = new() { @@ -71,12 +83,6 @@ namespace BizHawk.Client.EmuHawk tlpMain.Controls.Add(flpAddr, row: row, column: 1); row++; - LocLabelEx label2 = new() { Anchor = AnchorStyles.Right, Text = "Notes:" }; - NotesBox = new() { MaxLength = 256, Size = new(120, 20) }; - tlpMain.Controls.Add(label2, row: row, column: 0); - tlpMain.Controls.Add(NotesBox, row: row, column: 1); - row++; - LocLabelEx label3 = new() { Anchor = AnchorStyles.Right, Text = "Size:" }; SizeDropDown = new() { @@ -90,6 +96,17 @@ namespace BizHawk.Client.EmuHawk tlpMain.Controls.Add(SizeDropDown, row: row, column: 1); row++; + //TODO merge into size dropdown (event handlers will need rewriting) + BigEndianCheckBox = new() + { + AutoSize = true, + Size = new(77, 17), + Text = "Big Endian", + UseVisualStyleBackColor = true, + }; + tlpMain.Controls.Add(BigEndianCheckBox, row: row, column: 1); + row++; + LocLabelEx DisplayTypeLabel = new() { Anchor = AnchorStyles.Right, Text = "Display Type:" }; DisplayTypeDropDown = new() { @@ -102,26 +119,10 @@ namespace BizHawk.Client.EmuHawk tlpMain.Controls.Add(DisplayTypeDropDown, row: row, column: 1); row++; - BigEndianCheckBox = new() - { - AutoSize = true, - Size = new(77, 17), - Text = "Big Endian", - UseVisualStyleBackColor = true, - }; - tlpMain.Controls.Add(BigEndianCheckBox, row: row, column: 1); - row++; - - LocLabelEx label6 = new() { Anchor = AnchorStyles.Right | AnchorStyles.Top, Text = "Mem Domain:" }; - DomainDropDown = new() - { - DropDownStyle = ComboBoxStyle.DropDownList, - FormattingEnabled = true, - Size = new(120, 21), - }; - DomainDropDown.SelectedIndexChanged += DomainComboBox_SelectedIndexChanged; - tlpMain.Controls.Add(label6, row: row, column: 0); - tlpMain.Controls.Add(DomainDropDown, row: row, column: 1); + LocLabelEx label2 = new() { Anchor = AnchorStyles.Right | AnchorStyles.Top, Text = "Notes:" }; + NotesBox = new() { MaxLength = 256, Size = new(120, 20) }; + tlpMain.Controls.Add(label2, row: row, column: 0); + tlpMain.Controls.Add(NotesBox, row: row, column: 1); row++; Button OK = new()