aboutsummaryrefslogtreecommitdiffstats
path: root/Tabbed.hs
diff options
context:
space:
mode:
authorAndrea Rossato <andrea.rossato@unibz.it>2007-09-30 20:19:12 +0200
committerAndrea Rossato <andrea.rossato@unibz.it>2007-09-30 20:19:12 +0200
commitfad4514781e0e321a651504fa514b37becf9e072 (patch)
treeb832d806d66d8a6ffb88f047d7453f7bf0a16303 /Tabbed.hs
parent695f96c7286824d887e1cc5aaaa5578a8ff8f3bc (diff)
downloadXMonadContrib-fad4514781e0e321a651504fa514b37becf9e072.tar.gz
XMonadContrib-fad4514781e0e321a651504fa514b37becf9e072.tar.xz
XMonadContrib-fad4514781e0e321a651504fa514b37becf9e072.zip
Removed fromIMaybe from Tabbed ad added it to Invisible
darcs-hash:20070930181912-32816-142656b555beb7701117f43c1e20837e2daeb589.gz
Diffstat (limited to 'Tabbed.hs')
-rw-r--r--Tabbed.hs8
1 files changed, 2 insertions, 6 deletions
diff --git a/Tabbed.hs b/Tabbed.hs
index 7ee77af..e68d8fa 100644
--- a/Tabbed.hs
+++ b/Tabbed.hs
@@ -137,7 +137,7 @@ handleMess _ _ = return Nothing
handleEvent :: Invisible Maybe Shrinker -> TConf -> TabState -> Event -> X ()
-- button press
handleEvent ishr conf (TabState {tabsWindows = tws, scr = screen, fontS = fs })
- (ButtonEvent {ev_window = thisw, ev_subwindow = thisbw, ev_event_type = t })
+ (ButtonEvent {ev_window = thisw, ev_subwindow = thisbw, ev_event_type = t })
| t == buttonPress, tl <- map fst tws, thisw `elem` tl || thisbw `elem` tl = do
focus (fromJust $ lookup thisw tws)
updateTab ishr conf fs width (thisw, fromJust $ lookup thisw tws)
@@ -145,7 +145,7 @@ handleEvent ishr conf (TabState {tabsWindows = tws, scr = screen,
width = rect_width screen`div` fromIntegral (length tws)
handleEvent ishr conf (TabState {tabsWindows = tws, scr = screen, fontS = fs })
- (AnyEvent {ev_window = thisw, ev_event_type = t })
+ (AnyEvent {ev_window = thisw, ev_event_type = t })
-- expose
| thisw `elem` (map fst tws) && t == expose = do
updateTab ishr conf fs width (thisw, fromJust $ lookup thisw tws)
@@ -206,7 +206,3 @@ shrinkWhile sh p x = sw $ sh x
shrinkText :: Shrinker
shrinkText "" = [""]
shrinkText cs = cs : shrinkText (init cs)
-
-fromIMaybe :: a -> Invisible Maybe a -> a
-fromIMaybe _ (I (Just x)) = x
-fromIMaybe a (I Nothing) = a