XKB: Remove lock actions disabling
For some reason, XKB allows clients to set a global (!) flag that simply turns lock keys into state no-ops. Ignore this flag. Signed-off-by: Daniel Stone <daniel@fooishbar.org>
This commit is contained in:
parent
2f7cb73067
commit
5c281446d2
|
@ -291,12 +291,9 @@ extern _X_EXPORT void xkbUnwrapProc(DeviceIntPtr, DeviceHandleProc, pointer);
|
|||
|
||||
extern _X_EXPORT int XkbReqCode;
|
||||
extern _X_EXPORT int XkbEventBase;
|
||||
extern _X_EXPORT int XkbDisableLockActions;
|
||||
extern _X_EXPORT int XkbKeyboardErrorCode;
|
||||
extern _X_EXPORT char * XkbBaseDirectory;
|
||||
extern _X_EXPORT char * XkbBinDirectory;
|
||||
extern _X_EXPORT int XkbDfltRepeatDelay;
|
||||
extern _X_EXPORT int XkbDfltRepeatInterval;
|
||||
|
||||
extern _X_EXPORT Bool noXkbExtension;
|
||||
|
||||
|
|
|
@ -6611,8 +6611,6 @@ int rc;
|
|||
xkbDebugFlags = newFlags;
|
||||
xkbDebugCtrls = newCtrls;
|
||||
|
||||
XkbDisableLockActions= (xkbDebugCtrls&XkbDF_DisableLocks);
|
||||
|
||||
rep.type= X_Reply;
|
||||
rep.length = 0;
|
||||
rep.sequenceNumber = client->sequence;
|
||||
|
|
|
@ -85,41 +85,6 @@ static XkbAction fake;
|
|||
fake.type = XkbSA_NoAction;
|
||||
return fake;
|
||||
}
|
||||
if (XkbDisableLockActions) {
|
||||
switch (act->type) {
|
||||
case XkbSA_LockMods:
|
||||
fake.mods.type = XkbSA_SetMods;
|
||||
fake.mods.flags = 0;
|
||||
fake.mods.mask = act->mods.mask;
|
||||
return fake;
|
||||
case XkbSA_LatchMods:
|
||||
fake.mods.type = XkbSA_SetMods;
|
||||
fake.mods.flags = 0;
|
||||
fake.mods.mask = act->mods.mask;
|
||||
return fake;
|
||||
case XkbSA_ISOLock:
|
||||
if (act->iso.flags&XkbSA_ISODfltIsGroup) {
|
||||
fake.group.type = XkbSA_SetGroup;
|
||||
fake.group.flags = act->iso.flags&XkbSA_GroupAbsolute;
|
||||
XkbSASetGroup(&fake.group,XkbSAGroup(&act->iso));
|
||||
}
|
||||
else {
|
||||
fake.mods.type = XkbSA_SetMods;
|
||||
fake.mods.flags = 0;
|
||||
fake.mods.mask = act->iso.mask;
|
||||
}
|
||||
return fake;
|
||||
case XkbSA_LockGroup:
|
||||
case XkbSA_LatchGroup:
|
||||
/* We want everything from the latch/lock action except the
|
||||
* type should be changed to set.
|
||||
*/
|
||||
fake = *act;
|
||||
fake.group.type = XkbSA_SetGroup;
|
||||
return fake;
|
||||
}
|
||||
}
|
||||
else
|
||||
if (xkb->ctrls->enabled_ctrls&XkbStickyKeysMask) {
|
||||
if (act->any.type==XkbSA_SetMods) {
|
||||
fake.mods.type = XkbSA_LatchMods;
|
||||
|
|
|
@ -68,8 +68,6 @@ DEALINGS IN THE SOFTWARE.
|
|||
#include "xkbgeom.h"
|
||||
#include "xkb.h"
|
||||
|
||||
int XkbDisableLockActions = 0;
|
||||
|
||||
/***====================================================================***/
|
||||
|
||||
int
|
||||
|
|
Loading…
Reference in New Issue
Block a user