[vlc-devel] commit: XCB/window: Unicode non-Latin-1 keys (untested) ( Rémi Denis-Courmont )
git version control
git at videolan.org
Sun Jan 3 11:13:20 CET 2010
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sun Jan 3 12:08:46 2010 +0200| [4090e06769214e958496e1495a14f9d0a6fc0fe8] | committer: Rémi Denis-Courmont
XCB/window: Unicode non-Latin-1 keys (untested)
This is incomplete. X11 defined a whole set of non-Latin-1 key symbols
before ISO 10646. Only the key symbols defined later match Unicode (with
the 0x1000000 offset).
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=4090e06769214e958496e1495a14f9d0a6fc0fe8
---
modules/video_output/xcb/keys.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/modules/video_output/xcb/keys.c b/modules/video_output/xcb/keys.c
index 43bfa72..a136910 100644
--- a/modules/video_output/xcb/keys.c
+++ b/modules/video_output/xcb/keys.c
@@ -178,6 +178,9 @@ static uint_fast32_t ConvertKeySym (xcb_keysym_t sym)
/* X11 Latin-1 range */
if (sym <= 0xff)
return sym;
+ /* X11 Unicode range */
+ if (sym >= 0x1000100 && sym <= 0x110ffff)
+ return sym - 0x1000000;
/* Special keys */
res = bsearch (&sym, tab, sizeof (tab) / sizeof (tab[0]), sizeof (tab[0]),
More information about the vlc-devel
mailing list