Revert "Make scrll look more natural when removing items from control"

This reverts commit 88cbcf6baf.
This commit is contained in:
Michael Bucari-Tovo 2022-05-15 11:26:07 -06:00
parent 88cbcf6baf
commit a8a54aa443
3 changed files with 4 additions and 20 deletions

View file

@ -190,10 +190,7 @@ namespace LibationWinForms.ProcessQueue
vScrollBar1.LargeChange = LargeScrollChange;
//https://stackoverflow.com/a/2882878/3335599
int newMaximum = VirtualHeight + vScrollBar1.LargeChange - 1;
if (newMaximum < vScrollBar1.Maximum)
vScrollBar1.Value = Math.Max(vScrollBar1.Value - (vScrollBar1.Maximum - newMaximum), 0);
vScrollBar1.Maximum = newMaximum;
vScrollBar1.Maximum = VirtualHeight + vScrollBar1.LargeChange - 1;
}
}