diff finch/libgnt/gntkeys.c @ 27922:3b6f50b68f5d

Make gnt_keys_refine UTF8-compatible. Note, the rest of the tests don't need to be changed as multi-byte UTF8 values are always >128. Fixes #2504.
author Elliott Sales de Andrade <qulogic@pidgin.im>
date Sun, 16 Aug 2009 03:22:58 +0000
parents 135ee310d62c
children
line wrap: on
line diff
--- a/finch/libgnt/gntkeys.c	Sat Aug 15 19:59:14 2009 +0000
+++ b/finch/libgnt/gntkeys.c	Sun Aug 16 03:22:58 2009 +0000
@@ -166,7 +166,7 @@
 				strstr(term, "xterm") == term ||
 				strstr(term, "vt100") == term)
 			*(text + 1) = 'O';
-	} else if (*(unsigned char*)text == 195) {
+	} else if (g_utf8_get_char(text) == 195) {
 		if (*(text + 2) == 0 && strstr(term, "xterm") == term) {
 			*(text) = 27;
 			*(text + 1) -= 64;  /* Say wha? */