From 547b0bd9383b202c6edcd5f2b39987dc27cb65f9 Mon Sep 17 00:00:00 2001 From: Owen Taylor Date: Fri, 25 Oct 2002 19:59:41 +0000 Subject: [PATCH] Fix sensitivity of file operation buttons and buttons inside fileop Fri Oct 25 14:51:34 2002 Owen Taylor * gtk/gtkfilesel.c: Fix sensitivity of file operation buttons and buttons inside fileop dialogs to update properly based on the contents of the entries. (#74267, based on part of a patch from Muktha Narayan) * gtk/gtkitemfactory.c (gtk_item_factory_create_item): Warn if loading image fails. * tests/testgtk.c: Fix data for "apple" inline pixbuf to be valid. --- ChangeLog | 18 ++++++++++++------ ChangeLog.pre-2-10 | 18 ++++++++++++------ ChangeLog.pre-2-2 | 18 ++++++++++++------ ChangeLog.pre-2-4 | 18 ++++++++++++------ ChangeLog.pre-2-6 | 18 ++++++++++++------ ChangeLog.pre-2-8 | 18 ++++++++++++------ gtk/gtkitemfactory.c | 9 ++++++++- 7 files changed, 80 insertions(+), 37 deletions(-) diff --git a/ChangeLog b/ChangeLog index b4608a7244..c22d76094a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,10 +1,10 @@ -Fri Oct 25 18:17:39 2002 Soeren Sandmann +Fri Oct 25 14:51:34 2002 Owen Taylor - * gtk/gtkpaned.[ch]: New GtkPaned keyboard navigation. (Shift-)F8 - now cycles the available handles instead of toggling focus on and - off. Fixes #87160, reported by Calum Benson. - -Fri Oct 25 10:50:37 2002 Owen Taylor + * gtk/gtkfilesel.c: Fix sensitivity of file operation + buttons and buttons inside fileop dialogs to update + properly based on the contents of the entries. + (#74267, based on part of a patch from Muktha + Narayan) * gtk/gtkitemfactory.c (gtk_item_factory_create_item): Warn if loading image fails. @@ -12,6 +12,12 @@ Fri Oct 25 10:50:37 2002 Owen Taylor * tests/testgtk.c: Fix data for "apple" inline pixbuf to be valid. +Fri Oct 25 18:17:39 2002 Soeren Sandmann + + * gtk/gtkpaned.[ch]: New GtkPaned keyboard navigation. (Shift-)F8 + now cycles the available handles instead of toggling focus on and + off. Fixes #87160, reported by Calum Benson. + 2002-10-25 Matthias Clasen * gdk/x11/gdkcursor-x11.c: Fix doc comment. diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index b4608a7244..c22d76094a 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,10 +1,10 @@ -Fri Oct 25 18:17:39 2002 Soeren Sandmann +Fri Oct 25 14:51:34 2002 Owen Taylor - * gtk/gtkpaned.[ch]: New GtkPaned keyboard navigation. (Shift-)F8 - now cycles the available handles instead of toggling focus on and - off. Fixes #87160, reported by Calum Benson. - -Fri Oct 25 10:50:37 2002 Owen Taylor + * gtk/gtkfilesel.c: Fix sensitivity of file operation + buttons and buttons inside fileop dialogs to update + properly based on the contents of the entries. + (#74267, based on part of a patch from Muktha + Narayan) * gtk/gtkitemfactory.c (gtk_item_factory_create_item): Warn if loading image fails. @@ -12,6 +12,12 @@ Fri Oct 25 10:50:37 2002 Owen Taylor * tests/testgtk.c: Fix data for "apple" inline pixbuf to be valid. +Fri Oct 25 18:17:39 2002 Soeren Sandmann + + * gtk/gtkpaned.[ch]: New GtkPaned keyboard navigation. (Shift-)F8 + now cycles the available handles instead of toggling focus on and + off. Fixes #87160, reported by Calum Benson. + 2002-10-25 Matthias Clasen * gdk/x11/gdkcursor-x11.c: Fix doc comment. diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index b4608a7244..c22d76094a 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -1,10 +1,10 @@ -Fri Oct 25 18:17:39 2002 Soeren Sandmann +Fri Oct 25 14:51:34 2002 Owen Taylor - * gtk/gtkpaned.[ch]: New GtkPaned keyboard navigation. (Shift-)F8 - now cycles the available handles instead of toggling focus on and - off. Fixes #87160, reported by Calum Benson. - -Fri Oct 25 10:50:37 2002 Owen Taylor + * gtk/gtkfilesel.c: Fix sensitivity of file operation + buttons and buttons inside fileop dialogs to update + properly based on the contents of the entries. + (#74267, based on part of a patch from Muktha + Narayan) * gtk/gtkitemfactory.c (gtk_item_factory_create_item): Warn if loading image fails. @@ -12,6 +12,12 @@ Fri Oct 25 10:50:37 2002 Owen Taylor * tests/testgtk.c: Fix data for "apple" inline pixbuf to be valid. +Fri Oct 25 18:17:39 2002 Soeren Sandmann + + * gtk/gtkpaned.[ch]: New GtkPaned keyboard navigation. (Shift-)F8 + now cycles the available handles instead of toggling focus on and + off. Fixes #87160, reported by Calum Benson. + 2002-10-25 Matthias Clasen * gdk/x11/gdkcursor-x11.c: Fix doc comment. diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index b4608a7244..c22d76094a 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,10 +1,10 @@ -Fri Oct 25 18:17:39 2002 Soeren Sandmann +Fri Oct 25 14:51:34 2002 Owen Taylor - * gtk/gtkpaned.[ch]: New GtkPaned keyboard navigation. (Shift-)F8 - now cycles the available handles instead of toggling focus on and - off. Fixes #87160, reported by Calum Benson. - -Fri Oct 25 10:50:37 2002 Owen Taylor + * gtk/gtkfilesel.c: Fix sensitivity of file operation + buttons and buttons inside fileop dialogs to update + properly based on the contents of the entries. + (#74267, based on part of a patch from Muktha + Narayan) * gtk/gtkitemfactory.c (gtk_item_factory_create_item): Warn if loading image fails. @@ -12,6 +12,12 @@ Fri Oct 25 10:50:37 2002 Owen Taylor * tests/testgtk.c: Fix data for "apple" inline pixbuf to be valid. +Fri Oct 25 18:17:39 2002 Soeren Sandmann + + * gtk/gtkpaned.[ch]: New GtkPaned keyboard navigation. (Shift-)F8 + now cycles the available handles instead of toggling focus on and + off. Fixes #87160, reported by Calum Benson. + 2002-10-25 Matthias Clasen * gdk/x11/gdkcursor-x11.c: Fix doc comment. diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index b4608a7244..c22d76094a 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,10 +1,10 @@ -Fri Oct 25 18:17:39 2002 Soeren Sandmann +Fri Oct 25 14:51:34 2002 Owen Taylor - * gtk/gtkpaned.[ch]: New GtkPaned keyboard navigation. (Shift-)F8 - now cycles the available handles instead of toggling focus on and - off. Fixes #87160, reported by Calum Benson. - -Fri Oct 25 10:50:37 2002 Owen Taylor + * gtk/gtkfilesel.c: Fix sensitivity of file operation + buttons and buttons inside fileop dialogs to update + properly based on the contents of the entries. + (#74267, based on part of a patch from Muktha + Narayan) * gtk/gtkitemfactory.c (gtk_item_factory_create_item): Warn if loading image fails. @@ -12,6 +12,12 @@ Fri Oct 25 10:50:37 2002 Owen Taylor * tests/testgtk.c: Fix data for "apple" inline pixbuf to be valid. +Fri Oct 25 18:17:39 2002 Soeren Sandmann + + * gtk/gtkpaned.[ch]: New GtkPaned keyboard navigation. (Shift-)F8 + now cycles the available handles instead of toggling focus on and + off. Fixes #87160, reported by Calum Benson. + 2002-10-25 Matthias Clasen * gdk/x11/gdkcursor-x11.c: Fix doc comment. diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index b4608a7244..c22d76094a 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,10 +1,10 @@ -Fri Oct 25 18:17:39 2002 Soeren Sandmann +Fri Oct 25 14:51:34 2002 Owen Taylor - * gtk/gtkpaned.[ch]: New GtkPaned keyboard navigation. (Shift-)F8 - now cycles the available handles instead of toggling focus on and - off. Fixes #87160, reported by Calum Benson. - -Fri Oct 25 10:50:37 2002 Owen Taylor + * gtk/gtkfilesel.c: Fix sensitivity of file operation + buttons and buttons inside fileop dialogs to update + properly based on the contents of the entries. + (#74267, based on part of a patch from Muktha + Narayan) * gtk/gtkitemfactory.c (gtk_item_factory_create_item): Warn if loading image fails. @@ -12,6 +12,12 @@ Fri Oct 25 10:50:37 2002 Owen Taylor * tests/testgtk.c: Fix data for "apple" inline pixbuf to be valid. +Fri Oct 25 18:17:39 2002 Soeren Sandmann + + * gtk/gtkpaned.[ch]: New GtkPaned keyboard navigation. (Shift-)F8 + now cycles the available handles instead of toggling focus on and + off. Fixes #87160, reported by Calum Benson. + 2002-10-25 Matthias Clasen * gdk/x11/gdkcursor-x11.c: Fix doc comment. diff --git a/gtk/gtkitemfactory.c b/gtk/gtkitemfactory.c index 5a82f9ff4e..23e344cf68 100644 --- a/gtk/gtkitemfactory.c +++ b/gtk/gtkitemfactory.c @@ -1076,15 +1076,22 @@ gtk_item_factory_create_item (GtkItemFactory *ifactory, gtk_check_menu_item_set_show_toggle (GTK_CHECK_MENU_ITEM (widget), TRUE); if (type_id == quark_type_image_item) { + GError *error = NULL; GdkPixbuf *pixbuf = NULL; image = NULL; pixbuf = gdk_pixbuf_new_from_inline (-1, entry->extra_data, FALSE, - NULL); + &error); if (pixbuf) image = gtk_image_new_from_pixbuf (pixbuf); + else + { + g_warning ("Error loading menu image: %s", error->message); + g_error_free (error); + } + if (image) { gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (widget), image);