Commit d2ba4ddb authored by Ulrich Sibiller's avatar Ulrich Sibiller Committed by Mike Gabriel

nxagent: make nxagentXkbState.Initialized a Boolean

parent f10e9d9a
......@@ -1143,7 +1143,7 @@ FIXME: Don't enqueue the KeyRelease event if the key was not already
nxagentKeyDown = 0;
}
if (nxagentXkbState.Initialized == 0)
if (!nxagentXkbState.Initialized)
{
if (X.xkey.keycode == nxagentCapsLockKeycode)
{
......@@ -2263,7 +2263,7 @@ FIXME: Don't enqueue the KeyRelease event if the key was not already
int nxagentHandleKeyPress(XEvent *X, enum HandleEventResult *result)
{
if (nxagentXkbState.Initialized == 0)
if (!nxagentXkbState.Initialized)
{
if (X -> xkey.keycode == nxagentCapsLockKeycode)
{
......@@ -2741,7 +2741,7 @@ int nxagentHandleXkbKeyboardStateEvent(XEvent *X)
nxagentXkbState.Locked);
#endif
nxagentXkbState.Initialized = 1;
nxagentXkbState.Initialized = True;
if (nxagentXkbState.Caps == 0 &&
(nxagentXkbState.Locked & CAPSFLAG_IN_EVENT))
......
......@@ -161,7 +161,7 @@ XkbAgentInfoRec nxagentXkbInfo = { -1, -1, -1, -1, -1 };
* Keyboard status, updated through XKB events.
*/
XkbAgentStateRec nxagentXkbState = { 0, 0, 0, 0, 0 };
XkbAgentStateRec nxagentXkbState = { 0, 0, 0, 0, False };
/*
* Info for disabling/enabling Xkb extension.
......
......@@ -68,8 +68,7 @@ typedef struct _XkbAgentState
int Caps;
int Num;
int Focus;
int Initialized;
Bool Initialized;
} XkbAgentStateRec;
extern XkbAgentStateRec nxagentXkbState;
......
......@@ -616,7 +616,7 @@ Bool nxagentReconnectSession(void)
}
}
nxagentXkbState.Initialized = 0;
nxagentXkbState.Initialized = False;
SAFE_free(nxagentOldKeyboard);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment