mirror of
https://github.com/xmonad/xmonad-contrib.git
synced 2025-05-19 11:30:22 -07:00
Add backwards compatability in X.H.FadeInactive
This commit is contained in:
parent
8fe80758a8
commit
8b6135f868
@ -55,7 +55,7 @@ import Control.Monad
|
||||
-- | Converts a percentage to the format required for _NET_WM_WINDOW_OPACITY
|
||||
rationalToOpacity :: Integral a => Rational -> a
|
||||
rationalToOpacity perc
|
||||
| perc < 0 || perc > 1 = 0xffffffff -- invalid input, default to opaque
|
||||
| perc < 0 || perc > 1 = round perc -- to maintain backwards-compatability
|
||||
| otherwise = round $ perc * 0xffffffff
|
||||
|
||||
-- | sets the opacity of a window
|
||||
|
Loading…
x
Reference in New Issue
Block a user