summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog18
-rw-r--r--ChangeLog.pre-2-018
-rw-r--r--ChangeLog.pre-2-1018
-rw-r--r--ChangeLog.pre-2-218
-rw-r--r--ChangeLog.pre-2-418
-rw-r--r--ChangeLog.pre-2-618
-rw-r--r--ChangeLog.pre-2-818
-rw-r--r--gtk/gtkaccelgroup.c2
-rw-r--r--gtk/gtkbindings.c2
-rw-r--r--gtk/gtkmenushell.c11
-rw-r--r--gtk/gtkwindow.c19
-rw-r--r--gtk/gtkwindow.h2
12 files changed, 146 insertions, 16 deletions
diff --git a/ChangeLog b/ChangeLog
index edeab2696..f017d2405 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,21 @@
+Thu Feb 21 16:51:17 2002 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkaccelgroup.c (gtk_accelerator_valid): Add
+ GDK_ISO_Next_Group/Prev_Group/Level3_Shift/
+ First_Group/Last_Group to list of invalid accelerators.
+ (A lot more that should be added, but probably would
+ want a range mechanism. These are the ones found in
+ the standard XFree86 config files.)
+
+ * gtk/gtkbindings.c (gtk_bindings_activate): Fix problem
+ that broke bindings for menus.
+
+ * gtk/gtkwindow.[ch]: Export _gtk_window_activate_key()
+ privately.
+
+ * gtk/gtkmenushell.c (gtk_menu_shell_key_press): Use
+ _gtk_window_activate_key(), gtk_bindings_activate_event().
+
Thu Feb 21 12:24:22 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkctree.c (gtk_ctree_class_init): Remove some workarounds
diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0
index edeab2696..f017d2405 100644
--- a/ChangeLog.pre-2-0
+++ b/ChangeLog.pre-2-0
@@ -1,3 +1,21 @@
+Thu Feb 21 16:51:17 2002 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkaccelgroup.c (gtk_accelerator_valid): Add
+ GDK_ISO_Next_Group/Prev_Group/Level3_Shift/
+ First_Group/Last_Group to list of invalid accelerators.
+ (A lot more that should be added, but probably would
+ want a range mechanism. These are the ones found in
+ the standard XFree86 config files.)
+
+ * gtk/gtkbindings.c (gtk_bindings_activate): Fix problem
+ that broke bindings for menus.
+
+ * gtk/gtkwindow.[ch]: Export _gtk_window_activate_key()
+ privately.
+
+ * gtk/gtkmenushell.c (gtk_menu_shell_key_press): Use
+ _gtk_window_activate_key(), gtk_bindings_activate_event().
+
Thu Feb 21 12:24:22 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkctree.c (gtk_ctree_class_init): Remove some workarounds
diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10
index edeab2696..f017d2405 100644
--- a/ChangeLog.pre-2-10
+++ b/ChangeLog.pre-2-10
@@ -1,3 +1,21 @@
+Thu Feb 21 16:51:17 2002 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkaccelgroup.c (gtk_accelerator_valid): Add
+ GDK_ISO_Next_Group/Prev_Group/Level3_Shift/
+ First_Group/Last_Group to list of invalid accelerators.
+ (A lot more that should be added, but probably would
+ want a range mechanism. These are the ones found in
+ the standard XFree86 config files.)
+
+ * gtk/gtkbindings.c (gtk_bindings_activate): Fix problem
+ that broke bindings for menus.
+
+ * gtk/gtkwindow.[ch]: Export _gtk_window_activate_key()
+ privately.
+
+ * gtk/gtkmenushell.c (gtk_menu_shell_key_press): Use
+ _gtk_window_activate_key(), gtk_bindings_activate_event().
+
Thu Feb 21 12:24:22 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkctree.c (gtk_ctree_class_init): Remove some workarounds
diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2
index edeab2696..f017d2405 100644
--- a/ChangeLog.pre-2-2
+++ b/ChangeLog.pre-2-2
@@ -1,3 +1,21 @@
+Thu Feb 21 16:51:17 2002 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkaccelgroup.c (gtk_accelerator_valid): Add
+ GDK_ISO_Next_Group/Prev_Group/Level3_Shift/
+ First_Group/Last_Group to list of invalid accelerators.
+ (A lot more that should be added, but probably would
+ want a range mechanism. These are the ones found in
+ the standard XFree86 config files.)
+
+ * gtk/gtkbindings.c (gtk_bindings_activate): Fix problem
+ that broke bindings for menus.
+
+ * gtk/gtkwindow.[ch]: Export _gtk_window_activate_key()
+ privately.
+
+ * gtk/gtkmenushell.c (gtk_menu_shell_key_press): Use
+ _gtk_window_activate_key(), gtk_bindings_activate_event().
+
Thu Feb 21 12:24:22 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkctree.c (gtk_ctree_class_init): Remove some workarounds
diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4
index edeab2696..f017d2405 100644
--- a/ChangeLog.pre-2-4
+++ b/ChangeLog.pre-2-4
@@ -1,3 +1,21 @@
+Thu Feb 21 16:51:17 2002 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkaccelgroup.c (gtk_accelerator_valid): Add
+ GDK_ISO_Next_Group/Prev_Group/Level3_Shift/
+ First_Group/Last_Group to list of invalid accelerators.
+ (A lot more that should be added, but probably would
+ want a range mechanism. These are the ones found in
+ the standard XFree86 config files.)
+
+ * gtk/gtkbindings.c (gtk_bindings_activate): Fix problem
+ that broke bindings for menus.
+
+ * gtk/gtkwindow.[ch]: Export _gtk_window_activate_key()
+ privately.
+
+ * gtk/gtkmenushell.c (gtk_menu_shell_key_press): Use
+ _gtk_window_activate_key(), gtk_bindings_activate_event().
+
Thu Feb 21 12:24:22 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkctree.c (gtk_ctree_class_init): Remove some workarounds
diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6
index edeab2696..f017d2405 100644
--- a/ChangeLog.pre-2-6
+++ b/ChangeLog.pre-2-6
@@ -1,3 +1,21 @@
+Thu Feb 21 16:51:17 2002 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkaccelgroup.c (gtk_accelerator_valid): Add
+ GDK_ISO_Next_Group/Prev_Group/Level3_Shift/
+ First_Group/Last_Group to list of invalid accelerators.
+ (A lot more that should be added, but probably would
+ want a range mechanism. These are the ones found in
+ the standard XFree86 config files.)
+
+ * gtk/gtkbindings.c (gtk_bindings_activate): Fix problem
+ that broke bindings for menus.
+
+ * gtk/gtkwindow.[ch]: Export _gtk_window_activate_key()
+ privately.
+
+ * gtk/gtkmenushell.c (gtk_menu_shell_key_press): Use
+ _gtk_window_activate_key(), gtk_bindings_activate_event().
+
Thu Feb 21 12:24:22 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkctree.c (gtk_ctree_class_init): Remove some workarounds
diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8
index edeab2696..f017d2405 100644
--- a/ChangeLog.pre-2-8
+++ b/ChangeLog.pre-2-8
@@ -1,3 +1,21 @@
+Thu Feb 21 16:51:17 2002 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkaccelgroup.c (gtk_accelerator_valid): Add
+ GDK_ISO_Next_Group/Prev_Group/Level3_Shift/
+ First_Group/Last_Group to list of invalid accelerators.
+ (A lot more that should be added, but probably would
+ want a range mechanism. These are the ones found in
+ the standard XFree86 config files.)
+
+ * gtk/gtkbindings.c (gtk_bindings_activate): Fix problem
+ that broke bindings for menus.
+
+ * gtk/gtkwindow.[ch]: Export _gtk_window_activate_key()
+ privately.
+
+ * gtk/gtkmenushell.c (gtk_menu_shell_key_press): Use
+ _gtk_window_activate_key(), gtk_bindings_activate_event().
+
Thu Feb 21 12:24:22 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkctree.c (gtk_ctree_class_init): Remove some workarounds
diff --git a/gtk/gtkaccelgroup.c b/gtk/gtkaccelgroup.c
index 3f15a9e6e..1ceb537e3 100644
--- a/gtk/gtkaccelgroup.c
+++ b/gtk/gtkaccelgroup.c
@@ -805,6 +805,8 @@ gtk_accelerator_valid (guint keyval,
GDK_Shift_L, GDK_Shift_R, GDK_Shift_Lock, GDK_Caps_Lock, GDK_ISO_Lock,
GDK_Control_L, GDK_Control_R, GDK_Meta_L, GDK_Meta_R,
GDK_Alt_L, GDK_Alt_R, GDK_Super_L, GDK_Super_R, GDK_Hyper_L, GDK_Hyper_R,
+ GDK_ISO_Level3_Shift, GDK_ISO_Next_Group, GDK_ISO_Prev_Group,
+ GDK_ISO_First_Group, GDK_ISO_Last_Group,
GDK_Mode_switch, GDK_Num_Lock, GDK_Multi_key,
GDK_Scroll_Lock, GDK_Sys_Req,
GDK_Up, GDK_Down, GDK_Left, GDK_Right, GDK_Tab, GDK_ISO_Left_Tab,
diff --git a/gtk/gtkbindings.c b/gtk/gtkbindings.c
index 95ae875d8..abf473c46 100644
--- a/gtk/gtkbindings.c
+++ b/gtk/gtkbindings.c
@@ -1075,7 +1075,7 @@ gtk_bindings_activate (GtkObject *object,
if (!GTK_IS_WIDGET (object))
return FALSE;
- is_release = (BINDING_MOD_MASK () & GDK_RELEASE_MASK) != 0;
+ is_release = (modifiers & GDK_RELEASE_MASK) != 0;
modifiers = modifiers & BINDING_MOD_MASK () & ~GDK_RELEASE_MASK;
key_hash = binding_key_hash_for_keymap (gdk_keymap_get_default ());
diff --git a/gtk/gtkmenushell.c b/gtk/gtkmenushell.c
index 46355216a..2d352700d 100644
--- a/gtk/gtkmenushell.c
+++ b/gtk/gtkmenushell.c
@@ -551,21 +551,14 @@ gtk_menu_shell_key_press (GtkWidget *widget,
if (!menu_shell->active_menu_item && menu_shell->parent_menu_shell)
return gtk_widget_event (menu_shell->parent_menu_shell, (GdkEvent *)event);
- if (gtk_bindings_activate (GTK_OBJECT (widget),
- event->keyval,
- event->state))
+ if (_gtk_bindings_activate_event (GTK_OBJECT (widget), event))
return TRUE;
toplevel = gtk_widget_get_toplevel (widget);
if (GTK_IS_WINDOW (toplevel) &&
- gtk_window_mnemonic_activate (GTK_WINDOW (toplevel),
- event->keyval,
- event->state))
+ _gtk_window_activate_key (GTK_WINDOW (toplevel), event))
return TRUE;
- if (gtk_accel_groups_activate (G_OBJECT (widget), event->keyval, event->state))
- return TRUE;
-
return FALSE;
}
diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c
index a031e8bad..f2bca9df0 100644
--- a/gtk/gtkwindow.c
+++ b/gtk/gtkwindow.c
@@ -226,8 +226,6 @@ static void gtk_window_realize_icon (GtkWindow *window);
static void gtk_window_unrealize_icon (GtkWindow *window);
static void gtk_window_notify_keys_changed (GtkWindow *window);
-static gboolean gtk_window_activate_key (GtkWindow *window,
- GdkEventKey *event);
static GtkKeyHash *gtk_window_get_key_hash (GtkWindow *window);
static void gtk_window_free_key_hash (GtkWindow *window);
@@ -3534,7 +3532,7 @@ gtk_window_key_press_event (GtkWidget *widget,
/* Check for mnemonics and accelerators
*/
if (!handled)
- handled = gtk_window_activate_key (window, event);
+ handled = _gtk_window_activate_key (window, event);
if (!handled)
{
@@ -5812,9 +5810,18 @@ gtk_window_free_key_hash (GtkWindow *window)
}
}
-static gboolean
-gtk_window_activate_key (GtkWindow *window,
- GdkEventKey *event)
+/**
+ * _gtk_window_activate_key:
+ * @window: a #GtkWindow
+ * @event: a #GdkEventKey
+ *
+ * Activates mnemonics and accelerators for this #GtKWindow
+ *
+ * Return value: %TRUE if a mnemonic or accelerator was found and activated.
+ **/
+gboolean
+_gtk_window_activate_key (GtkWindow *window,
+ GdkEventKey *event)
{
GtkKeyHash *key_hash = g_object_get_data (G_OBJECT (window), "gtk-window-key-hash");
GtkWindowKeyEntry *found_entry = NULL;
diff --git a/gtk/gtkwindow.h b/gtk/gtkwindow.h
index d6c97376d..329fcdc44 100644
--- a/gtk/gtkwindow.h
+++ b/gtk/gtkwindow.h
@@ -325,6 +325,8 @@ void _gtk_window_constrain_size (GtkWindow *window,
gint *new_width,
gint *new_height);
GtkWindowGroup *_gtk_window_get_group (GtkWindow *window);
+gboolean _gtk_window_activate_key (GtkWindow *window,
+ GdkEventKey *event);
/* --- internal (GtkAcceleratable) --- */
gboolean _gtk_window_query_nonaccels (GtkWindow *window,