summaryrefslogtreecommitdiffstats
path: root/MetaTile/ManageHook.hs
diff options
context:
space:
mode:
Diffstat (limited to 'MetaTile/ManageHook.hs')
-rw-r--r--MetaTile/ManageHook.hs9
1 files changed, 5 insertions, 4 deletions
diff --git a/MetaTile/ManageHook.hs b/MetaTile/ManageHook.hs
index f2daf9c..c7140c4 100644
--- a/MetaTile/ManageHook.hs
+++ b/MetaTile/ManageHook.hs
@@ -18,17 +18,18 @@
module MetaTile.ManageHook where
-import Prelude hiding (catch)
import MetaTile.Core
import Graphics.X11.Xlib.Extras
import Graphics.X11.Xlib (Display, Window, internAtom, wM_NAME)
-import Control.Exception.Extensible (bracket, catch, SomeException(..))
+import Control.Exception.Extensible (bracket, SomeException(..))
import Control.Monad.Reader
import Data.Maybe
import Data.Monoid
import qualified MetaTile.StackSet as W
import MetaTile.Operations (reveal)
+import qualified Control.Exception.Extensible as C (catch)
+
-- | Lift an 'X' action to a 'Query'.
liftX :: X a -> Query a
liftX = Query . lift
@@ -74,10 +75,10 @@ title = ask >>= \w -> liftX $ do
let
getProp =
(internAtom d "_NET_WM_NAME" False >>= getTextProperty d w)
- `catch` \(SomeException _) -> getTextProperty d w wM_NAME
+ `C.catch` \(SomeException _) -> getTextProperty d w wM_NAME
extract prop = do l <- wcTextPropertyToTextList d prop
return $ if null l then "" else head l
- io $ bracket getProp (xFree . tp_value) extract `catch` \(SomeException _) -> return ""
+ io $ bracket getProp (xFree . tp_value) extract `C.catch` \(SomeException _) -> return ""
-- | Return the application name.
appName :: Query String