diff options
author | Peter Hutterer <peter.hutterer@redhat.com> | 2008-08-11 15:40:03 +0930 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@redhat.com> | 2008-08-12 10:54:45 +0930 |
commit | 12e8f5e5b3f33dbd1290c76dd0d6a4cf832993d7 (patch) | |
tree | f7dd943c72c4d1b34dba7f7a95e2744fb543271e /keymap.c | |
parent | de48206e7fe2206542313a2d1d1ea3c40b06114b (diff) |
Add a few explanatory comments.
Diffstat (limited to 'keymap.c')
-rw-r--r-- | keymap.c | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -41,6 +41,9 @@ XkbFile * sections[MAX_SECTIONS]; +/** + * Compile the given file and store the output in result. + */ Bool CompileKeymap(XkbFile *file,XkbFileInfo *result,unsigned merge) { @@ -59,7 +62,7 @@ LEDInfo * unbound= NULL; required= XkmSemanticsRequired; legal= XkmSemanticsLegal; break; - case XkmLayoutFile: + case XkmLayoutFile: /* standard type if setxkbmap -print */ required= XkmLayoutRequired; legal= XkmKeymapLegal; break; @@ -75,6 +78,7 @@ LEDInfo * unbound= NULL; have= 0; ok= 1; file= (XkbFile *)file->defs; + /* Check for duplicate entries in the input file */ while ((file)&&(ok)) { file->topName= mainName; if ((have&(1<<file->type))!=0) { @@ -129,6 +133,7 @@ LEDInfo * unbound= NULL; have|= (1<<file->type); file= (XkbFile*)file->common.next; } + /* compile the sections we have in the file one-by-one, or fail. */ if (ok) { if (ok && (sections[KEYCODES]!=NULL)) ok= CompileKeycodes(sections[KEYCODES],result,MergeOverride); |