mirror of
https://github.com/xmonad/xmonad-contrib.git
synced 2025-07-31 20:21:51 -07:00
* Use global state instead of per-layout - so now window is minimized on all workspaces (EWMH requires that windows with _NET_WM_STATE_HIDDEN set should be minimized on any workspace but previously they were not) * Use `windows` instead of `modify`. That should fix bugs related to actions that should be done by `windows` and not done by `modify` (fixes #46) * Mark module X.H.RestoreMinimized as deprecated
42 lines
1.3 KiB
Haskell
42 lines
1.3 KiB
Haskell
-----------------------------------------------------------------------------
|
|
-- |
|
|
-- Module : XMonad.Hooks.RestoreMinimized
|
|
-- Copyright : (c) Jan Vornberger 2009
|
|
-- License : BSD3-style (see LICENSE)
|
|
--
|
|
-- Maintainer : jan.vornberger@informatik.uni-oldenburg.de
|
|
-- Stability : unstable
|
|
-- Portability : not portable
|
|
--
|
|
-- (Deprecated: Use XMonad.Hooks.Minimize) Lets you restore minimized
|
|
-- windows (see "XMonad.Layout.Minimize") by selecting them on a
|
|
-- taskbar (listens for _NET_ACTIVE_WINDOW and WM_CHANGE_STATE).
|
|
--
|
|
-----------------------------------------------------------------------------
|
|
|
|
module XMonad.Hooks.RestoreMinimized
|
|
{-# DEPRECATED "Use XMonad.Hooks.Minimize instead, this module has no effect" #-}
|
|
( -- * Usage
|
|
-- $usage
|
|
RestoreMinimized (..)
|
|
, restoreMinimizedEventHook
|
|
) where
|
|
|
|
import Data.Monoid
|
|
|
|
import XMonad
|
|
|
|
-- $usage
|
|
-- You can use this module with the following in your @~\/.xmonad\/xmonad.hs@:
|
|
--
|
|
-- > import XMonad.Hooks.RestoreMinimized
|
|
-- >
|
|
-- > myHandleEventHook = restoreMinimizedEventHook
|
|
-- >
|
|
-- > main = xmonad def { handleEventHook = myHandleEventHook }
|
|
|
|
data RestoreMinimized = RestoreMinimized deriving ( Show, Read )
|
|
|
|
restoreMinimizedEventHook :: Event -> X All
|
|
restoreMinimizedEventHook _ = return (All True)
|