init: emit timeout instead of forced update

This commit is contained in:
Adrian C. (anrxc) 2010-10-09 10:03:21 +02:00
parent fbd2af7b15
commit 932bd8dfcb
1 changed files with 4 additions and 3 deletions

View File

@ -119,6 +119,7 @@ local function regregister(reg)
timers[reg.update] = {
timer = capi.timer({ timeout = reg.timer })
}
local tm = timers[reg.update].timer
if tm.connect_signal then
tm:connect_signal("timeout", reg.update)
@ -126,10 +127,10 @@ local function regregister(reg)
tm:add_signal("timeout", reg.update)
end
tm:start()
end
-- Initial update
reg.update()
-- Initial update
tm:emit_signal("timeout")
end
reg.running = true
end
end