From 97ec92aac22f9e65e395c69d6514b5d1667f3f47 Mon Sep 17 00:00:00 2001 From: Robert Jelic <36573031+NoryiE@users.noreply.github.com> Date: Thu, 13 Oct 2022 19:54:24 +0200 Subject: [PATCH] Scroll fix -Fixed frame calculating wrong anount to scroll --- Basalt/Frame.lua | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Basalt/Frame.lua b/Basalt/Frame.lua index 775a988..d0da34a 100644 --- a/Basalt/Frame.lua +++ b/Basalt/Frame.lua @@ -342,12 +342,13 @@ return function(name, parent, pTerm, basalt) local function calculateMaxScroll(self) if(autoScroll)then + scrollAmount = 0 for _, value in pairs(objects) do for _, b in pairs(value) do if(b.getHeight~=nil)and(b.getY~=nil)then local h, y = b:getHeight(), b:getY() - if (h + y - self:getHeight() ~= scrollAmount) then - scrollAmount = max(h + y - self:getHeight() - 1, 0) + if (h + y - self:getHeight() >= scrollAmount) then + scrollAmount = max(h + y - self:getHeight(), 0) end end end