]> git.donarmstrong.com Git - x_base.git/commitdiff
* update rc.lua with new focus switching routines
authorDon Armstrong <don@donarmstrong.com>
Wed, 8 Sep 2010 01:35:15 +0000 (01:35 +0000)
committerDon Armstrong <don@donarmstrong.com>
Wed, 8 Sep 2010 01:35:15 +0000 (01:35 +0000)
.config/awesome/rc.lua

index b00a0a9eab709aed7e4ac772140a5c50a4706cd8..05ae1194725515e94f6da882ef0062f4aa6acf93 100644 (file)
@@ -52,7 +52,7 @@ layouts =
 tags = {}
 for s = 1, screen.count() do
     -- Each screen has its own tag table.
-    tags[s] = awful.tag({ 1, 2, 3, 4, 5, 6, 7, 8, 9 }, s)
+    tags[s] = awful.tag({ 1, 2, 3, 4, 5, 6, 7, 8, 9 }, s, layouts[1])
 end
 -- }}}
 
@@ -184,13 +184,15 @@ globalkeys = awful.util.table.join(
         function ()
             awful.client.focus.byidx( 1)
             if client.focus then client.focus:raise() end
+           warp_mouse()
         end),
     awful.key({ modkey,           }, "k",
         function ()
             awful.client.focus.byidx(-1)
             if client.focus then client.focus:raise() end
+           warp_mouse()
         end),
-    awful.key({ modkey,           }, "w", function () mymainmenu:show(true)        end),
+    awful.key({ modkey,           }, "w", function () mymainmenu:show({keygrabber=true}) end),
 
     -- Layout manipulation
     awful.key({ modkey, "Shift"   }, "j", function () awful.client.swap.byidx(  1)    end),
@@ -352,6 +354,21 @@ client.add_signal("manage", function (c, startup)
     end
 end)
 
+function warp_mouse()
+    c = client.focus
+    if c then
+        local g = c:geometry()
+        mouse.coords { x = g.x + 5, y = g.y + 5 , true}
+    end
+end
+
+-- for s = 1, screen.count() do
+--     screen[s]:add_signal("arrange", function (screen)
+--         warp_mouse(screen)
+--     end)
+-- end
+
+
 client.add_signal("focus", function(c) c.border_color = beautiful.border_focus end)
 client.add_signal("unfocus", function(c) c.border_color = beautiful.border_normal end)
 -- }}}