mirror of
https://github.com/Ellpeck/MLEM.git
synced 2024-11-22 20:58:34 +01:00
fixed 0f4e67f20f
This commit is contained in:
parent
0f4e67f20f
commit
cd32372994
1 changed files with 1 additions and 1 deletions
|
@ -85,7 +85,7 @@ namespace MLEM.Ui.Elements {
|
|||
if (e == null || !e.GetParentTree().Contains(this))
|
||||
return;
|
||||
var firstChild = this.Children.First(c => c != this.ScrollBar);
|
||||
this.ScrollBar.CurrentValue = (e.UnscrolledArea.Center.Y - firstChild.Area.Height - this.Area.Height / 2) / e.Scale + this.ChildPadding.Value.Height;
|
||||
this.ScrollBar.CurrentValue = (e.Area.Center.Y - this.Area.Height / 2 - firstChild.Area.Top) / e.Scale + this.ChildPadding.Value.Height / 2;
|
||||
};
|
||||
this.AddChild(this.ScrollBar);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue