Move DefaultDecoration from DecorationMadness to Decoration

This commit is contained in:
Andrea Rossato 2008-02-10 10:43:04 +00:00
parent c1090dfcaf
commit 041f12f21d
2 changed files with 4 additions and 4 deletions

View File

@ -20,6 +20,7 @@ module XMonad.Layout.Decoration
-- $usage -- $usage
decoration decoration
, Decoration , Decoration
, DefaultDecoration (..)
, DecorationStyle (..) , DecorationStyle (..)
, DecorationMsg (..) , DecorationMsg (..)
, Theme (..), defaultTheme , Theme (..), defaultTheme
@ -129,6 +130,9 @@ class (Read (ds a), Show (ds a)) => DecorationStyle ds a where
-> W.Stack a -> [(a,Rectangle)] -> (a,Rectangle) -> X (Maybe Rectangle) -> W.Stack a -> [(a,Rectangle)] -> (a,Rectangle) -> X (Maybe Rectangle)
decorate ds w h r s ars ar = return $ pureDecoration ds w h r s ars ar decorate ds w h r s ars ar = return $ pureDecoration ds w h r s ars ar
data DefaultDecoration a = DefaultDecoration deriving ( Read, Show )
instance DecorationStyle DefaultDecoration a
instance (DecorationStyle ds Window, Shrinker s) => LayoutModifier (Decoration ds s) Window where instance (DecorationStyle ds Window, Shrinker s) => LayoutModifier (Decoration ds s) Window where
redoLayout (Decoration st sh t ds) sc stack wrs redoLayout (Decoration st sh t ds) sc stack wrs
| decorate_first = do whenIJust st releaseResources | decorate_first = do whenIJust st releaseResources

View File

@ -125,10 +125,6 @@ import XMonad.Layout.WindowArranger
-- WindowNavigation and with some layout combinators. I hope to fix -- WindowNavigation and with some layout combinators. I hope to fix
-- this problem shortly! -- this problem shortly!
-- The xmonad default decoration modifier!
data DefaultDecoration a = DefaultDecoration deriving ( Read, Show )
instance DecorationStyle DefaultDecoration a
-- There may be a regression in Tabbed, and no tab is displayed when -- There may be a regression in Tabbed, and no tab is displayed when
-- using it with other layouts. This is the reason for the following -- using it with other layouts. This is the reason for the following
-- instance (to be removed!) -- instance (to be removed!)