mirror of
https://github.com/xmonad/xmonad-contrib.git
synced 2025-05-19 03:20:21 -07:00
Clean Xkb masks in X.A.Submap
Xkb adds its own mask and prevent Submap keybindings from normal functioning when alternate layout is used. This patch cleans these masks.
This commit is contained in:
parent
fdaeaa18de
commit
c884dbb74b
@ -18,7 +18,7 @@ module XMonad.Actions.Submap (
|
||||
submap,
|
||||
submapDefault
|
||||
) where
|
||||
|
||||
import Data.Bits
|
||||
import XMonad hiding (keys)
|
||||
import qualified Data.Map as M
|
||||
import Control.Monad.Fix (fix)
|
||||
@ -74,8 +74,8 @@ submapDefault def keys = do
|
||||
if isModifierKey keysym
|
||||
then nextkey
|
||||
else return (m, keysym)
|
||||
|
||||
m' <- cleanMask m
|
||||
-- Remove num lock mask and Xkb group state bits
|
||||
m' <- cleanMask $ m .&. ((1 `shiftL` 12) - 1)
|
||||
maybe def id (M.lookup (m', s) keys)
|
||||
|
||||
io $ ungrabKeyboard d currentTime
|
||||
|
Loading…
x
Reference in New Issue
Block a user