mirror of
https://github.com/haven1433/HexManiacAdvance.git
synced 2026-09-11 18:37:47 -05:00
fix header update during single-table mode
This commit is contained in:
@@ -179,6 +179,7 @@ namespace HavenSoft.HexManiac.Core.ViewModels {
|
||||
NotifyPropertyChanged(nameof(MinimumScroll));
|
||||
NotifyPropertyChanged(nameof(MaximumScroll));
|
||||
NotifyPropertyChanged(nameof(DataLength));
|
||||
UpdateHeaders();
|
||||
}
|
||||
|
||||
public void ClearTableMode() => SetTableMode(0, 0);
|
||||
|
||||
@@ -312,8 +312,10 @@ namespace HavenSoft.HexManiac.Core.ViewModels {
|
||||
}
|
||||
|
||||
private void GotoAddressAndAlign(int address, int preferredWidth, int tableStart = 0) {
|
||||
Scroll.ClearTableMode();
|
||||
Debug.Assert(Scroll.DataLength == model.Count, "I forgot to update the Scroll.DataLength after expanding the data!");
|
||||
if (address < Scroll.DataStart || Scroll.DataLength < address) {
|
||||
Scroll.ClearTableMode();
|
||||
Debug.Assert(Scroll.DataLength == model.Count, "I forgot to update the Scroll.DataLength after expanding the data!");
|
||||
}
|
||||
|
||||
var startAddress = address;
|
||||
if (preferredWidth > 1) address -= (address - tableStart) % preferredWidth;
|
||||
|
||||
Reference in New Issue
Block a user