From 0a30958905cfea13e2ee3b62fc38a50d62d8a08e Mon Sep 17 00:00:00 2001 From: Josh Rahm Date: Wed, 6 Dec 2023 19:30:13 -0700 Subject: Add duplicate window --- src/Rahm/Desktop/Keys.hs | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'src/Rahm/Desktop/Keys.hs') diff --git a/src/Rahm/Desktop/Keys.hs b/src/Rahm/Desktop/Keys.hs index 210d4c5..76634b0 100644 --- a/src/Rahm/Desktop/Keys.hs +++ b/src/Rahm/Desktop/Keys.hs @@ -47,10 +47,11 @@ import Rahm.Desktop.Common gotoWorkspace, locationWindow, locationWorkspace, + pointerWorkspace, runMaybeT_, setBorderColor, withBorderColor, - withBorderColorM, pointerWorkspace, + withBorderColorM, duplWindow, ) import Rahm.Desktop.DMenu (runDMenu) import qualified Rahm.Desktop.Dragging as D @@ -302,6 +303,11 @@ keymap = runKeys $ do (h : _) -> lift (focusLocation h) _ -> return () + bind xK_semicolon $ + justMod $ + doc "Run the command which opened this window again." $ + X.withFocused duplWindow + bind xK_w $ do justMod $ doc "Swap windows with other windows" $ @@ -1102,8 +1108,8 @@ mouseMap = runButtons $ do bind button2 $ noMod $ - doc "Sink the window under the cursor into the tiling" $ - windows . W.sink + doc "Run the command that started a window." $ + duplWindow bind button3 $ noMod $ @@ -1170,7 +1176,7 @@ mouseMap = runButtons $ do bind button2 $ noMod $ - doc "Clear the window selection" (noWindow clearWindowSelection) + doc "Clear the window selection" $ noWindow (clearWindowSelection >> escape) bind button13 $ noMod $ -- cgit