update field definition when data changes
This commit is contained in:
parent
1b891eaa0b
commit
a147506dc5
@ -379,6 +379,7 @@ namespace UniversalEditor.Editors.Binary
|
||||
|
||||
this.hexedit = new HexEditorControl();
|
||||
this.hexedit.SelectionChanged += Hexedit_SelectionChanged;
|
||||
this.hexedit.Changed += hexedit_Changed;
|
||||
this.Controls.Add(hexedit, new BoxLayout.Constraints(true, true));
|
||||
|
||||
this.conversionPanel = new Container();
|
||||
@ -449,6 +450,18 @@ namespace UniversalEditor.Editors.Binary
|
||||
this.Controls.Add(tabs, new BoxLayout.Constraints(false, false, 0, BoxLayout.PackType.End));
|
||||
}
|
||||
|
||||
private void hexedit_Changed(object sender, EventArgs e)
|
||||
{
|
||||
foreach (TreeModelRow row in tmFieldDefinitions.Rows)
|
||||
{
|
||||
FieldDefinition def = row.GetExtraData<FieldDefinition>("def");
|
||||
if (def == null) continue;
|
||||
|
||||
row.RowColumns[3].Value = GetFieldValue(def);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private void lvFieldDefinitions_RowActivated(object sender, ListViewRowActivatedEventArgs e)
|
||||
{
|
||||
tsbFieldDefinitionEdit_Click(sender, e);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user