mirror of
https://github.com/IgorTimofeev/MineOS.git
synced 2026-01-07 19:52:40 +01:00
Update Pastebin.lua
This commit is contained in:
parent
0b194e3c6c
commit
c40dd5490f
@ -515,7 +515,7 @@ while true do
|
||||
local action = context.menu(e[3], e[4], {"Просмотр"}, "-", {"Запустить"}, {"Сохранить как"}, "-",{"Удалить"})
|
||||
|
||||
if action == "Сохранить как" then
|
||||
local data = ecs.beautifulInput("auto", "auto", 30, "Сохранить как", "Ок", tabColor1, 0xffffff, tabColor2, true, {"Введите путь"})
|
||||
local data = ecs.unversalWindow("auto", "auto", 36, tabColor1, true, {"EmptyLine"}, {"CenterText", 0xffffff, "Загрузить на Pastebin"}, {"EmptyLine"}, {"Input", tabColor2, 0xffffff, "Имя"}, {"Button", {tabColor2, 0xffffff, "OK"}} )
|
||||
local path = data[1]
|
||||
if path ~= nil or path ~= "" or path ~= " " then
|
||||
fs.makeDirectory(fs.path(path))
|
||||
@ -579,7 +579,7 @@ while true do
|
||||
drawAll()
|
||||
displayPastes(drawPastesFrom)
|
||||
elseif key == "⛨Загрузить новый файл" then
|
||||
local data = ecs.beautifulInput("auto", "auto", 30, "Загрузить файл", "Ок", tabColor1, 0xffffff, tabColor2, true, {"Путь к файлу"}, {"Имя на Pastebin"})
|
||||
local data = ecs.unversalWindow("auto", "auto", 36, tabColor1, true, {"EmptyLine"}, {"CenterText", 0xffffff, "Загрузить на Pastebin"}, {"EmptyLine"}, {"Input", tabColor2, 0xffffff, "Путь к файлу"}, {"Input", tabColor2, 0xffffff, "Имя на Pastebin"}, {"Button", {tabColor2, 0xffffff, "OK"}})
|
||||
if fs.exists(data[1]) then
|
||||
if not fs.isDirectory(data[1]) then
|
||||
upload(data[1], data[2] or "Untitled")
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user