From f5eac3a48ed6de9b1fd6d58f97465a6a31654566 Mon Sep 17 00:00:00 2001 From: Andrea Scarpino Date: Sun, 13 Apr 2014 12:19:02 +0200 Subject: [PATCH] net: optional notifications --- widgets/net.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/widgets/net.lua b/widgets/net.lua index af97201..08c7366 100644 --- a/widgets/net.lua +++ b/widgets/net.lua @@ -44,6 +44,7 @@ local function worker(args) local timeout = args.timeout or 2 local iface = args.iface or net.get_device() local units = args.units or 1024 --kb + local notify = args.notify or "on" local settings = args.settings or function() end net.widget = wibox.widget.textbox('') @@ -76,7 +77,7 @@ local function worker(args) net.last_t = now_t net.last_r = now_r - if net_now.carrier ~= "1" + if net_now.carrier ~= "1" and notify == "on" then if helpers.get_map(iface) then -- 2.39.5