summaryrefslogtreecommitdiffstats
path: root/vncviewer/DesktopWindow.cxx
diff options
context:
space:
mode:
authorPierre Ossman <ossman@cendio.se>2011-03-10 11:57:03 +0000
committerPierre Ossman <ossman@cendio.se>2011-03-10 11:57:03 +0000
commit70f32469fbf2310a8321e90ff270c84cd1720680 (patch)
tree80edf88330fcc6c7098d27ac6a25915b05ed510b /vncviewer/DesktopWindow.cxx
parent381e546e0917fe029645bd7bf6f77c789960e299 (diff)
downloadtigervnc-70f32469fbf2310a8321e90ff270c84cd1720680.tar.gz
tigervnc-70f32469fbf2310a8321e90ff270c84cd1720680.zip
Off-by-one error. FL_F points to "F0", not F1.
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@4357 3789f03b-4d11-0410-bbf8-ca57d06f2519
Diffstat (limited to 'vncviewer/DesktopWindow.cxx')
-rw-r--r--vncviewer/DesktopWindow.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/vncviewer/DesktopWindow.cxx b/vncviewer/DesktopWindow.cxx
index 0188f724..a621e405 100644
--- a/vncviewer/DesktopWindow.cxx
+++ b/vncviewer/DesktopWindow.cxx
@@ -281,8 +281,8 @@ rdr::U32 DesktopWindow::translateKeyEvent(int keyCode, const char *keyText)
unsigned ucs;
// First check for function keys
- if ((keyCode >= FL_F) && (keyCode <= FL_F_Last))
- return XK_F1 + (keyCode - FL_F);
+ if ((keyCode > FL_F) && (keyCode <= FL_F_Last))
+ return XK_F1 + (keyCode - FL_F - 1);
// Numpad numbers
if ((keyCode >= (FL_KP + '0')) && (keyCode <= (FL_KP + '9')))