Remove overlay support as well Right now we just silently ignore overlay controls, which is probably bad, but it's not the easiest to fix. Signed-off-by: Daniel Stone <daniel@fooishbar.org>
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143
diff --git a/src/xkbcomp/action.c b/src/xkbcomp/action.c
index 7374652..49d8695 100644
--- a/src/xkbcomp/action.c
+++ b/src/xkbcomp/action.c
@@ -740,10 +740,10 @@ const LookupEntry ctrlNames[] = {
{"accessxtimeout", XkbAccessXTimeoutMask},
{"accessxfeedback", XkbAccessXFeedbackMask},
{"audiblebell", XkbAudibleBellMask},
- {"overlay1", XkbOverlay1Mask},
- {"overlay2", XkbOverlay2Mask},
{"ignoregrouplock", XkbIgnoreGroupLockMask},
{"all", XkbAllBooleanCtrlsMask},
+ {"overlay1", 0},
+ {"overlay2", 0},
{"none", 0},
{NULL, 0}
};
diff --git a/src/xkbcomp/symbols.c b/src/xkbcomp/symbols.c
index dfaf547..1065e16 100644
--- a/src/xkbcomp/symbols.c
+++ b/src/xkbcomp/symbols.c
@@ -70,7 +70,6 @@ typedef struct _KeyInfo
unsigned repeat;
struct xkb_behavior behavior;
unsigned short vmodmap;
- unsigned long nameForOverlayKey;
unsigned long allowNone;
xkb_atom_t dfltType;
} KeyInfo;
@@ -102,7 +101,6 @@ InitKeyInfo(KeyInfo * info)
info->behavior.type = XkbKB_Default;
info->behavior.data = 0;
info->vmodmap = 0;
- info->nameForOverlayKey = 0;
info->repeat = RepeatUndefined;
info->allowNone = 0;
}
@@ -134,7 +132,6 @@ FreeKeyInfo(KeyInfo * info)
info->behavior.type = XkbKB_Default;
info->behavior.data = 0;
info->vmodmap = 0;
- info->nameForOverlayKey = 0;
info->repeat = RepeatUndefined;
info->allowNone = 0;
}
@@ -544,7 +541,6 @@ MergeKeys(SymbolsInfo * info, KeyInfo * into, KeyInfo * from)
if (UseNewField(_Key_Behavior, &into->defs, &from->defs, &collide))
{
into->behavior = from->behavior;
- into->nameForOverlayKey = from->nameForOverlayKey;
into->defs.defined |= _Key_Behavior;
}
if (UseNewField(_Key_VModMap, &into->defs, &from->defs, &collide))
@@ -1106,55 +1102,8 @@ SetSymbolsField(KeyInfo * key,
else if (uStrCasePrefix("overlay", field) ||
uStrCasePrefix("permanentoverlay", field))
{
- Bool permanent = False;
- char *which;
- int overlayNdx;
- if (uStrCasePrefix("permanent", field))
- {
- permanent = True;
- which = &field[sizeof("permanentoverlay") - 1];
- }
- else
- {
- which = &field[sizeof("overlay") - 1];
- }
- if (sscanf(which, "%d", &overlayNdx) == 1)
- {
- if (((overlayNdx < 1) || (overlayNdx > 2)) && (warningLevel > 0))
- {
- ERROR("Illegal overlay %d specified for %s\n",
- overlayNdx, longText(key->name));
- ACTION("Ignored\n");
- return False;
- }
- }
- else if (*which == '\0')
- overlayNdx = 1;
- else if (warningLevel > 0)
- {
- ERROR("Illegal overlay \"%s\" specified for %s\n",
- which, longText(key->name));
- ACTION("Ignored\n");
- return False;
- }
- ok = ExprResolveKeyName(value, &tmp);
- if (!ok)
- {
- ERROR("Illegal overlay key specification for %s\n",
- longText(key->name));
- ACTION("Overlay key must be specified by name\n");
- return False;
- }
- if (overlayNdx == 1)
- key->behavior.type = XkbKB_Overlay1;
- else
- key->behavior.type = XkbKB_Overlay2;
- if (permanent)
- key->behavior.type |= XkbKB_Permanent;
-
- key->behavior.data = 0;
- key->nameForOverlayKey = KeyNameToLong(tmp.keyName.name);
- key->defs.defined |= _Key_Behavior;
+ ERROR("Overlays not supported\n");
+ ACTION("Ignoring overlay specification for key %s\n", longText(key->name));
}
else if ((uStrCaseCmp(field, "repeating") == 0) ||
(uStrCaseCmp(field, "repeats") == 0) ||
@@ -1788,7 +1737,7 @@ static Bool
CopySymbolsDef(struct xkb_desc * xkb, KeyInfo *key, int start_from)
{
int i;
- xkb_keycode_t okc, kc;
+ xkb_keycode_t kc;
unsigned width, tmp, nGroups;
struct xkb_key_type * type;
Bool haveActions, autoType, useAlias;
@@ -1943,22 +1892,6 @@ CopySymbolsDef(struct xkb_desc * xkb, KeyInfo *key, int start_from)
{
case XkbKB_Default:
break;
- case XkbKB_Overlay1:
- case XkbKB_Overlay2:
- /* find key by name! */
- if (!FindNamedKey(xkb, key->nameForOverlayKey, &okc, True,
- CreateKeyNames(xkb), 0))
- {
- if (warningLevel >= 1)
- {
- WARN("Key %s not found in keycodes\n",
- longText(key->nameForOverlayKey));
- ACTION("Not treating %s as an overlay key \n",
- longText(key->name));
- }
- break;
- }
- key->behavior.data = okc;
default:
xkb->server->behaviors[kc] = key->behavior;
xkb->server->explicit[kc] |= XkbExplicitBehaviorMask;