mirror of
https://github.com/Ellpeck/MLEM.git
synced 2024-11-22 20:58:34 +01:00
fixed setheightbasedonchildren causing stack overflow on uneven resolutions
This commit is contained in:
parent
f1c9ba5517
commit
aecf1a565e
1 changed files with 1 additions and 1 deletions
|
@ -311,7 +311,7 @@ namespace MLEM.Ui.Elements {
|
|||
var lowest = this.GetLowestChild(e => !e.IsHidden);
|
||||
if (lowest != null) {
|
||||
var newHeight = (lowest.UnscrolledArea.Bottom - pos.Y + this.ScaledChildPadding.Y) / this.Scale;
|
||||
if (newHeight != this.size.Y) {
|
||||
if ((int) newHeight != (int) this.size.Y) {
|
||||
this.size.Y = newHeight;
|
||||
this.ForceUpdateArea();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue