diff --git a/.DS_Store b/.DS_Store index 43119828..9c805603 100644 Binary files a/.DS_Store and b/.DS_Store differ diff --git a/Applications.txt b/Applications.txt index d21edc5e..02e07dcb 100644 --- a/Applications.txt +++ b/Applications.txt @@ -8,7 +8,7 @@ about="IgorTimofeev/OpenComputers/master/MineOS/About/", type="Script", forceDownload=true, - version=3.44, + version=3.45, }, { name="MineOS/Pictures/Raspberry.pic", @@ -274,7 +274,7 @@ url="IgorTimofeev/OpenComputers/master/lib/ECSAPI.lua", type="Library", preLoadFile=true, - version=1.08, + version=1.09, }, { name="lib/colorlib.lua", @@ -886,7 +886,7 @@ icon="IgorTimofeev/OpenComputers/master/Applications/MineCodeIDE/Icon.pic", createShortcut="dock", forceDownload=true, - version=1.11, + version=1.12, }, { name="MineOS/Applications/Battleship", diff --git a/Applications/MineCodeIDE/MineCodeIDE.lua b/Applications/MineCodeIDE/MineCodeIDE.lua index 19a498c0..0c566977 100755 --- a/Applications/MineCodeIDE/MineCodeIDE.lua +++ b/Applications/MineCodeIDE/MineCodeIDE.lua @@ -758,7 +758,7 @@ local function createWindow() end elseif eventData[1] == "clipboard" then local lines = {} - for line in data:gmatch("(.+)\n") do + for line in eventData[3]:gmatch("(.+)\n") do table.insert(lines, removeTabs(line)) end paste({eventData[3]}) diff --git a/lib/ECSAPI.lua b/lib/ECSAPI.lua index 208174d4..d2d88568 100755 --- a/lib/ECSAPI.lua +++ b/lib/ECSAPI.lua @@ -1178,6 +1178,10 @@ function ecs.newFile(path) local inputs = ecs.universalWindow("auto", "auto", 30, ecs.windowColors.background, true, {"EmptyLine"}, {"CenterText", 0x262626, "Новый файл"}, {"EmptyLine"}, {"Input", 0x262626, 0x880000, ""}, {"EmptyLine"}, {"Button", {0xbbbbbb, 0xffffff, "OK"}}) if ecs.checkName(inputs[1], path) then + fs.makeDirectory(fs.path(path)) + local file = io.open(path, "w") + file:write("") + file:close() local MineOSCore = require("MineOSCore") MineOSCore.safeLaunch(MineOSCore.paths.applications .. "/MineCode IDE.app/MineCode IDE.lua", "open", path) end