diff --git a/Docs/articles/ui.md b/Docs/articles/ui.md index 0e76aa9..f68bbef 100644 --- a/Docs/articles/ui.md +++ b/Docs/articles/ui.md @@ -13,7 +13,7 @@ protected override void LoadContent() { // Load your other content here // Initialize the Ui system - this.UiSystem = new UiSystem(this.Window, this.GraphicsDevice, new UntexturedStyle(this.SpriteBatch)); + this.UiSystem = new UiSystem(this, this.GraphicsDevice, new UntexturedStyle(this.SpriteBatch)); } protected override void Update(GameTime gameTime) { diff --git a/MLEM.Ui/Elements/Group.cs b/MLEM.Ui/Elements/Group.cs index 8035046..f8f496b 100644 --- a/MLEM.Ui/Elements/Group.cs +++ b/MLEM.Ui/Elements/Group.cs @@ -6,7 +6,7 @@ namespace MLEM.Ui.Elements { /// /// A group element to be used inside of a . /// A group is an element that has no rendering or interaction on its own, but that can aid with automatic placement of child elements. - /// If a grouping whose children scroll, and which has a , is desired, a panel with its set to can be used. + /// If a grouping whose children scroll, and which has a , is desired, a with its set to can be used. /// public class Group : Element { diff --git a/MLEM.Ui/Elements/Panel.cs b/MLEM.Ui/Elements/Panel.cs index 3300fea..36f5288 100644 --- a/MLEM.Ui/Elements/Panel.cs +++ b/MLEM.Ui/Elements/Panel.cs @@ -86,6 +86,7 @@ namespace MLEM.Ui.Elements { if (scrollOverflow) { this.scrollBarMaxHistory = new float[3]; + this.scrollBarMaxHistoryDirty = true; this.ResetScrollBarMaxHistory(); this.ScrollBar = new ScrollBar(Anchor.TopRight, Vector2.Zero, 0, 0) {