changed eventHandler

- the event handler is now only listening to necessary events, which makes the overall event loop much smaller and makes other stuff also possible
- base frame is now auto. resizing
- setMoveable -> setMovable

Note: There may be some (ofc expected) bugs..
This commit is contained in:
Robert Jelic
2022-08-12 01:52:06 +02:00
parent 5f76a059cc
commit 6dcd4c2427
76 changed files with 1905 additions and 14981 deletions

View File

@@ -464,7 +464,8 @@ outputFile:write("project['default'] = {}")
local function writeNewPackage(subdir, name, path)
if not(fs.isDir(path))then
outputFile:write("project['"..subdir.."']['"..name.."'] = ".."function(...)")
local fileData = io.open(path, "r"):read("*all")
local file = io.open(path, "r")
local fileData = file:read("*all")
if(minifyProject)then
local success, data = minify(fileData)
if(success)then
@@ -475,7 +476,7 @@ local function writeNewPackage(subdir, name, path)
else
outputFile:write(fileData:gsub("]]", "] ]"):gsub("]]", "] ]").."\n")
end
fileData.close()
file:close()
outputFile:write("end; \n")
end
end
@@ -490,16 +491,17 @@ for _,v in pairs(projectFiles)do
end
end
local main = io.open(fs.combine(projectPath, mainFile), "r"):read("*all")
local main = io.open(fs.combine(projectPath, mainFile), "r")
local mainData = main:read("*all")
if(minifyProject)then
local success,data = minify(main)
local success,data = minify(mainData)
if(success)then
outputFile:write(data)
else
print("Error: Can't minify "..fs.combine(projectPath, mainFile))
print("Error: Can't minify "..fs.combine(projectPath, mainFile).." "..data)
end
else
outputFile:write(main)
outputFile:write(mainData)
end
outputFile:close()
main:close()
outputFile:close()