summaryrefslogtreecommitdiffstats
path: root/Operations.hs
diff options
context:
space:
mode:
authorStefan O'Rear <stefanor@cox.net>2007-06-09 20:58:35 +0200
committerStefan O'Rear <stefanor@cox.net>2007-06-09 20:58:35 +0200
commit66dc293ddb6faf7d7766552ce8be208746e49687 (patch)
treebfc7339ea98da0bab2c4f7881fa8f1c3fa04d83e /Operations.hs
parent80b7c600635c2e21bcbdd001ed25cc0b6848a0b7 (diff)
downloadmetatile-66dc293ddb6faf7d7766552ce8be208746e49687.tar
metatile-66dc293ddb6faf7d7766552ce8be208746e49687.zip
UNDO: Give refresh sole responsibility for establishing window properties (-3 loc)
darcs-hash:20070609185835-e3110-1eaa534465f66313044477acd9cae1bbbcf61950
Diffstat (limited to 'Operations.hs')
-rw-r--r--Operations.hs4
1 files changed, 1 insertions, 3 deletions
diff --git a/Operations.hs b/Operations.hs
index 2c290f3..0716533 100644
--- a/Operations.hs
+++ b/Operations.hs
@@ -45,7 +45,7 @@ import Graphics.X11.Xlib.Extras
--
manage :: Window -> X ()
manage w = withDisplay $ \d -> do
- setInitialProperties w -- we need this so that the modify below will not capture the wrong border size...
+ setInitialProperties w >> reveal w
-- FIXME: This is pretty awkward. We can't can't let "refresh" happen
-- before the call to float, because that will resize the window and
@@ -201,7 +201,6 @@ setWMState w v = withDisplay $ \dpy -> do
-- | hide. Hide a window by unmapping it, and setting Iconified.
hide :: Window -> X ()
hide w = whenX (gets (S.member w . mapped)) $ withDisplay $ \d -> do
- setInitialProperties w
io $ do selectInput d w (clientMask .&. complement structureNotifyMask)
unmapWindow d w
selectInput d w clientMask
@@ -215,7 +214,6 @@ hide w = whenX (gets (S.member w . mapped)) $ withDisplay $ \d -> do
-- this is harmless if the window was already visible
reveal :: Window -> X ()
reveal w = withDisplay $ \d -> do
- setInitialProperties w
setWMState w 1 --normal
io $ mapWindow d w
modify (\s -> s { mapped = S.insert w (mapped s) })