diff options
author | Matthias Clasen <mclasen@redhat.com> | 2006-05-18 16:51:37 +0000 |
---|---|---|
committer | Matthias Clasen <matthiasc@src.gnome.org> | 2006-05-18 16:51:37 +0000 |
commit | 184937d21207f75bbdb08f0a2a9ba203e18d9e89 (patch) | |
tree | 4652cbf93fe403d99ca6b55de098bde8789c48f6 | |
parent | 37928c202e3260fd6c7bdc523e41d7765f8ebb31 (diff) | |
download | gdk-pixbuf-184937d21207f75bbdb08f0a2a9ba203e18d9e89.tar.gz |
Only unref the pixbuf if the image has the appropriate storage type.
2006-05-18 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkimage.c (icon_theme_changed): Only unref the pixbuf
if the image has the appropriate storage type. (#342096, Tommi
Komulainen)
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | ChangeLog.pre-2-10 | 4 | ||||
-rw-r--r-- | gtk/gtkimage.c | 11 |
3 files changed, 15 insertions, 4 deletions
@@ -1,5 +1,9 @@ 2006-05-18 Matthias Clasen <mclasen@redhat.com> + * gtk/gtkimage.c (icon_theme_changed): Only unref the pixbuf + if the image has the appropriate storage type. (#342096, Tommi + Komulainen) + * gtk/gtkentry.c (gtk_entry_drag_data_received): Make drops end up at the right spot. (#342072, Yevgen Muntyan) diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 131a64b8e..4f7a5c9eb 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,5 +1,9 @@ 2006-05-18 Matthias Clasen <mclasen@redhat.com> + * gtk/gtkimage.c (icon_theme_changed): Only unref the pixbuf + if the image has the appropriate storage type. (#342096, Tommi + Komulainen) + * gtk/gtkentry.c (gtk_entry_drag_data_received): Make drops end up at the right spot. (#342072, Yevgen Muntyan) diff --git a/gtk/gtkimage.c b/gtk/gtkimage.c index 3221335eb..f6fdbee4a 100644 --- a/gtk/gtkimage.c +++ b/gtk/gtkimage.c @@ -1409,11 +1409,14 @@ animation_timeout (gpointer data) static void icon_theme_changed (GtkImage *image) { - if (image->data.name.pixbuf) - g_object_unref (image->data.name.pixbuf); - image->data.name.pixbuf = NULL; + if (image->storage_type == GTK_IMAGE_ICON_NAME) + { + if (image->data.name.pixbuf) + g_object_unref (image->data.name.pixbuf); + image->data.name.pixbuf = NULL; - gtk_widget_queue_draw (GTK_WIDGET (image)); + gtk_widget_queue_draw (GTK_WIDGET (image)); + } } static void |