From: Samir Benmendil Date: Tue, 31 Jan 2017 01:11:07 +0000 (+0000) Subject: awesome: fix bindings for modkey+space and others involving mypromptbox X-Git-Url: https://git.rmz.io/dotfiles.git/commitdiff_plain/7f294912eb8a0c7405642dcb1dde2d96a4ac7b79?ds=inline awesome: fix bindings for modkey+space and others involving mypromptbox --- diff --git a/awesome/bindings.lua b/awesome/bindings.lua index 457e936..5d9937b 100644 --- a/awesome/bindings.lua +++ b/awesome/bindings.lua @@ -53,11 +53,14 @@ globalkeys = awful.util.table.join(globalkeys, awful.key({ modkey }, "x", function () - awful.prompt.run({ prompt = "Run Lua code: " }, - mypromptbox[mouse.screen].widget, - awful.util.eval, nil, - awful.util.getdir("cache") .. "/history_eval") - end), + awful.prompt.run { + prompt = "Run Lua code: ", + textbox = awful.screen.focused().mypromptbox.widget, + exe_callback = awful.util.eval, + history_path = awful.util.get_cache_dir() .. "/history_eval" + } + end, + {description = "lua execute prompt", group = "awesome"}), -- Menubar -- awful.key({ modkey }, "p", function() menubar.show() end), @@ -70,7 +73,7 @@ globalkeys = awful.util.table.join(globalkeys, -- Menu awful.key({ modkey }, "w", function () mymainmenu:show({ coords = { x = 0, y = 0}}) end), -- Prompt - awful.key({ modkey }, "space", function () mypromptbox[mouse.screen]:run() end), + awful.key({ modkey }, "space", function () awful.screen.focused().mypromptbox:run() end), -- switch layout awful.key({ modkey }, "]", function () awful.layout.inc( 1, mouse.screen, layouts) end), awful.key({ modkey }, "[", function () awful.layout.inc(-1, mouse.screen, layouts) end),