fixed KeySym handling ((keysym & 0xF000) != 0 instead of keysym < 0xFF to determine printable characters
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@6859 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
9c6751aa46
commit
3d6f72618e
@ -503,7 +503,7 @@ static long map_to_unmodified_wx_keysym( KeySym keysym )
|
||||
case GDK_F12: key_code = WXK_F12; break;
|
||||
default:
|
||||
{
|
||||
if (keysym <= 0xFF)
|
||||
if ((keysym & 0xF000) == 0)
|
||||
{
|
||||
guint upper = gdk_keyval_to_upper( (guint)keysym );
|
||||
keysym = (upper != 0 ? upper : keysym ); /* to be MSW compatible */
|
||||
@ -602,7 +602,7 @@ static long map_to_wx_keysym( KeySym keysym )
|
||||
case GDK_F12: key_code = WXK_F12; break;
|
||||
default:
|
||||
{
|
||||
if (keysym <= 0xFF)
|
||||
if ((keysym & 0xF000) == 0)
|
||||
{
|
||||
key_code = (guint)keysym;
|
||||
}
|
||||
@ -794,6 +794,7 @@ static gint gtk_window_key_press_callback( GtkWidget *widget, GdkEventKey *gdk_e
|
||||
if (!win->m_hasVMT) return FALSE;
|
||||
if (g_blockEventsOnDrag) return FALSE;
|
||||
|
||||
|
||||
/*
|
||||
wxString tmp;
|
||||
tmp += (char)gdk_event->keyval;
|
||||
|
@ -503,7 +503,7 @@ static long map_to_unmodified_wx_keysym( KeySym keysym )
|
||||
case GDK_F12: key_code = WXK_F12; break;
|
||||
default:
|
||||
{
|
||||
if (keysym <= 0xFF)
|
||||
if ((keysym & 0xF000) == 0)
|
||||
{
|
||||
guint upper = gdk_keyval_to_upper( (guint)keysym );
|
||||
keysym = (upper != 0 ? upper : keysym ); /* to be MSW compatible */
|
||||
@ -602,7 +602,7 @@ static long map_to_wx_keysym( KeySym keysym )
|
||||
case GDK_F12: key_code = WXK_F12; break;
|
||||
default:
|
||||
{
|
||||
if (keysym <= 0xFF)
|
||||
if ((keysym & 0xF000) == 0)
|
||||
{
|
||||
key_code = (guint)keysym;
|
||||
}
|
||||
@ -794,6 +794,7 @@ static gint gtk_window_key_press_callback( GtkWidget *widget, GdkEventKey *gdk_e
|
||||
if (!win->m_hasVMT) return FALSE;
|
||||
if (g_blockEventsOnDrag) return FALSE;
|
||||
|
||||
|
||||
/*
|
||||
wxString tmp;
|
||||
tmp += (char)gdk_event->keyval;
|
||||
|
Loading…
Reference in New Issue
Block a user