aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Keyboard.c19
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Keyboard.h2
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Reconnect.c2
3 files changed, 7 insertions, 16 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c
index 20b68b563..5c35d7124 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c
@@ -1691,10 +1691,14 @@ void nxagentWriteKeyboardFile(char *rules, char *model, char *layout, char *vari
void nxagentKeycodeConversionSetup(void)
{
+ nxagentKeycodeConversion = False;
+
+ if (nxagentXkbInfo.Opcode == -1)
+ return;
+
if (nxagentOption(KeycodeConversion) == KeycodeConversionOff)
{
fprintf(stderr, "Info: Keycode conversion is off\n");
- nxagentKeycodeConversion = False;
}
else if (nxagentOption(KeycodeConversion) == KeycodeConversionOn)
{
@@ -1721,23 +1725,10 @@ void nxagentKeycodeConversionSetup(void)
#endif
fprintf(stderr, "Info: Keycode conversion auto-determined as off\n");
- nxagentKeycodeConversion = False;
}
}
}
-void nxagentResetKeycodeConversion(void)
-{
- if (nxagentXkbInfo.Opcode != -1)
- {
- nxagentKeycodeConversionSetup();
- }
- else
- {
- nxagentKeycodeConversion = False;
- }
-}
-
Bool nxagentGetRemoteXkbExtension(void)
{
Bool result;
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h
index b6ec51e99..dbfb47733 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h
+++ b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h
@@ -117,7 +117,7 @@ void nxagentEnableXkbExtension(void);
void nxagentTuneXkbWrapper(void);
-void nxagentResetKeycodeConversion(void);
+void nxagentKeycodeConversionSetup(void);
Bool nxagentGetRemoteXkbExtension(void);
#endif
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c
index bd4fccdce..91445a383 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c
@@ -620,7 +620,7 @@ Bool nxagentReconnectSession(void)
}
else
{
- nxagentResetKeycodeConversion();
+ nxagentKeycodeConversionSetup();
}
nxagentXkbState.Initialized = 0;