summaryrefslogtreecommitdiff
path: root/bindings.lua
diff options
context:
space:
mode:
Diffstat (limited to 'bindings.lua')
-rw-r--r--bindings.lua19
1 files changed, 14 insertions, 5 deletions
diff --git a/bindings.lua b/bindings.lua
index 455a5fd..be43176 100644
--- a/bindings.lua
+++ b/bindings.lua
@@ -68,8 +68,6 @@ function M.create(workspace)
awful.key({ modkey, "Control" }, "h", function () awful.tag.incncol( 1) end),
awful.key({ modkey, "Control" }, "l", function () awful.tag.incncol(-1) end),
- awful.key({ modkey, "Control" }, "n", awful.client.restore),
-
-- Prompt
awful.key({ modkey }, "r", function () mypromptbox[mouse.screen]:run() end),
@@ -79,7 +77,19 @@ function M.create(workspace)
mypromptbox[mouse.screen].widget,
awful.util.eval, nil,
awful.util.getdir("cache") .. "/history_eval")
- end)
+ end),
+
+ awful.key({ modkey }, "n",
+ function()
+ awful.prompt.run({ prompt = "Rename desktop: " },
+ mypromptbox[mouse.screen].widget,
+ function(input)
+ if input then
+ local cur_desk = workspace.screen_state[mouse.screen].desktop
+ workspace:rename_desktop(cur_desk, input)
+ end
+ end)
+ end)
)
-- Bind all key numbers to tags.
@@ -117,7 +127,7 @@ function M.create(workspace)
function ()
local screen = mouse.screen
if workspace.desktops[i] == nil then
- workspace:add_desktop("Desktop " .. i, 10)
+ workspace:add_desktop(i, "Desktop " .. i, 10)
end
workspace:view(screen, i)
end),
@@ -137,7 +147,6 @@ function M.create(workspace)
awful.key({ modkey, "Control" }, "space", awful.client.floating.toggle ),
awful.key({ modkey, "Control" }, "Return", function (c) c:swap(awful.client.getmaster()) end),
awful.key({ modkey, }, "o", awful.client.movetoscreen ),
- awful.key({ modkey, }, "t", function (c) c.ontop = not c.ontop end),
awful.key({ modkey, }, "m",
function (c)
c.maximized_horizontal = not c.maximized_horizontal