diff options
| author | Josh Rahm <joshuarahm@gmail.com> | 2022-04-24 21:06:10 -0600 |
|---|---|---|
| committer | Josh Rahm <joshuarahm@gmail.com> | 2022-04-24 21:10:00 -0600 |
| commit | 07252ce0461d8746481881dbcc6ca07b71fd8553 (patch) | |
| tree | 6392e713485289bae9b6c25bb6f5da0436a5da61 /src/Rahm/Desktop/SwapMaster.hs | |
| parent | 1ff9a98f85df0c3df4e3f1c3f332100922d18317 (diff) | |
| download | rde-07252ce0461d8746481881dbcc6ca07b71fd8553.tar.gz rde-07252ce0461d8746481881dbcc6ca07b71fd8553.tar.bz2 rde-07252ce0461d8746481881dbcc6ca07b71fd8553.zip | |
Roll Windows.hs into R.D.StackSet
Diffstat (limited to 'src/Rahm/Desktop/SwapMaster.hs')
| -rw-r--r-- | src/Rahm/Desktop/SwapMaster.hs | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/Rahm/Desktop/SwapMaster.hs b/src/Rahm/Desktop/SwapMaster.hs index fd61a50..96417ed 100644 --- a/src/Rahm/Desktop/SwapMaster.hs +++ b/src/Rahm/Desktop/SwapMaster.hs @@ -3,7 +3,6 @@ module Rahm.Desktop.SwapMaster (swapMaster) where import qualified Rahm.Desktop.StackSet as W -import Rahm.Desktop.Windows (mapWindows, getMaster, swapWindows) import Control.Monad.Trans.Maybe import XMonad (Window, ExtensionClass(..), X(..), windows, windowset) import Control.Monad (void) @@ -28,13 +27,13 @@ swapMaster = void $ runMaybeT $ do ss <- gets windowset focused <- hoist $ W.peek ss - master <- hoist $ getMaster ss + master <- hoist $ W.masterWindow ss if focused == master then do lw <- MaybeT $ lastWindow <$> XS.get - lift $ windows (swapWindows focused lw) - else lift $ windows (swapWindows focused master) + lift $ windows (W.swapWindows focused lw) + else lift $ windows (W.swapWindows focused master) lift $ do XS.put (LastWindow $ Just master) |