mirror of
https://github.com/MikaylaFischler/cc-mek-scada.git
synced 2024-08-30 18:22:34 +00:00
fixed element assertion scope on frame validations
This commit is contained in:
parent
86e8feaabc
commit
6f1195dded
@ -7,7 +7,7 @@ local flasher = require("graphics.flasher")
|
|||||||
|
|
||||||
local core = {}
|
local core = {}
|
||||||
|
|
||||||
core.version = "2.0.1"
|
core.version = "2.0.2"
|
||||||
|
|
||||||
core.flasher = flasher
|
core.flasher = flasher
|
||||||
core.events = events
|
core.events = events
|
||||||
|
@ -217,10 +217,10 @@ function element.new(args, child_offset_x, child_offset_y)
|
|||||||
end
|
end
|
||||||
|
|
||||||
-- check frame
|
-- check frame
|
||||||
element.assert(f.x >= 1, "frame x not >= 1", 2)
|
element.assert(f.x >= 1, "frame x not >= 1", 3)
|
||||||
element.assert(f.y >= 1, "frame y not >= 1", 2)
|
element.assert(f.y >= 1, "frame y not >= 1", 3)
|
||||||
element.assert(f.w >= 1, "frame width not >= 1", 2)
|
element.assert(f.w >= 1, "frame width not >= 1", 3)
|
||||||
element.assert(f.h >= 1, "frame height not >= 1", 2)
|
element.assert(f.h >= 1, "frame height not >= 1", 3)
|
||||||
|
|
||||||
-- create window
|
-- create window
|
||||||
protected.window = window.create(self.p_window, f.x, f.y, f.w, f.h, args.hidden ~= true)
|
protected.window = window.create(self.p_window, f.x, f.y, f.w, f.h, args.hidden ~= true)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user