mirror of https://github.com/lcpz/lain.git
widgets: screen notification setting added
This commit is contained in:
parent
724eaa3ad7
commit
02a50839c8
|
@ -41,7 +41,8 @@ local alsabar = {
|
||||||
font = beautiful.font:sub(beautiful.font:find(""), beautiful.font:find(" ")),
|
font = beautiful.font:sub(beautiful.font:find(""), beautiful.font:find(" ")),
|
||||||
font_size = "11",
|
font_size = "11",
|
||||||
color = beautiful.fg_normal,
|
color = beautiful.fg_normal,
|
||||||
bar_size = 18
|
bar_size = 18,
|
||||||
|
screen = 1
|
||||||
},
|
},
|
||||||
|
|
||||||
_current_level = 0,
|
_current_level = 0,
|
||||||
|
@ -55,6 +56,7 @@ function alsabar.notify()
|
||||||
title = "",
|
title = "",
|
||||||
text = "",
|
text = "",
|
||||||
timeout = 4,
|
timeout = 4,
|
||||||
|
screen = alsabar.notifications.screen,
|
||||||
font = alsabar.notifications.font .. " " ..
|
font = alsabar.notifications.font .. " " ..
|
||||||
alsabar.notifications.font_size,
|
alsabar.notifications.font_size,
|
||||||
fg = alsabar.notifications.color
|
fg = alsabar.notifications.color
|
||||||
|
|
|
@ -30,7 +30,7 @@ function calendar:hide()
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function calendar:show(t_out, inc_offset)
|
function calendar:show(t_out, inc_offset, scr)
|
||||||
calendar:hide()
|
calendar:hide()
|
||||||
|
|
||||||
local offs = inc_offset or 0
|
local offs = inc_offset or 0
|
||||||
|
@ -99,6 +99,7 @@ function calendar:show(t_out, inc_offset)
|
||||||
fg = calendar.fg,
|
fg = calendar.fg,
|
||||||
bg = calendar.bg,
|
bg = calendar.bg,
|
||||||
timeout = tims,
|
timeout = tims,
|
||||||
|
screen = scr or 1
|
||||||
})
|
})
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -45,6 +45,7 @@ local function worker(args)
|
||||||
local iface = args.iface or net.get_device()
|
local iface = args.iface or net.get_device()
|
||||||
local units = args.units or 1024 --kb
|
local units = args.units or 1024 --kb
|
||||||
local notify = args.notify or "on"
|
local notify = args.notify or "on"
|
||||||
|
local screen = args.screen or 1
|
||||||
local settings = args.settings or function() end
|
local settings = args.settings or function() end
|
||||||
|
|
||||||
net.widget = wibox.widget.textbox('')
|
net.widget = wibox.widget.textbox('')
|
||||||
|
@ -88,6 +89,7 @@ local function worker(args)
|
||||||
position = "top_left",
|
position = "top_left",
|
||||||
icon = helpers.icons_dir .. "no_net.png",
|
icon = helpers.icons_dir .. "no_net.png",
|
||||||
fg = notify_fg or "#FFFFFF",
|
fg = notify_fg or "#FFFFFF",
|
||||||
|
screen = screen
|
||||||
})
|
})
|
||||||
helpers.set_map(iface, false)
|
helpers.set_map(iface, false)
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue