GDK: Prefix key names with KEY_
The keysyms create a lot of potential namespace conflicts for C, and are especially problematic for introspection, where we take constants into the namespace, so GDK_Display conflicts with GdkDisplay. For C application compatiblity, add gdkkeysyms-compat.h which uses the old names. Just one user in GTK+ continues to use gdkkeysyms-compat.h, which is the gtkimcontextsimple.c, since porting that requires porting more custom Perl code.
This commit is contained in:
@ -259,12 +259,12 @@ gtk_cell_renderer_spin_key_press_event (GtkWidget *widget,
|
||||
{
|
||||
if (event->state == 0)
|
||||
{
|
||||
if (event->keyval == GDK_Up)
|
||||
if (event->keyval == GDK_KEY_Up)
|
||||
{
|
||||
gtk_spin_button_spin (GTK_SPIN_BUTTON (widget), GTK_SPIN_STEP_FORWARD, 1);
|
||||
return TRUE;
|
||||
}
|
||||
else if (event->keyval == GDK_Down)
|
||||
else if (event->keyval == GDK_KEY_Down)
|
||||
{
|
||||
gtk_spin_button_spin (GTK_SPIN_BUTTON (widget), GTK_SPIN_STEP_BACKWARD, 1);
|
||||
return TRUE;
|
||||
|
||||
Reference in New Issue
Block a user