summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorColin Walters <walters@verbum.org>2010-09-08 13:35:51 -0400
committerColin Walters <walters@verbum.org>2010-09-08 18:51:44 -0400
commit913cdf3be750a1e74c09b20edf55a57f9a919fcc (patch)
tree0d2129a167579c0d896bb9213503619b2ef44d1f /tests
parent03c19e37af1f7aa9af8a48bcc9dc023397f8693f (diff)
downloadgtk+-913cdf3be750a1e74c09b20edf55a57f9a919fcc.tar.gz
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.
Diffstat (limited to 'tests')
-rw-r--r--tests/testgtk.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/testgtk.c b/tests/testgtk.c
index b29c4d4be0..8d408b3123 100644
--- a/tests/testgtk.c
+++ b/tests/testgtk.c
@@ -2278,7 +2278,7 @@ void create_labels (GtkWidget *widget)
"but this _word is <span foreground=\"purple\"><big>purple</big></span>\n"
"<span underline=\"double\">We like <sup>superscript</sup> and <sub>subscript</sub> too</span>");
- g_assert (gtk_label_get_mnemonic_keyval (GTK_LABEL (label)) == GDK_s);
+ g_assert (gtk_label_get_mnemonic_keyval (GTK_LABEL (label)) == GDK_KEY_s);
gtk_container_add (GTK_CONTAINER (frame), label);
gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, FALSE, 0);
@@ -3511,7 +3511,7 @@ create_menus (GtkWidget *widget)
gtk_widget_add_accelerator (menuitem,
"activate",
accel_group,
- GDK_F1,
+ GDK_KEY_F1,
0,
GTK_ACCEL_VISIBLE);
menuitem = gtk_check_menu_item_new_with_label ("Accelerator Locked");
@@ -3520,7 +3520,7 @@ create_menus (GtkWidget *widget)
gtk_widget_add_accelerator (menuitem,
"activate",
accel_group,
- GDK_F2,
+ GDK_KEY_F2,
0,
GTK_ACCEL_VISIBLE | GTK_ACCEL_LOCKED);
menuitem = gtk_check_menu_item_new_with_label ("Accelerators Frozen");
@@ -3529,13 +3529,13 @@ create_menus (GtkWidget *widget)
gtk_widget_add_accelerator (menuitem,
"activate",
accel_group,
- GDK_F2,
+ GDK_KEY_F2,
0,
GTK_ACCEL_VISIBLE);
gtk_widget_add_accelerator (menuitem,
"activate",
accel_group,
- GDK_F3,
+ GDK_KEY_F3,
0,
GTK_ACCEL_VISIBLE);