From: martin f. krafft Date: Tue, 14 Oct 2008 10:55:34 +0000 (+0200) Subject: follow config changes X-Git-Url: https://git.madduck.net/etc/awesome.git/commitdiff_plain/5b34b565d7cdb0a61f93bb028127412697239a3a follow config changes --- diff --git a/.config/awesome/rc.lua b/.config/awesome/rc.lua index 3f21875..29b0d62 100644 --- a/.config/awesome/rc.lua +++ b/.config/awesome/rc.lua @@ -130,8 +130,8 @@ mytaglist.label = awful.widget.taglist.label.all mytasklist = widget({ type = "tasklist", name = "mytasklist" }) mytasklist:buttons({ button({ }, 1, function (object, c) client.focus = c; c:raise() end), - button({ }, 4, function () awful.client.focusbyidx(1) end), - button({ }, 5, function () awful.client.focusbyidx(-1) end) + button({ }, 4, function () awful.client.focus.byidx(1) end), + button({ }, 5, function () awful.client.focus.byidx(-1) end) }) mytasklist.label = awful.widget.tasklist.label.currenttags @@ -260,7 +260,7 @@ keybinding({ modkey }, "Escape", awful.tag.history.restore):add() keybinding({ modkey }, "Return", function () awful.util.spawn(terminal) end):add() keybinding({ modkey, "Control" }, "r", function () - mypromptbox.text = + mypromptbox[mouse.screen].text = awful.util.escape(awful.util.restart()) end):add() keybinding({ modkey, "Shift" }, "q", awesome.quit):add() @@ -294,24 +294,25 @@ keybinding({ modkey, "Shift" }, "space", function () awful.layout.inc(layouts, - -- Prompt keybinding({ modkey }, "F1", function () - awful.prompt.run({ prompt = "Run: " }, mypromptbox, awful.util.spawn, awful.completion.bash, + awful.prompt.run({ prompt = "Run: " }, mypromptbox[mouse.screen], awful.util.spawn, awful.completion.bash, os.getenv("HOME") .. "/.cache/awesome/history") end):add() keybinding({ modkey }, "F4", function () - awful.prompt.run({ prompt = "Run Lua code: " }, mypromptbox, awful.eval, awful.prompt.bash, + awful.prompt.run({ prompt = "Run Lua code: " }, mypromptbox[mouse.screen], awful.util.eval, awful.prompt.bash, os.getenv("HOME") .. "/.cache/awesome/history_eval") end):add() keybinding({ modkey, "Ctrl" }, "i", function () - if mypromptbox.text then - mypromptbox.text = nil + local s = mouse.screen + if mypromptbox[s].text then + mypromptbox[s].text = nil else - mypromptbox.text = nil + mypromptbox[s].text = nil if client.focus.class then - mypromptbox.text = "Class: " .. client.focus.class .. " " + mypromptbox[s].text = "Class: " .. client.focus.class .. " " end if client.focus.instance then - mypromptbox.text = mypromptbox.text .. "Instance: ".. client.focus.instance .. " " + mypromptbox[s].text = mypromptbox[s].text .. "Instance: ".. client.focus.instance .. " " end if client.focus.role then - mypromptbox.text = mypromptbox.text .. "Role: ".. client.focus.role + mypromptbox[s].text = mypromptbox[s].text .. "Role: ".. client.focus.role end end end):add() @@ -457,7 +458,7 @@ awful.hooks.manage.register(function (c) -- i.e. put it at the end of others instead of setting it master. -- awful.client.setslave(c) - -- Honor size hints: if you want to drop the gaps between windows, set this to false. | if maxapps[inst] or maxapps[cls] then + -- Honor size hints: if you want to drop the gaps between windows, set this to false. c.honorsizehints = true -- Maximise some @@ -524,7 +525,7 @@ function get_acpibatt() local s = f:read('*l') f:close() if not s then - return laststring; + return '-'; end -- Battery 0: Discharging, 89%, 00:02:14 remaining @@ -547,7 +548,7 @@ function get_acpibatt() elseif status == 'Discarching' then status = 'd'; else - status = ''; + status = '-'; end return percent; -- .. ' (' .. status .. ')'; -- .. ' ' .. time .. ' left';