From 3e58667f6b4e0ef05fc02aae11fb2ee86aea101e Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Wed, 11 Sep 2002 21:55:48 +0000 Subject: [PATCH] Merge from gtk-2-0: 2002-09-12 Tor Lillqvist Merge from gtk-2-0: * gdk/win32/gdkkeys-win32.c (print_keysym_tab): Factor out debugging output to new function. --- ChangeLog | 3 +++ ChangeLog.pre-2-10 | 3 +++ ChangeLog.pre-2-2 | 3 +++ ChangeLog.pre-2-4 | 3 +++ ChangeLog.pre-2-6 | 3 +++ ChangeLog.pre-2-8 | 3 +++ gdk/win32/gdkkeys-win32.c | 47 +++++++++++++++++++++------------------ 7 files changed, 43 insertions(+), 22 deletions(-) diff --git a/ChangeLog b/ChangeLog index ab87a861c5..7cf31f6a6c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -29,6 +29,9 @@ to some functions, related to moving and resizing and expose and antiexpose queue processing. Use %p to output HWNDs. + * gdk/win32/gdkkeys-win32.c (print_keysym_tab): Factor out + debugging output to new function. + Fix for #81831 by Tim Evans: * gdk/win32/gdkevents-win32.c (gdk_event_translate): Don't call diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index ab87a861c5..7cf31f6a6c 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -29,6 +29,9 @@ to some functions, related to moving and resizing and expose and antiexpose queue processing. Use %p to output HWNDs. + * gdk/win32/gdkkeys-win32.c (print_keysym_tab): Factor out + debugging output to new function. + Fix for #81831 by Tim Evans: * gdk/win32/gdkevents-win32.c (gdk_event_translate): Don't call diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index ab87a861c5..7cf31f6a6c 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -29,6 +29,9 @@ to some functions, related to moving and resizing and expose and antiexpose queue processing. Use %p to output HWNDs. + * gdk/win32/gdkkeys-win32.c (print_keysym_tab): Factor out + debugging output to new function. + Fix for #81831 by Tim Evans: * gdk/win32/gdkevents-win32.c (gdk_event_translate): Don't call diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index ab87a861c5..7cf31f6a6c 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -29,6 +29,9 @@ to some functions, related to moving and resizing and expose and antiexpose queue processing. Use %p to output HWNDs. + * gdk/win32/gdkkeys-win32.c (print_keysym_tab): Factor out + debugging output to new function. + Fix for #81831 by Tim Evans: * gdk/win32/gdkevents-win32.c (gdk_event_translate): Don't call diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index ab87a861c5..7cf31f6a6c 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -29,6 +29,9 @@ to some functions, related to moving and resizing and expose and antiexpose queue processing. Use %p to output HWNDs. + * gdk/win32/gdkkeys-win32.c (print_keysym_tab): Factor out + debugging output to new function. + Fix for #81831 by Tim Evans: * gdk/win32/gdkevents-win32.c (gdk_event_translate): Don't call diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index ab87a861c5..7cf31f6a6c 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -29,6 +29,9 @@ to some functions, related to moving and resizing and expose and antiexpose queue processing. Use %p to output HWNDs. + * gdk/win32/gdkkeys-win32.c (print_keysym_tab): Factor out + debugging output to new function. + Fix for #81831 by Tim Evans: * gdk/win32/gdkevents-win32.c (gdk_event_translate): Don't call diff --git a/gdk/win32/gdkkeys-win32.c b/gdk/win32/gdkkeys-win32.c index e96b464a90..530db6132c 100644 --- a/gdk/win32/gdkkeys-win32.c +++ b/gdk/win32/gdkkeys-win32.c @@ -44,6 +44,30 @@ static GdkKeymap *default_keymap = NULL; static guint *keysym_tab = NULL; +#ifdef G_ENABLE_DEBUG +static void +print_keysym_tab (void) +{ + gint vk; + + g_print ("keymap:\n"); + for (vk = 0; vk < 256; vk++) + { + gint state; + + g_print ("%#.02x: ", vk); + for (state = 0; state < 4; state++) + { + gchar *name = gdk_keyval_name (keysym_tab[vk*4 + state]); + if (name == NULL) + name = "(none)"; + g_print ("%s ", name); + } + g_print ("\n"); + } +} +#endif + static void update_keymap (void) { @@ -262,28 +286,7 @@ update_keymap (void) key_state[vk] = 0; } } -#ifdef G_ENABLE_DEBUG - if (_gdk_debug_flags & GDK_DEBUG_EVENTS) - { - gint vk; - - g_print ("keymap:\n"); - for (vk = 0; vk < 256; vk++) - { - gint state; - - g_print ("%#.02x: ", vk); - for (state = 0; state < 4; state++) - { - gchar *name = gdk_keyval_name (keysym_tab[vk*4 + state]); - if (name == NULL) - name = "(none)"; - g_print ("%s ", name); - } - g_print ("\n"); - } - } -#endif + GDK_NOTE (EVENTS, print_keysym_tab ()); } GdkKeymap*