Replace process.api with Event

This commit is contained in:
kepler155c@gmail.com
2017-07-28 19:01:59 -04:00
parent f8bcf90a6b
commit be51935662
21 changed files with 326 additions and 343 deletions

View File

@@ -103,7 +103,7 @@ function page.grid:draw()
UI.Grid.draw(self)
end
function eventLoop()
Event.addRoutine(function()
while true do
local e = { os.pullEvent() }
@@ -124,8 +124,7 @@ function eventLoop()
page:sync()
end
end
end
end)
UI:setPage(page)
Event.pullEvents(eventLoop)
UI.term:reset()
UI:pullEvents()