gtk cannot differ GDK_KP_Enter and GDK_Return on win32
- From: Chuck Norris <norris chuck mail ru>
- To: gtk-list gnome org
- Subject: gtk cannot differ GDK_KP_Enter and GDK_Return on win32
- Date: Fri, 26 Feb 2010 13:29:26 +0600
Hi, All!
I don't know if this is known bug/feature that
gtk cannot differ GDK_KP_Enter and GDK_Return on win32
So, in my program in key-press-event on window
I get GDK_KP_Enter under linux after pressing Enter on keypad
but under windows xp I get GDK_Return.
I have took a look in gtk sources and found in gdkevents-win32.c(line
2144 in 2.18.7 version):
if (HIWORD (msg->lParam) & KF_EXTENDED)
{
switch (msg->wParam)
{
case VK_CONTROL:
event->key.hardware_keycode = VK_RCONTROL;
break;
case VK_SHIFT: /* Actually, KF_EXTENDED is not set
* for the right shift key.
*/
event->key.hardware_keycode = VK_RSHIFT;
break;
case VK_MENU:
event->key.hardware_keycode = VK_RMENU;
break;
}
}
maybe something like
case VK_ENTER:
event->key.keyval = GDK_KP_Enter;
break;
should be added to fix this behavior?
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]