diff options
author | Joachim Breitner <mail@joachim-breitner.de> | 2008-10-06 23:05:48 +0200 |
---|---|---|
committer | Joachim Breitner <mail@joachim-breitner.de> | 2008-10-06 23:05:48 +0200 |
commit | 82fcc47ea367f2ba33f08f95320189a5bab87b41 (patch) | |
tree | 0eaec131caf153e672672ef6879f68cd719bbb4b | |
parent | 1e67a3f13c5ff800ebc6756deee22abb2e4fc6ba (diff) | |
download | XMonadContrib-82fcc47ea367f2ba33f08f95320189a5bab87b41.tar.gz XMonadContrib-82fcc47ea367f2ba33f08f95320189a5bab87b41.tar.xz XMonadContrib-82fcc47ea367f2ba33f08f95320189a5bab87b41.zip |
Add straightforward HiddenWS to WSType
With NonEmptyWS and HiddenNonEmptyWS present, HiddenWS is obviously missing.
darcs-hash:20081006210548-23c07-4ddc29497068f5f4e4819960c0e1bd97bfd74812.gz
-rw-r--r-- | XMonad/Actions/CycleWS.hs | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/XMonad/Actions/CycleWS.hs b/XMonad/Actions/CycleWS.hs index f7a59bb..4bb49cd 100644 --- a/XMonad/Actions/CycleWS.hs +++ b/XMonad/Actions/CycleWS.hs @@ -172,6 +172,7 @@ data WSDirection = Next | Prev -- | What type of workspaces should be included in the cycle? data WSType = EmptyWS -- ^ cycle through empty workspaces | NonEmptyWS -- ^ cycle through non-empty workspaces + | HiddenWS -- ^ cycle through non-visible workspaces | HiddenNonEmptyWS -- ^ cycle through non-empty non-visible workspaces | AnyWS -- ^ cycle through all workspaces | WSIs (X (WindowSpace -> Bool)) @@ -182,6 +183,8 @@ data WSType = EmptyWS -- ^ cycle through empty workspaces wsTypeToPred :: WSType -> X (WindowSpace -> Bool) wsTypeToPred EmptyWS = return (isNothing . stack) wsTypeToPred NonEmptyWS = return (isJust . stack) +wsTypeToPred HiddenWS = do hs <- gets (map tag . hidden . windowset) + return (\w -> tag w `elem` hs) wsTypeToPred HiddenNonEmptyWS = do hs <- gets (map tag . hidden . windowset) return (\w -> isJust (stack w) && tag w `elem` hs) wsTypeToPred AnyWS = return (const True) |