GE Lua Documentation

Press F to search!

callbackSecureCommCppProgress

Definition


-- @/lua/ge/extensions/core/online.lua:199

-- do not remove, called by c++
local function callbackSecureCommCppProgress(id, dltotal, dlnow, ultotal, ulnow, dlspeed, ulspeed, time)
  --log('E', 'online', 'callbackSecureCommCppProgress: ' .. dumps(id, dltotal, dlnow, ultotal, ulnow, dlspeed, ulspeed, time))
  local r = requests[id]
  if r and r.priv.callback_progress_lua then
    -- 0 means not set/used
    if dltotal ~= 0 then
      r.pub.dltotal = dltotal
    end
    if dlnow ~= 0 then
      r.pub.dlnow = dlnow
    end
    if ultotal ~= 0 then
      r.pub.ultotal = ultotal
    end
    if ulnow ~= 0 then
      r.pub.ulnow = ulnow
    end
    if ulspeed ~= 0 then
      r.pub.ulspeed = ulspeed
    end
    if dlspeed ~= 0 then
      r.pub.dlspeed = dlspeed
    end
    r.pub.time = time
    r.priv.callback_progress_lua(r.pub)
  end
end

Callers