powertop for battery widget added (right mouse button).

This commit is contained in:
Kolan Sh 2017-02-20 13:09:11 +03:00
parent 19ed9bc819
commit b1b1d3567a
1 changed files with 4 additions and 1 deletions

5
wi.lua
View File

@ -62,7 +62,10 @@ function popup_bat()
naughty.notify { text = "Charge : " .. bat_charge .. "%\nState : " .. state ..
" (" .. bat_time .. ")", timeout = 5, hover_timeout = 0.5 }
end
batpct:buttons(awful.util.table.join(awful.button({ }, 1, popup_bat)))
function show_powertop ()
os.execute ("pgrep powertop || urxvt -e sudo powertop &")
end
batpct:buttons(awful.util.table.join(awful.button({ }, 1, popup_bat), awful.button({ }, 3, show_powertop)))
baticon:buttons(batpct:buttons())
----< Volume >--------------------------------------------------------