Chore: Fix a few more widgets that were breaking dimen refs in

paintTo...
This commit is contained in:
NiLuJe
2024-01-15 20:04:28 +01:00
parent d33bb0452c
commit 3b129e2ada
6 changed files with 52 additions and 19 deletions

View File

@@ -110,11 +110,19 @@ end
function ProgressWidget:paintTo(bb, x, y)
local my_size = self:getSize()
self.dimen = Geom:new{
x = x, y = y,
w = my_size.w,
h = my_size.h
}
if not self.dimen then
self.dimen = Geom:new{
x = x, y = y,
w = my_size.w,
h = my_size.h
}
else
self.dimen.x = x
self.dimen.y = y
-- Possibly redundant
self.dimen.w = my_size.w
self.dimen.h = my_size.h
end
if self.dimen.w == 0 or self.dimen.h == 0 then return end
local _mirroredUI = BD.mirroredUILayout()