X-Git-Url: https://git.madduck.net/etc/awesome.git/blobdiff_plain/b7c3cb77a1ca72ab8fb91c8618f8703e3c1e446c..0b80b45bc9bca17f08e8055d364bac17f96129bd:/widgets/cpu.lua diff --git a/widgets/cpu.lua b/widgets/cpu.lua index 96e0d3b..ec84101 100644 --- a/widgets/cpu.lua +++ b/widgets/cpu.lua @@ -28,7 +28,7 @@ local cpu = { local function worker(args) local args = args or {} - local timeout = args.timeout or 5 + local timeout = args.timeout or 2 local settings = args.settings or function() end cpu.widget = wibox.widget.textbox('') @@ -58,7 +58,7 @@ local function worker(args) local dactive = active - cpu.last_active local dtotal = total - cpu.last_total - cpu_noj = {} + cpu_now = {} cpu_now.usage = tostring(math.ceil((dactive / dtotal) * 100)) widget = cpu.widget