From 62304b0fb5e70c90950237568591b7a23fc74c60 Mon Sep 17 00:00:00 2001 From: Sven Neumann Date: Tue, 4 Feb 2003 13:43:10 +0000 Subject: [PATCH] made the ugly hack that prevents users from reassigning the F1 shortcut 2003-02-04 Sven Neumann * app/widgets/gimpitemfactory.c (gimp_item_factory_item_key_press): made the ugly hack that prevents users from reassigning the F1 shortcut even more ugly but fixed bug #105068. --- ChangeLog | 6 ++++++ app/widgets/gimpitemfactory.c | 7 ++++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index f7be230b6f..d534d9ce83 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2003-02-04 Sven Neumann + + * app/widgets/gimpitemfactory.c (gimp_item_factory_item_key_press): + made the ugly hack that prevents users from reassigning the F1 + shortcut even more ugly but fixed bug #105068. + 2003-02-04 Sven Neumann * plug-ins/gimpressionist/gimpressionist.h diff --git a/app/widgets/gimpitemfactory.c b/app/widgets/gimpitemfactory.c index 72cb525ed5..c243ffaf80 100644 --- a/app/widgets/gimpitemfactory.c +++ b/app/widgets/gimpitemfactory.c @@ -949,13 +949,14 @@ gimp_item_factory_item_key_press (GtkWidget *widget, help_page = NULL; } - /* For any key except F1, continue with the standard - * GtkItemFactory callback and assign a new shortcut, but don't - * assign a shortcut to the help menu entries... + /* For any valid accelerator key except F1, continue with the + * standard GtkItemFactory callback and assign a new shortcut, but + * don't assign a shortcut to the help menu entries ... */ if (kevent->keyval != GDK_F1) { if (help_page && + gtk_accelerator_valid (kevent->keyval, 0) && (item_factory == (GtkItemFactory *) gimp_item_factory_from_path ("")) && (strcmp (help_page, "help/dialogs/help.html") == 0 ||