Revision: 5108 http://tigervnc.svn.sourceforge.net/tigervnc/?rev=5108&view=rev Author: ossman_ Date: 2013-05-23 11:45:18 +0000 (Thu, 23 May 2013) Log Message: ----------- xkbcomp ignores keycodes without names, so make sure any keycode we use actually has one.
Modified Paths: -------------- trunk/unix/xserver/hw/vnc/InputXKB.cc Modified: trunk/unix/xserver/hw/vnc/InputXKB.cc =================================================================== --- trunk/unix/xserver/hw/vnc/InputXKB.cc 2013-05-23 11:44:23 UTC (rev 5107) +++ trunk/unix/xserver/hw/vnc/InputXKB.cc 2013-05-23 11:45:18 UTC (rev 5108) @@ -501,6 +501,22 @@ XkbSetCauseUnknown(&cause); + /* + * Tools like xkbcomp get confused if there isn't a name + * assigned to the keycode we're trying to use. + */ + if (xkb->names && xkb->names->keys && + (xkb->names->keys[key].name[0] == '\0')) { + xkb->names->keys[key].name[0] = 'I'; + xkb->names->keys[key].name[1] = '0' + (key / 100) % 10; + xkb->names->keys[key].name[2] = '0' + (key / 10) % 10; + xkb->names->keys[key].name[3] = '0' + (key / 1) % 10; + + changes.names.changed |= XkbKeyNamesMask; + changes.names.first_key = key; + changes.names.num_keys = 1; + } + /* FIXME: Verify that ONE_LEVEL isn't screwed up */ types[XkbGroup1Index] = XkbOneLevelIndex; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. ------------------------------------------------------------------------------ Try New Relic Now & We'll Send You this Cool Shirt New Relic is the only SaaS-based application performance monitoring service that delivers powerful full stack analytics. Optimize and monitor your browser, app, & servers with just a few lines of code. Try New Relic and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_may _______________________________________________ Tigervnc-commits mailing list Tigervnc-commits@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/tigervnc-commits