use a record pattern to be robust against additions to the X11 library

This commit is contained in:
Daniel Wagner
2015-12-15 07:44:36 -08:00
parent b9b4f4af07
commit 800ae670e2

View File

@@ -41,7 +41,15 @@ debugWindow w = do
case w' of case w' of
Nothing -> Nothing ->
return $ "(deleted window " ++ wx ++ ")" return $ "(deleted window " ++ wx ++ ")"
Just (WindowAttributes x y wid ht bw m o) -> do Just (WindowAttributes
{ wa_x = x
, wa_y = y
, wa_width = wid
, wa_height = ht
, wa_border_width = bw
, wa_map_state = m
, wa_override_redirect = o
}) -> do
c' <- withDisplay $ \d -> c' <- withDisplay $ \d ->
io (getWindowProperty8 d wM_CLASS w) io (getWindowProperty8 d wM_CLASS w)
let c = case c' of let c = case c' of