summaryrefslogtreecommitdiffstats
path: root/vnc
diff options
context:
space:
mode:
authorjsorg71 <jsorg71>2010-03-17 18:35:26 +0000
committerjsorg71 <jsorg71>2010-03-17 18:35:26 +0000
commit2b8a5f42b1548f9bc8a76b066712a7da4f7342e9 (patch)
tree83341463cae83ef11be2395105081ae0770a5a11 /vnc
parentabba73f9bcfa6e3e51f395d67f7270518bb1787d (diff)
downloadxrdp-proprietary-2b8a5f42b1548f9bc8a76b066712a7da4f7342e9.tar.gz
xrdp-proprietary-2b8a5f42b1548f9bc8a76b066712a7da4f7342e9.zip
fix for mstsc altgr
Diffstat (limited to 'vnc')
-rw-r--r--vnc/vnc.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/vnc/vnc.c b/vnc/vnc.c
index fefedd6c..6df35b02 100644
--- a/vnc/vnc.c
+++ b/vnc/vnc.c
@@ -255,12 +255,29 @@ lib_mod_event(struct vnc* v, int msg, long param1, long param2,
key = param2;
if (key > 0)
{
+ if (key == 65027) /* altgr */
+ {
+ if (v->shift_state)
+ {
+ /* fix for mstsc sending left control down with altgr */
+ init_stream(s, 8192);
+ out_uint8(s, 4);
+ out_uint8(s, 0); /* down flag */
+ out_uint8s(s, 2);
+ out_uint32_be(s, 65507); /* left control */
+ lib_send(v, s->data, 8);
+ }
+ }
init_stream(s, 8192);
out_uint8(s, 4);
out_uint8(s, msg == 15); /* down flag */
out_uint8s(s, 2);
out_uint32_be(s, key);
error = lib_send(v, s->data, 8);
+ if (key == 65507) /* left control */
+ {
+ v->shift_state = msg == 15;
+ }
}
}
else if (msg >= 100 && msg <= 110) /* mouse events */