summaryrefslogtreecommitdiff
path: root/xkb/xkbUtils.c
diff options
context:
space:
mode:
authorPeter Hutterer <peter@cs.unisa.edu.au>2007-11-13 11:26:16 +1030
committerPeter Hutterer <peter@cs.unisa.edu.au>2007-11-13 11:26:16 +1030
commit51239f87ce42ad564ceee1761980391947294511 (patch)
tree0a92379d923c20f2d861453eb9b4502d3a2ad341 /xkb/xkbUtils.c
parent2b1d946392ce28b96941341778b2b526aa0fb126 (diff)
dix: Send MappingNotify when keyboard maps change.
If a slave device is attached to a master device, then we need to send a mapping notify to the client. Mapping notify needs to be sent if - different slave device but on same master - different master This gives you funny behaviour with the ClientPointer. When a MappingNotify is sent to the client, the client usually responds with a GetKeyboardMapping. This will retrieve the ClientPointer's keyboard mapping, regardless of which keyboard sent the last mapping notify request. So depending on the CP setting, your keyboard may change layout in each app...
Diffstat (limited to 'xkb/xkbUtils.c')
-rw-r--r--xkb/xkbUtils.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/xkb/xkbUtils.c b/xkb/xkbUtils.c
index e87064a42..d49a3c63d 100644
--- a/xkb/xkbUtils.c
+++ b/xkb/xkbUtils.c
@@ -935,7 +935,10 @@ XkbCopyKeymap(XkbDescPtr src, XkbDescPtr dst, Bool sendNotifies)
xkbMapNotify mn;
xkbNewKeyboardNotify nkn;
- if (!src || !dst || src == dst)
+ if (src == dst)
+ return TRUE;
+
+ if (!src || !dst)
return FALSE;
/* client map */