core/menusystem: fix a crash

This commit is contained in:
Kazhnuz 2019-02-13 18:51:10 +01:00
parent 88701f5e44
commit 70853353bb

View file

@ -221,11 +221,11 @@ function GridBox:draw()
self:regenSlots() -- On reget les slots au cas où :p
for i,v in ipairs(self.slots) do
if (v.isChild == 0) and (v.widgetID <= #self.widget.list) then
--self.widget.list[v.widgetID]:draw(widgetx, widgety, self.widget.w * v.sizeW, self.widget.h * v.sizeH)
--self.widget.list[v.widgetID]:draw(widgetx, widgety, self.widget.w * v.width, self.widget.h * v.height)
if self.widget.selected == v.widgetID and self:haveFocus() == true then
self.widget.list[v.widgetID]:drawSelected(widgetx, widgety, self.widget.w * v.sizeW, self.widget.h * v.sizeH)
self.widget.list[v.widgetID]:drawSelected(widgetx, widgety, self.widget.w * v.width, self.widget.h * v.height)
else
self.widget.list[v.widgetID]:draw(widgetx, widgety, self.widget.w * v.sizeW, self.widget.h * v.sizeH)
self.widget.list[v.widgetID]:draw(widgetx, widgety, self.widget.w * v.width, self.widget.h * v.height)
end
end
if (v.isChild > 0) and false then