h1-mod/data/cdata/ui_scripts/mods/download.lua

14 lines
459 B
Lua
Raw Normal View History

Engine.GetLuiRoot():registerEventHandler("mod_download_start", function(element, event)
local popup = LUI.openpopupmenu("generic_waiting_popup_", {
oncancel = function()
download.abort()
end,
withcancel = true,
text = "Downloading " .. event.request.name .. "..."
})
Engine.GetLuiRoot():registerEventHandler("mod_download_done", function()
LUI.FlowManager.RequestLeaveMenu(popup)
end)
end)