From 512a5d86e762695f3b8dd009cf349ef2da15d015 Mon Sep 17 00:00:00 2001 From: Julien Danjou Date: Mon, 27 Apr 2009 18:39:09 +0200 Subject: [PATCH] awful.button: export new Signed-off-by: Julien Danjou --- lib/awful/button.lua.in | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/awful/button.lua.in b/lib/awful/button.lua.in index 217cdeecf..5e60f1071 100644 --- a/lib/awful/button.lua.in +++ b/lib/awful/button.lua.in @@ -27,7 +27,7 @@ ignore_modifiers = { "Lock", "Mod2" } -- CapsLock off. -- @see C api button() function for parameters. -- @return A table with one or several button objects. -local function new(_, mod, ...) +function new(mod, ...) local ret = {} local subsets = util.subsets(ignore_modifiers) for _, set in ipairs(subsets) do @@ -36,6 +36,6 @@ local function new(_, mod, ...) return ret end -setmetatable(_M, { __call = new }) +setmetatable(_M, { __call = function(_, ...) return new(unpack(arg)) end }) -- vim: filetype=lua:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80