summaryrefslogtreecommitdiff
path: root/cpu-widget
diff options
context:
space:
mode:
authorpmakhov <pavel.makhov@savoirfairelinux.com>2017-12-11 17:08:40 -0500
committerpmakhov <pavel.makhov@savoirfairelinux.com>2017-12-11 17:08:40 -0500
commitd94e05bda0f24173fb8c6c3513cbae1d082e5a74 (patch)
treec8f9e7775a49b8f4ec0428dcbd14feb8e8d909d9 /cpu-widget
parente6c30597276edfa2637cde277d7d30209612dd5c (diff)
make cpu widget local
Diffstat (limited to 'cpu-widget')
-rw-r--r--cpu-widget/cpu-widget.lua11
1 files changed, 3 insertions, 8 deletions
diff --git a/cpu-widget/cpu-widget.lua b/cpu-widget/cpu-widget.lua
index 7d077f5..70bf03d 100644
--- a/cpu-widget/cpu-widget.lua
+++ b/cpu-widget/cpu-widget.lua
@@ -1,4 +1,3 @@
-local awful = require("awful")
local watch = require("awful.widget.watch")
local wibox = require("wibox")
@@ -12,7 +11,8 @@ local cpugraph_widget = wibox.widget {
widget = wibox.widget.graph
}
-cpu_widget = wibox.container.margin(wibox.container.mirror(cpugraph_widget, { horizontal = true }), 0, 0, 0, 2)
+-- mirros and push up a bit
+local cpu_widget = wibox.container.margin(wibox.container.mirror(cpugraph_widget, { horizontal = true }), 0, 0, 0, 2)
local total_prev = 0
local idle_prev = 0
@@ -42,9 +42,4 @@ watch("cat /proc/stat | grep '^cpu '", 1,
cpugraph_widget
)
-cpugraph_widget:buttons(
- awful.util.table.join(
- awful.button({}, 1, function() awful.spawn.with_shell("echo left | xsel --clipboard") end),
- awful.button({}, 3, function() awful.spawn.with_shell("echo right | xsel --clipboard") end)
- )
-)
+return cpu_widget \ No newline at end of file